Mage_Directory_Model_Region Class Reference

Inheritance diagram for Mage_Directory_Model_Region:

Mage_Core_Model_Abstract Varien_Object

List of all members.

Public Member Functions

 getName ()
 loadByCode ($code, $countryId)
 loadByName ($name, $countryId)

Protected Member Functions

 _construct ()


Detailed Description

Definition at line 34 of file Region.php.


Member Function Documentation

_construct (  )  [protected]

Enter description here...

Reimplemented from Varien_Object.

Definition at line 36 of file Region.php.

00037     {
00038         $this->_init('directory/region');
00039     }

getName (  ) 

Retrieve region name

If name is no declared, then default_name is used

Returns:
string

Definition at line 48 of file Region.php.

00049     {
00050         $name = $this->getData('name');
00051         if (is_null($name)) {
00052             $name = $this->getData('default_name');
00053         }
00054         return $name;
00055     }

loadByCode ( code,
countryId 
)

Definition at line 57 of file Region.php.

00058     {
00059         if ($code) {
00060             $this->_getResource()->loadByCode($this, $code, $countryId);
00061         }
00062         return $this;
00063     }

loadByName ( name,
countryId 
)

Definition at line 65 of file Region.php.

00066     {
00067         $this->_getResource()->loadByName($this, $name, $countryId);
00068         return $this;
00069     }


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

Generated on Sat Jul 4 17:24:07 2009 for Magento by  doxygen 1.5.8