Class LocalizedAttributes


  • public class LocalizedAttributes
    extends java.lang.Object
    Localized attributes values for a given EDM type. For example, if a Product has localized attributes, then the localized attributes will be captured in a Localized___Product EDM type. This class represents the Localized___... EDM types.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.Map<java.lang.String,​LocalizedValue> attributes  
      static LocalizedAttributes EMPTY
      An empty LocalizedAttributes object that does not contain a single attribute value.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static LocalizedAttributes createFrom​(org.apache.olingo.odata2.api.ep.entry.ODataEntry entry)
      Creates instance of LocalizedAttributes and populates it from the provided OData entry
      boolean equals​(java.lang.Object o)  
      void forEachAttribute​(java.util.function.BiConsumer<? super java.lang.String,​? super LocalizedValue> action)
      Performs the given action for each entry in this map until all entries have been processed or the action throws an exception.
      int hashCode()  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • EMPTY

        public static final LocalizedAttributes EMPTY
        An empty LocalizedAttributes object that does not contain a single attribute value.
      • attributes

        protected final java.util.Map<java.lang.String,​LocalizedValue> attributes
    • Method Detail

      • createFrom

        public static LocalizedAttributes createFrom​(org.apache.olingo.odata2.api.ep.entry.ODataEntry entry)
        Creates instance of LocalizedAttributes and populates it from the provided OData entry
        Parameters:
        entry - an entry that corresponds to the 'Localized___...' type.
        Returns:
        an instance with all localized attributes present in the OData entry
      • forEachAttribute

        public void forEachAttribute​(java.util.function.BiConsumer<? super java.lang.String,​? super LocalizedValue> action)
        Performs the given action for each entry in this map until all entries have been processed or the action throws an exception. Actions are performed in the order of entry set iteration. Exceptions thrown by the action are relayed back to the caller.
        Parameters:
        action - The action to be performed for each entry
        Throws:
        java.lang.NullPointerException - if the specified action is null
        java.util.ConcurrentModificationException - if an entry is found to be removed during iteration
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object