Ferreteria/v0.3/class/cPortalRow: Difference between revisions

From Woozle Writes Code
< Ferreteria‎ | v0.3‎ | class
Jump to navigation Jump to search
(Created page with "{{page/code/class|ferreteria}} <source lang=php> abstract class cPortalRow { public function __construct(cIORow $rs) { protected function SetRowObject(cIORow $rs) {...")
 
m (4 revisions imported: moving this project here)
 
(3 intermediate revisions by one other user not shown)
Line 2: Line 2:
<source lang=php>
<source lang=php>
abstract class cPortalRow {
abstract class cPortalRow {
     public function __construct(cIORow $rs) {
 
     protected function SetRowObject(cIORow $rs) {
     public function __construct(cFieldRow $rs) { $this->SetRowObject($rs); }
     // PUBLIC because some operations return PortalRow objects and we need to get back to the Row object
     protected function SetRowObject(cFieldRow $rs) { $this->rs = $rs; }
     public function GetRowObject() : cIORow {
     /*----
     abstract protected function GetPortalType();
      PUBLIC because some operations return PortalRow objects and we need to get back to the Row object
    abstract protected function SetPortals_fromFields(array $arFields);
    */
    protected function GetPortal($sKey) : cFieldPortal {
     public function GetRowObject() : cFieldRow { return $this->rs; }
     abstract protected function GetPortalType(); // child classes return constants from cIOField
     /*----
     /*----
       ACTION: load the row from portal's external format
       ACTION: load the row from portal's external format

Latest revision as of 16:43, 22 May 2022

Template:Page/code/class

abstract class cPortalRow {

    public function __construct(cFieldRow $rs) { $this->SetRowObject($rs); }
    protected function SetRowObject(cFieldRow $rs) { $this->rs = $rs; }
    /*----
      PUBLIC because some operations return PortalRow objects and we need to get back to the Row object
    */
    public function GetRowObject() : cFieldRow { return $this->rs; }
    abstract protected function GetPortalType();  // child classes return constants from cIOField
    /*----
      ACTION: load the row from portal's external format
        and delete any values not specified in the input
      PUBLIC so flow controllers can use it
    */
    public function LoadRow_fromArray(array $ar) {
}