/** * Construct a openTrans order * * @param string type */ public function __construct($type) { parent::__construct(self::DOCUMENT_TYPE_ORDER); if (!is_string($type)) { throw new rs_opentrans_exception('$type must be a string.'); } if (!in_array($type, self::$valid_types)) { throw new rs_opentrans_exception('Unsupported type "' . $type . '".'); } $this->type = $type; $this->set_summary(new rs_opentrans_document_summary_order(0)); }
/** * Construct a openTrans orderchange */ public function __construct() { parent::__construct(self::DOCUMENT_TYPE_ORDERCHANGE); $this->summary = new rs_opentrans_document_summary_order(0); }