Perforce Chronicle 2012.2/486814
API Documentation

History_Form_HistoryGridOptions Class Reference

This is the History grid options form. More...

Inheritance diagram for History_Form_HistoryGridOptions:
Ui_Form_GridOptions P4Cms_Form_PubSubForm P4Cms_Form

List of all members.

Public Member Functions

 getChanges ()
 Return the list of changes for the record that has been set for this form (or null if no record has been set).
 getRecord ()
 Return record the form is constructed for.
 setRecord (P4Cms_Record $record=null)
 Set record for this form.

Protected Attributes

 $_changes = null
 $_record = null

Detailed Description

This is the History grid options form.

Copyright:
2011-2012 Perforce Software. All rights reserved
License:
Please see LICENSE.txt in top-level folder of this distribution.
Version:
2012.2/486814

Member Function Documentation

History_Form_HistoryGridOptions::getChanges ( )

Return the list of changes for the record that has been set for this form (or null if no record has been set).

List with changes is stored in memory until the record is changed or reset.

Returns:
P4_Model_Iterator|null the list of changes or null
    {
        if ($this->_changes === null && $this->_record !== null) {
            $this->_changes = $this->_record->toP4File()->getChanges();
        }

        return $this->_changes;
    }
History_Form_HistoryGridOptions::getRecord ( )

Return record the form is constructed for.

Returns:
P4Cms_Record|null record for this form or null
    {
        return $this->_record;
    }
History_Form_HistoryGridOptions::setRecord ( P4Cms_Record record = null)

Set record for this form.

Parameters:
P4Cms_Record$recordrecord the form is constructed for.
    {
        $this->_record = $record;

        // reset changes to force re-generating list of changes at next getChanges() call
        $this->_changes = null;
    }

Member Data Documentation

History_Form_HistoryGridOptions::$_changes = null [protected]
History_Form_HistoryGridOptions::$_record = null [protected]

The documentation for this class was generated from the following file: