Class ReportElementHandle

    • Field Detail

      • element

        protected org.eclipse.birt.report.model.core.DesignElement element
        The target report element.
    • Constructor Detail

      • ReportElementHandle

        public ReportElementHandle​(org.eclipse.birt.report.model.core.Module module,
                                   org.eclipse.birt.report.model.core.DesignElement element)
        Constructs the handle for a report element with the given design and element. The application generally does not create handles directly. Instead, it uses one of the navigation methods available on other element handles.
        Parameters:
        module - the module
        element - the model representation of the element
    • Method Detail

      • getElement

        public org.eclipse.birt.report.model.core.DesignElement getElement()
        Description copied from class: DesignElementHandle
        Returns the element to which this handle is attached.
        Specified by:
        getElement in class DesignElementHandle
        Returns:
        The attached element. Will be null if the handle is not attached.
      • propertyMaskIterator

        public java.util.Iterator propertyMaskIterator()
        Returns property masks on this element. This method follows these rules:
        • If any property mask exists on this element, returns property mask list of itself.
        • If no property masks on this element, returns property mask list of its parent.
        Returns:
        the iterator of property mask structure list
        See Also:
        getPropertyMask(String)
      • getPropertyMask

        public java.lang.String getPropertyMask​(java.lang.String propName)
        Returns the mask of the specified property given its internal name. This method follows these rules:
        • If the mask of a specified property is defined on this element, returns the mask value.
        • If the mask of a specified property is not defined on this element, returns the mask value inherited from its ancestor.
        • null is returned if no mask value defined on this property.

        The optional mask values are defined in DesignChoiceConstants. and they are

        • PROPERTYMASK_TYPE_CHANGE
        • PROPERTYMASK_TYPE_LOCK
        • PROPERTYMASK_TYPE_HIDE
        Parameters:
        propName - the name of the property to get. Can be a system-defined or user-defined property name.
        Returns:
        the property mask, or null if the mask is not set.
        See Also:
        DesignChoiceConstants
      • setPropertyMask

        public void setPropertyMask​(java.lang.String propName,
                                    java.lang.String maskValue)
                             throws SemanticException
        Sets the mask of the specified property. The mask values are defined in DesignChoiceConstants and they are:
        • PROPERTYMASK_TYPE_CHANGE
        • PROPERTYMASK_TYPE_LOCK
        • PROPERTYMASK_TYPE_HIDE

        Note it is not allowed to set the mask on PROPERTY_MASKS_PROP. This method does nothing for this situation.

        Parameters:
        propName - the property name to get. Can be a system-defined or user-defined property name.
        maskValue - the mask value
        Throws:
        SemanticException - if the maskValue is not one of the above.
        See Also:
        DesignChoiceConstants
      • setDisplayNameKey

        public void setDisplayNameKey​(java.lang.String displayNameKey)
                               throws SemanticException
        Sets the resource key of the display name.
        Parameters:
        displayNameKey - the resource key of the display name
        Throws:
        SemanticException - if the display name resource-key property is locked or not defined on this element.
      • getDisplayNameKey

        public java.lang.String getDisplayNameKey()
        Gets the resource key of the display name.
        Returns:
        the resource key of the display name
      • setDisplayName

        public void setDisplayName​(java.lang.String displayName)
                            throws SemanticException
        Sets the display name.
        Parameters:
        displayName - the display name
        Throws:
        SemanticException - if the display name property is locked or not defined on this element.
      • getDisplayName

        public java.lang.String getDisplayName()
        Gets the display name.
        Returns:
        the display name
      • setCustomXml

        public void setCustomXml​(java.lang.String customXml)
                          throws SemanticException
        Sets the custom XML.
        Parameters:
        customXml - the custom XML to set
        Throws:
        SemanticException - if the custom XML is locked or not defined on this element.
      • getCustomXml

        public java.lang.String getCustomXml()
        Gets the custom XML.
        Returns:
        the custom XML
      • setComments

        public void setComments​(java.lang.String theComments)
                         throws SemanticException
        Sets the comments of the report element.
        Parameters:
        theComments - the comments to set
        Throws:
        SemanticException - if the comments property is locked or not defined on this element.
      • getComments

        public java.lang.String getComments()
        Gets the comments of the report element.
        Returns:
        the comments of the report element
      • isValidReferenceForCompoundElement

        @Deprecated
        public boolean isValidReferenceForCompoundElement()
        Deprecated.
        Checks whether the compound element is valid if the element has no extends property value or if the current element is compound elements and extends value is unresovled.
        Returns:
        true if the compound element is valid. Otherwise false.
      • isValidLayoutForCompoundElement

        public boolean isValidLayoutForCompoundElement()
        Checks whether the compound element is valid. If a table/grid has no rows/columns, it is invalid. If the table has overlapped areas, it is invalid.
        Returns:
        true if the compound element is valid. Otherwise false.