C_Display_Type

A Display Type is a component which renders a collection of images in a "gallery".

Defined (1)

The class is defined in the following location(s).

/products/photocrati_nextgen/modules/nextgen_gallery_display/package.module.nextgen_gallery_display.php  
  1. class C_Display_Type extends C_DataMapper_Model 
  2. var $_mapper_interface = 'I_Display_Type_Mapper'; 
  3. function define($properties = array(), $mapper = FALSE, $context = FALSE) 
  4. parent::define($mapper, $properties, $context); 
  5. $this->add_mixin('Mixin_Display_Type_Validation'); 
  6. $this->add_mixin('Mixin_Display_Type_Instance_Methods'); 
  7. $this->implement('I_Display_Type'); 
  8. /** 
  9. * Initializes a display type with properties 
  10. * @param FALSE|C_Display_Type_Mapper $mapper 
  11. * @param array|stdClass|C_Display_Type $properties 
  12. * @param FALSE|string|array $context 
  13. */ 
  14. function initialize($properties = array(), $mapper = FALSE, $context = FALSE) 
  15. // If no mapper was specified, then get the mapper 
  16. if (!$mapper) { 
  17. $mapper = $this->get_registry()->get_utility($this->_mapper_interface); 
  18. // Construct the model 
  19. parent::initialize($mapper, $properties); 
  20. /** 
  21. * Allows a setting to be retrieved directly, rather than through the 
  22. * settings property 
  23. * @param string $property 
  24. * @return mixed 
  25. */ 
  26. function &__get($property) 
  27. if (isset($this->settings) && isset($this->settings[$property])) { 
  28. $retval =& $this->settings[$property]; 
  29. return $retval; 
  30. } else { 
  31. return parent::__get($property);