ilog.rules.shared.bom

Interface IlrBOMDomainValueProvider

  • All Known Subinterfaces:
    IlrBOMDomainValueProvider
    All Known Implementing Classes:
    IlrPropertyBOMDomainValueProvider, IlrPropertyBOMDomainValueProvider, IlrResourceDomainProvider


    public interface IlrBOMDomainValueProvider
    This interface specifies the API that must be implemented by a Domain Value Provider. A Domain Value Provider is used to dynamically creates a new BOM enumerated domain for a given class. The getValues() method will be called first, then the caller will iterate on each returned values and will call the getters available in this interface, and then dispose() will be called.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      void dispose()
      This method is called when the caller have finished to iterate on values returned by this provider
      java.lang.String getBOM2XOMMapping(java.lang.String valueName)
      Domain value are generated as field of the class interfaced by this BOM Domain value provider and this method returns the B2X associated to this field.
      java.lang.String getDisplayText(java.lang.String valueName, java.util.Locale locale) 
      java.lang.String getDocumentation(java.lang.String valueName, java.util.Locale locale) 
      java.util.Map getProperties(java.lang.String valueName) 
      java.lang.String getTranslation(java.lang.String valueName) 
      java.util.Collection getValues(IlrClass clazz)
      This method returns all values that will be used to create the enumerated domain for the given class
    • Method Detail

      • getValues

        java.util.Collection getValues(IlrClass clazz)
        This method returns all values that will be used to create the enumerated domain for the given class
        Parameters:
        clazz - the class that will host the new enumerated domain
        Returns:
        a list of String representing the name of each value of the enumerated domain. For each value, the caller will call APIs provided by this interface to actually create the value in the enumerated domain. The names returned must be java compliant identifiers.
      • getDisplayText

        java.lang.String getDisplayText(java.lang.String valueName,
                                      java.util.Locale locale)
        Returns:
        the label of the domain value identified by the given name. The returned label is used to create the corresponding element in the vocabulary of the given locale
      • getTranslation

        java.lang.String getTranslation(java.lang.String valueName)
        Returns:
        the IRL translation of the domain value identified by the given name
      • getBOM2XOMMapping

        java.lang.String getBOM2XOMMapping(java.lang.String valueName)
        Domain value are generated as field of the class interfaced by this BOM Domain value provider and this method returns the B2X associated to this field. Usually, either Translation or B2X is used to support the domain value at execution time, but not both.
        Returns:
        the B2X code that maps the given domain value to its XOM counter-part. This method may return null.
      • getProperties

        java.util.Map getProperties(java.lang.String valueName)
        Returns:
        a map of properties for the domain value identified by the given name. This method may return null.
      • getDocumentation

        java.lang.String getDocumentation(java.lang.String valueName,
                                        java.util.Locale locale)
        Returns:
        the documentation of the domain value identified by the given name. This method may return null.
      • dispose

        void dispose()
        This method is called when the caller have finished to iterate on values returned by this provider

© Copyright IBM Corp. 1987, 2017