function getPack() { static $s4_container; if ($s4_container === null) { $s4_container = new MovieViewerS4DealContainer(); } return $s4_container->getPack($this->pack_id); }
function findById($pack_id) { //TODO: DealPackを永続化する方法を検討する $container = new MovieViewerS4DealContainer(); $pack = $container->getPack($pack_id); if ($pack === null) { MovieViewerLogger::getLogger()->addError("パックが見つからない", array("pack_id" => $pack_id)); throw new MovieViewerRepositoryObjectCantStoreException(); } return $pack; }