<?php

require_once 'orm/mapping/OrmMapElement.php';

/**
 * Base map's collection elements class.
 * 
 * This class defines the base for all other map's collection elements.
 * Collection elements can hold a map with other elements, in 'fields' attrib.
 * 
 * @author  $Author: pruna $
 * @package orm/mapping
 * @version $Revision: 1.3 $
 * @created 02-Apr-2005
 * @modified $Date: 2005/12/06 02:56:45 $
 */
class OrmMapElementCollection extends OrmMapElement {
    
    /**
     * Constructor that defines basic properties for this Bean.
     * 
     * It follows Collection rules for constructor.
     * Basic elements are: 
     * <ul>
     * <li>table: table's name (string)</li>
     * <li>tableAlias: table's name alias (string)</li>
     * <li>class: class name (string)</li>
     * <li>propertyRef: field referenced on related table (string)</li>
     * <li>map: map's file name (string)</li>
     * <li>cascade: list of actions to cascade to the other table (string)</li>
     * <li>lazy: if does lazy loading (boolean - default: false)</li>
     * <li>fields: Map containing internal elements (object)</li>
     * </ul>
     * Default values may serve as guide for preferred data types.
     * For a full description about this elements, see @docs
     * 
     * @access  public
     * @param   ICollection    $collection    Initial elements
     */
    public function __construct($collection = null) {
        parent::__construct(array(
            'table' => null,
            'tableAlias' => null,
            'class' => null,
            'propertyRef' => null,
            'map' => null,
            'cascade' => array(),
            'lazy' => FALSE,
            'fields' => null,
        ));
        $this->setAll($collection);
    }
   
}

?>