Gpf_Rpc_Data::__construct PHP Method

__construct() public method

Create instance to handle DataRequest
public __construct ( Gpf_Rpc_Params $params = null )
$params Gpf_Rpc_Params
        public function __construct(Gpf_Rpc_Params $params = null)
        {
            if ($params === null) {
                $params = new Gpf_Rpc_Params();
            }
            $this->filters = new Gpf_Rpc_FilterCollection($params);
            $this->params = new Gpf_Data_IndexedRecordSet(self::NAME);
            $this->params->setHeader(array(self::NAME, self::VALUE));
            if ($params->exists(self::DATA) !== null) {
                $this->loadParamsFromArray($params->get(self::DATA));
            }
            $this->id = $params->get(self::ID);
            $this->response = new Gpf_Data_IndexedRecordSet(self::NAME);
            $this->response->setHeader(array(self::NAME, self::VALUE));
        }