List all jobs on your account

@param array  $args    Array of filters to use when loading index
@param array  $params  Optional overrides

@return array An array of Services_Zencoder_Job objects
436035
public function index($args = array(), $params = array()) {
    $jobs = $this->proxy->retrieveData("jobs.json", $args, $params);
    $results = array();
    foreach($jobs as $job) $results[] = new Services_Zencoder_Job($job);
    return $results;
  }
484495
public function getPaginationList($params)
    {
        $qb = $this->getPaginationQueryBuilder($params);
        $cursor = $qb->hydrate(false)
                     ->select('_id')
                     ->getQuery()
                     ->execute();
        
        $list = new PaginationList(array_keys(ArrayUtils::iteratorToArray($cursor)));
        return $list;
    }
51035
public function all(array $params = array())
    {
        $data = $this->request('/admin/application_charges.json', 'GET', $params);
        return $this->createCollection(ApplicationCharge::class, $data['application_charges']);
    }
519634
public static function all(array $arg_params)
    {
        //validate params
        $data = self::getParams($arg_params);
        $url = '/ecommerce/transactions';
        $filters = '';
        if(!empty($data['page'])&&ctype_digit($data['page'])){
            $filters .= 'page='.$data['page'];
        }
        if(!empty($filters))$filters='?'.$filters;

        //submit to api
        $transactions_data = APIRequests::request(
            $url.$filters,
            APIRequests::METHOD_GET
        );

        //return response
        return self::toListObj($transactions_data['body']);
    }
690804
private function filterParameters(array $params): array
    {
        return
            array_filter(
                $params,
                function (&$value) {
                    if (is_array($value)) {
                        $value = $this->filterParameters($value);

                        return count($value) > 0;
                    } else {
                        return !is_null($value);
                    }
                }
            );
    }
519830
public function findJob($command, array $args = [])
    {
        return $this->_em->createQuery('SELECT j FROM JMSJobQueueBundle:Job j WHERE j.command = :command AND j.args = :args')
            ->setParameter('command', $command)
            ->setParameter('args', $args, Type::JSON_ARRAY)
            ->setMaxResults(1)
            ->getOneOrNullResult();
    }
75006
public function index($params = [])
    {
        // Set the filters
        $params = (!empty($params))? $params : $this->app->request->input();

        // Get records
        $this->model->params = $params;
        $result = $this->model->search($params)->get();

        // Get pagination and number of records
        $pagination = array_merge(
            ['records' => $this->model->search($params)->count()],
            $this->model->pagination()
        );

        // Return results
        return [
            'success' => true,
            'paging' => $pagination,
            'data' => $result
        ];
    }
964194
public function searchJobs(SearchJobsParameters $parameters)
    {
        $requestData = $this->getDefaultRequestData('json', $parameters->exportToArray());
        return $this->sendRequest('jobs/search', $requestData, self::HTTP_METHOD_POST);
    }
258008
protected function parseArguments(array $args)
    {
        $output = [];

        foreach ($args as $arg) {
            if (is_string($arg) && strpos($arg, '@') === 0) {
                $service = substr($arg, 1);
                $output[] = $this->container->get($service);

                continue;
            }

            $output[] = $arg;
        }

        return $output;
    }
590006
protected function getServiceByArgs($args) {
		$args = $this->normalizeArgs($args);
		$id   = $this->getIdByArgs($args);
		$args = $this->processArgs($args);
			
		if (! isset($this->servicesByArgs[$id])) {
			$this->servicesByArgs[$id] = $this->initService($args);
		}

		return $this->servicesByArgs[$id];
	}
1133173
public function actionList($aParams = array())
    {
        $oData = $this->mapper()->find();
        $aParams = array(
            'Data' => $oData
        );

        return $this->view('List', $aParams);
    }
1061654
public function all(array $params = array())
    {
        $data = $this->request('/admin/application_credits.json', 'GET', $params);
        return $this->createCollection(ApplicationCredit::class, $data['application_credits']);
    }
168440
public static function create(array $args)
    {
        $job = new Job($args['body']);

        if (isset($args['id'])) {
            $job->setId($args['id']);
            $job->setTtl(hexdec(substr($job->getId(), -4)));
        }

        if (isset($args['queue'])) {
            $job->setQueue($args['queue']);
        }

        if (isset($args['ttl'])) {
            $job->setTtl($args['ttl']);
        }

        if (isset($args['retry'])) {
            $job->setRetry($args['retry']);
        }

        return $job;
    }
870083
public function getEntities(array $args = [])
    {
        // @todo - use permission base to exclude secure if necessary.
        $replacementFilter = [
            'column' => 'f.object',
            'expr'   => 'neq',
            'value'  => ['company'],
        ];
        foreach ($args as $type => &$arg) {
            if ('filter' === $type) {
                foreach ($arg as $key => &$filter) {
                    if ('force' === $key) {
                        foreach ($filter as $forceKey => &$forceFilter) {
                            if (
                                !empty($forceFilter['column'])
                                && 'f.object' == $forceFilter['column']
                                && !empty($forceFilter['expr'])
                                && 'eq' == $forceFilter['expr']
                                && !empty($forceFilter['value'])
                                && 'lead' == $forceFilter['value']
                            ) {
                                $forceFilter = $replacementFilter;
                            }
                        }
                    } elseif ('object' === $key && 'lead' === $filter) {
                        // Move the filter to force mode in order to replace.
                        if (!isset($arg['force'])) {
                            $arg['force'] = [];
                        }
                        $arg['force'][] = $replacementFilter;
                        unset($arg[$key]);
                    }
                }
            }
        }

        return parent::getEntities($args);
    }
928210
public function all(array $params = array())
    {
        $endpoint = '/admin/themes.json';
        $response = $this->request($endpoint, 'GET', $params);
        return $this->createCollection(Theme::class, $response['themes']);
    }
712844
protected function encodeArray(array $args): array
    {
        foreach ($args as $key => $value) {
            if (is_object($value)) {
                $args[$key] = get_class($value);
            }
        }
        return $args;
    }
587903
public function afterFetch(Array &$args) {
        $model = $args[0];
        $results = $args[1];
        $table = $model->getName();
        $chartService = new Garp_Service_Google_Chart();
        $ini = Garp_Config_Ini::getCached(APPLICATION_PATH.'/configs/routes.ini');
        $routes = $ini->routes->toArray();
        $view = Zend_Controller_Front::getInstance()->getParam('bootstrap')->getResource('view');

        $routeFound = false;
        foreach ($routes as $r) {
            if (
                array_key_exists('route', $r) &&
                $r['route'] === '/'.$table.'/:slug'
            ) {
                $routeFound = $r;
                break;
            }
        }

        if (!$routeFound) {
            throw new Exception('There is no direct route to this object.');
        }

        // provide uniform interface, so we can always loop
        if (!$results instanceof Garp_Db_Table_Rowset) {
            $results = array($results);
        }

        foreach ($results as $row) {
            if (
                isset($row->slug) &&
                $row->slug
            ) {
                $refUrl = $view->fullUrl('/'.$table.'/'.$row->slug);
                $row->setVirtual('qrcode', $chartService->fetchQRCodeUrl($refUrl));
            }
        }

        // return the pointer to 0
        if ($results instanceof Garp_Db_Table_Rowset) {
            $results->rewind();
        } else {
        // also, return results to the original format if it was no Rowset to begin with.
            $results = $results[0];
        }
    }