<?php
/**
* @version 1.0.0
* @category Anahita Social Engineâ¢
* @copyright Copyright (C) 2008 - 2010 rmdStudio Inc. and Peerglobe Technology Inc. All rights reserved.
* @license GNU GPLv2 <http://www.gnu.org/licenses/old-licenses/gpl-2.0.html>
* @link http://www.anahitapolis.com
*/
class AnModelApplicationRepository extends AnDomainRepositoryDefault
{
/**
* Get application or applications using a component
* @return mixed
* @param $component mixed
*/
public function getApplicationByComponent($component)
{
$query = $this->getMapper()->getQuery();
if ( is_array($component) )
return $query->where('component','IN',$component)->fetchAll();
else
return $query->where('component','=',$component)->fetch();
}
//end class
}