protected static function getReferencedEnums() { $ref_enums = array(); $ref_enums['EventType'] = AdActivityEventTypeValues::getInstance()->getValues(); $ref_enums['Category'] = AdActivityCategoryValues::getInstance()->getValues(); return $ref_enums; }
public function getActivities(array $fields = array(), array $params = array(), $pending = false) { $this->assureId(); $param_types = array('add_children' => 'bool', 'business_id' => 'string', 'category' => 'category_enum', 'extra_oids' => 'list<string>', 'oid' => 'string', 'since' => 'datetime', 'uid' => 'int', 'until' => 'datetime'); $enums = array('category_enum' => AdActivityCategoryValues::getInstance()->getValues()); $request = new ApiRequest($this->api, $this->data['id'], RequestInterface::METHOD_GET, '/activities', new AdActivity(), 'EDGE', AdActivity::getFieldsEnum()->getValues(), new TypeChecker($param_types, $enums)); $request->addParams($params); $request->addFields($fields); return $pending ? $request : $request->execute(); }