Interface AttributeManager

    • Method Detail

      • setAttributeTypeCode

        void setAttributeTypeCode​(java.lang.String strCode)
        Define the attribute Type code
        Parameters:
        strCode - The Attribute Type Code
      • getAttributeTypeCode

        java.lang.String getAttributeTypeCode()
        Return the attribute Type code
        Returns:
        The Attribute Type Code
      • getCreateFormHtml

        java.lang.String getCreateFormHtml​(DocumentAttribute attribute,
                                           java.util.Locale locale,
                                           java.lang.String strBaseUrl)
        Gets the part of an HTML form to enter attribute data
        Parameters:
        attribute - The attribute
        locale - The current Locale
        strBaseUrl - the base url
        Returns:
        A part of the HTML form
      • getModifyFormHtml

        java.lang.String getModifyFormHtml​(DocumentAttribute attribute,
                                           Document document,
                                           java.util.Locale locale,
                                           java.lang.String strBaseUrl)
        Gets the part of an HTML form to modify attribute data
        Parameters:
        attribute - The attribute
        document - The attribute document
        locale - The current Locale
        strBaseUrl - The base url
        Returns:
        A part of the HTML form
      • getCreateParametersFormHtml

        java.lang.String getCreateParametersFormHtml​(java.util.Locale locale)
        Gets the part of an HTML form to enter parameters data
        Parameters:
        locale - The current Locale
        Returns:
        A part of the HTML form
      • getCreateParametersFormHtml

        java.lang.String getCreateParametersFormHtml​(java.util.List<AttributeTypeParameter> listParameters,
                                                     java.util.Locale locale)
        Gets the part of an HTML form to enter parameters data
        Parameters:
        listParameters - list attribute type parameters
        locale - The current Locale
        Returns:
        A part of the HTML form
      • getModifyParametersFormHtml

        java.lang.String getModifyParametersFormHtml​(java.util.Locale locale,
                                                     int nAttributeId)
        Gets the part of an HTML form to modify parameters data
        Parameters:
        locale - The current Locale
        nAttributeId - Attribute Id
        Returns:
        A part of the HTML form
      • getExtraParameters

        java.util.List<AttributeTypeParameter> getExtraParameters​(java.util.Locale locale)
        Gets extra parameters for the attribute
        Parameters:
        locale - The current Locale
        Returns:
        A collection of attribute parameters
      • getExtraParametersValues

        java.util.List<AttributeTypeParameter> getExtraParametersValues​(java.util.Locale locale,
                                                                        int nAttributeId)
        Gets extra parameters values for the attribute
        Parameters:
        locale - The current Locale
        nAttributeId -
        Returns:
        The extra parameters values for the attribute
      • validateValue

        java.lang.String validateValue​(int nAttributeId,
                                       java.lang.String strValue,
                                       java.util.Locale locale)
        Validate the value for the attribute
        Parameters:
        nAttributeId - The attribute identifier
        strValue - The value to check
        locale - The current Locale
        Returns:
        null if valid, otherwise error message
      • validateValueParameters

        java.lang.String validateValueParameters​(java.util.List<AttributeTypeParameter> listParameters,
                                                 java.util.Locale locale)
        Validate the value for the parameters
        Parameters:
        listParameters - The list of parameters to check
        locale - The locale
        Returns:
        null if valid, otherwise message property
      • getAttributeXmlValue

        java.lang.String getAttributeXmlValue​(Document document,
                                              DocumentAttribute attribute)
        Get the XML data corresponding to the attribute to build the docuemnt XML content
        Parameters:
        document - The document
        attribute - The attribute
        Returns:
        The XML value of the attribute
      • canBeUsedAsThumbnail

        boolean canBeUsedAsThumbnail()
        Tells if the attrubute can be used as Thumbnail (image)
        Returns:
        true if the attrubute can be used as Thumbnail, otherwise false
      • getValueParameters

        java.util.List<AttributeTypeParameter> getValueParameters​(javax.servlet.http.HttpServletRequest request,
                                                                  java.util.Locale locale)
        Get the value parameters
        Parameters:
        request - the HTTP request
        locale - the locale
        Returns:
        a list of AttributeTypeParameter