Bug 122850 Table/list should not be able to be inserted in Master Page mode.
Description: Table/list should not be able to be inserted in Master Page mode. Steps to reproduce: 1. New a report and transfer to Master Page mode. 2. New a datasource and dataset 3. Drag a list/table to page header/footer, bind it to dataset and drag some columns inside. 4. Save and preview Expected result: Insert list/table item in master page should be forbidden. Actual result: They are allowed and preview showed "undefine" in page
model/org.eclipse.birt.report.model/src/org/eclipse/birt/report/model/util/ModelUtil.java
import org.eclipse.birt.report.model.elements.interfaces.IOdaExtendableElementModel;
import org.eclipse.birt.report.model.extension.IExtendableElement;
import org.eclipse.birt.report.model.i18n.ModelMessages;
import org.eclipse.birt.report.model.i18n.ThreadResources;
import org.eclipse.birt.report.model.metadata.ElementPropertyDefn;
import org.eclipse.birt.report.model.metadata.ElementRefValue;
import org.eclipse.birt.report.model.metadata.PropertyDefn;
import org.eclipse.birt.report.model.metadata.PropertyType;
import org.eclipse.birt.report.model.metadata.ReferenceValue;
import org.eclipse.birt.report.model.metadata.StructRefValue;
import org.eclipse.birt.report.model.parser.DesignParserException;
import org.xml.sax.SAXException;
/**
 * The utility class which provides many static methods used in Model.
 */
public class ModelUtil
{
	/**
	 * Returns the id reference relationship between the parent element and the
	 * child element.
	 * <p>
	 * Notice: the element and its parent should have the same structure when
	 * calling this method. That is the child structure has already been
	 * refreshed from parent.
	 * 
	 * @param element
	 *            the element to setup the id reference
	 * @return a map to store the base id and the corresponding child element.
	 */
	public static Map getIdMap( DesignElement element )