Ejemplo n.º 1
0
 /**
  * list all Workers
  * 
  * @action listWorkers
  * @return KalturaSchedulerWorkerListResponse
  */
 function listWorkersAction()
 {
     $c = new Criteria();
     $count = SchedulerWorkerPeer::doCount($c, false, myDbHelper::getConnection(myDbHelper::DB_HELPER_CONN_PROPEL2));
     $list = SchedulerWorkerPeer::doSelect($c, myDbHelper::getConnection(myDbHelper::DB_HELPER_CONN_PROPEL2));
     $newList = KalturaSchedulerWorkerArray::fromDbArray($list, $this->getResponseProfile());
     $response = new KalturaSchedulerWorkerListResponse();
     $response->objects = $newList;
     $response->totalCount = $count;
     return $response;
 }
Ejemplo n.º 2
0
 /**
  * @param Scheduler $dbData
  * @return KalturaScheduler
  */
 public function statusFromObject($dbData)
 {
     $this->fromObject($dbData);
     $this->workers = KalturaSchedulerWorkerArray::statusFromSchedulerWorkerArray($dbData->getWorkers());
     $this->configs = KalturaSchedulerConfigArray::fromDbArray($dbData->getConfigs());
     return $this;
 }