Class JsonRowMap

  • All Implemented Interfaces:
    java.util.Map<java.lang.String,​java.lang.Object>

    public class JsonRowMap
    extends java.util.AbstractMap<java.lang.String,​java.lang.Object>
    Class representing a row of data as a map. This class parses JSON row data in the 8+ webservice API version format (ie. a simple array of values such as [1, "foo", null, true, 1.23]).
    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.util.AbstractMap

        java.util.AbstractMap.SimpleEntry<K extends java.lang.Object,​V extends java.lang.Object>, java.util.AbstractMap.SimpleImmutableEntry<K extends java.lang.Object,​V extends java.lang.Object>
      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Constructor Summary

      Constructors 
      Constructor Description
      JsonRowMap​(java.lang.String json, java.util.List<java.lang.String> views)
      Construct a result-row with a String as its backing data store.
      JsonRowMap​(org.json.JSONArray ja, java.util.List<java.lang.String> views)
      Construct a result-row with a JSONArray as its backing data store.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Set<java.util.Map.Entry<java.lang.String,​java.lang.Object>> entrySet()  
      java.lang.Object get​(java.lang.Object key)  
      • Methods inherited from class java.util.AbstractMap

        clear, clone, containsKey, containsValue, equals, hashCode, isEmpty, keySet, put, putAll, remove, size, toString, values
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map

        compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
    • Constructor Detail

      • JsonRowMap

        public JsonRowMap​(org.json.JSONArray ja,
                          java.util.List<java.lang.String> views)
        Construct a result-row with a JSONArray as its backing data store.
        Parameters:
        ja - The source of the data.
        views - The column names.
      • JsonRowMap

        public JsonRowMap​(java.lang.String json,
                          java.util.List<java.lang.String> views)
        Construct a result-row with a String as its backing data store.
        Parameters:
        json - The source of the data.
        views - The column names.
    • Method Detail

      • entrySet

        public java.util.Set<java.util.Map.Entry<java.lang.String,​java.lang.Object>> entrySet()
        Specified by:
        entrySet in interface java.util.Map<java.lang.String,​java.lang.Object>
        Specified by:
        entrySet in class java.util.AbstractMap<java.lang.String,​java.lang.Object>
      • get

        public java.lang.Object get​(java.lang.Object key)
        Specified by:
        get in interface java.util.Map<java.lang.String,​java.lang.Object>
        Overrides:
        get in class java.util.AbstractMap<java.lang.String,​java.lang.Object>