Class ConversionParameters

java.lang.Object
de.hybris.platform.odata2services.converter.ConversionParameters

public class ConversionParameters extends Object
Parameters providing context for converting an attribute value in the payload. Depending on the attribute type the value may be converted into a collection of primitives or of IntegrationItems, or a primitive, an IntegrationItem, a Map, etc. value.
  • Method Details

    • getAttributeName

      public String getAttributeName()
      Retrieves name of the attribute, whose value is being converted.
      Returns:
      name of the attribute to convert value for.
    • getAttributeValue

      public Object getAttributeValue()
      Retrieves value to be converted.
      Returns:
      value the attribute has in ODataEntry and, which has to be converted to be acceptable by OData independent IntegrationItem.
    • getContext

      public org.apache.olingo.odata2.api.processor.ODataContext getContext()
      Retrieves OData request context.
      Returns:
      OData context describing the request.
    • getIntegrationItem

      public IntegrationItem getIntegrationItem()
      Retrieves IntegrationItem, in which the converted attribute value will be set.
      Returns:
      item to set converted value to.
    • getTypeAttributeDescriptor

      public TypeAttributeDescriptor getTypeAttributeDescriptor()
      Retrieves type descriptor for the attribute to set in the IntegrationItem
      Returns:
      type descriptor for the attribute to set, if the ODataEntry attribute exists in the corresponding type in the type system or null otherwise.
      See Also:
    • getTypeDescriptor

      public TypeDescriptor getTypeDescriptor()
      Retrieves type descriptor for the type in the type system corresponding to the ODataEntry being converted.
      Returns:
      IntegrationItem type.
      See Also:
    • getContentLocale

      public Locale getContentLocale()
      Specifies the request content language.
      Returns:
      a locale corresponding to the value specified in the Content-Language header or the default system locale, if the content language was not specified explicitly.
      See Also:
    • isMapAttributeValue

      public boolean isMapAttributeValue()
      Determines whether the ODataEntry attribute being converted corresponds to a Map attribute in the platform.
      Returns:
      true, if the context attribute is a Map attribute in the type system; false otherwise.
    • isContentLanguagePresent

      public boolean isContentLanguagePresent()
      Determines whether Content-Language was explicitly specified for the request.
      Returns:
      true, if the Content-Language is present in the request; false, otherwise.