Class ResultRowList

  • All Implemented Interfaces:
    java.lang.Iterable<java.lang.Object>, java.util.Collection<java.lang.Object>, java.util.List<java.lang.Object>

    public class ResultRowList
    extends java.lang.Object
    implements java.util.List<java.lang.Object>, java.lang.Iterable<java.lang.Object>
    A representation of a result row that allows parsed objects to be retrieved by index, where the order of elements is the same as that of the view list of the originating PathQuery.
    • Constructor Summary

      Constructors 
      Constructor Description
      ResultRowList​(java.lang.String input)
      Construct a new result row object backed by the JSONArray which can be parsed from the given String.
      ResultRowList​(org.json.JSONArray ja)
      Construct a new result row object backed by the given JSONArray.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void add​(int arg0, java.lang.Object arg1)  
      boolean add​(java.lang.Object arg0)  
      boolean addAll​(int arg0, java.util.Collection<? extends java.lang.Object> arg1)  
      boolean addAll​(java.util.Collection<? extends java.lang.Object> arg0)  
      void clear()  
      boolean contains​(java.lang.Object value)  
      boolean containsAll​(java.util.Collection<?> arg0)  
      java.lang.Object get​(int arg0)  
      int indexOf​(java.lang.Object arg0)  
      boolean isEmpty()  
      java.util.Iterator<java.lang.Object> iterator()  
      int lastIndexOf​(java.lang.Object arg0)  
      java.util.ListIterator<java.lang.Object> listIterator()  
      java.util.ListIterator<java.lang.Object> listIterator​(int arg0)  
      java.lang.Object remove​(int arg0)  
      boolean remove​(java.lang.Object arg0)  
      boolean removeAll​(java.util.Collection<?> arg0)  
      boolean retainAll​(java.util.Collection<?> arg0)  
      java.lang.Object set​(int arg0, java.lang.Object arg1)  
      int size()  
      java.util.List<java.lang.Object> subList​(int arg0, int arg1)  
      java.lang.Object[] toArray()  
      <T> T[] toArray​(T[] arg0)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Collection

        parallelStream, removeIf, stream, toArray
      • Methods inherited from interface java.lang.Iterable

        forEach
      • Methods inherited from interface java.util.List

        equals, hashCode, replaceAll, sort, spliterator
    • Constructor Detail

      • ResultRowList

        public ResultRowList​(org.json.JSONArray ja)
        Construct a new result row object backed by the given JSONArray.
        Parameters:
        ja - The source array.
      • ResultRowList

        public ResultRowList​(java.lang.String input)
        Construct a new result row object backed by the JSONArray which can be parsed from the given String.
        Parameters:
        input - The source string.
    • Method Detail

      • add

        public boolean add​(java.lang.Object arg0)
        Specified by:
        add in interface java.util.Collection<java.lang.Object>
        Specified by:
        add in interface java.util.List<java.lang.Object>
      • add

        public void add​(int arg0,
                        java.lang.Object arg1)
        Specified by:
        add in interface java.util.List<java.lang.Object>
      • addAll

        public boolean addAll​(java.util.Collection<? extends java.lang.Object> arg0)
        Specified by:
        addAll in interface java.util.Collection<java.lang.Object>
        Specified by:
        addAll in interface java.util.List<java.lang.Object>
      • addAll

        public boolean addAll​(int arg0,
                              java.util.Collection<? extends java.lang.Object> arg1)
        Specified by:
        addAll in interface java.util.List<java.lang.Object>
      • clear

        public void clear()
        Specified by:
        clear in interface java.util.Collection<java.lang.Object>
        Specified by:
        clear in interface java.util.List<java.lang.Object>
      • contains

        public boolean contains​(java.lang.Object value)
        Specified by:
        contains in interface java.util.Collection<java.lang.Object>
        Specified by:
        contains in interface java.util.List<java.lang.Object>
      • containsAll

        public boolean containsAll​(java.util.Collection<?> arg0)
        Specified by:
        containsAll in interface java.util.Collection<java.lang.Object>
        Specified by:
        containsAll in interface java.util.List<java.lang.Object>
      • get

        public java.lang.Object get​(int arg0)
        Specified by:
        get in interface java.util.List<java.lang.Object>
      • indexOf

        public int indexOf​(java.lang.Object arg0)
        Specified by:
        indexOf in interface java.util.List<java.lang.Object>
      • isEmpty

        public boolean isEmpty()
        Specified by:
        isEmpty in interface java.util.Collection<java.lang.Object>
        Specified by:
        isEmpty in interface java.util.List<java.lang.Object>
      • iterator

        public java.util.Iterator<java.lang.Object> iterator()
        Specified by:
        iterator in interface java.util.Collection<java.lang.Object>
        Specified by:
        iterator in interface java.lang.Iterable<java.lang.Object>
        Specified by:
        iterator in interface java.util.List<java.lang.Object>
      • lastIndexOf

        public int lastIndexOf​(java.lang.Object arg0)
        Specified by:
        lastIndexOf in interface java.util.List<java.lang.Object>
      • listIterator

        public java.util.ListIterator<java.lang.Object> listIterator()
        Specified by:
        listIterator in interface java.util.List<java.lang.Object>
      • listIterator

        public java.util.ListIterator<java.lang.Object> listIterator​(int arg0)
        Specified by:
        listIterator in interface java.util.List<java.lang.Object>
      • remove

        public boolean remove​(java.lang.Object arg0)
        Specified by:
        remove in interface java.util.Collection<java.lang.Object>
        Specified by:
        remove in interface java.util.List<java.lang.Object>
      • remove

        public java.lang.Object remove​(int arg0)
        Specified by:
        remove in interface java.util.List<java.lang.Object>
      • removeAll

        public boolean removeAll​(java.util.Collection<?> arg0)
        Specified by:
        removeAll in interface java.util.Collection<java.lang.Object>
        Specified by:
        removeAll in interface java.util.List<java.lang.Object>
      • retainAll

        public boolean retainAll​(java.util.Collection<?> arg0)
        Specified by:
        retainAll in interface java.util.Collection<java.lang.Object>
        Specified by:
        retainAll in interface java.util.List<java.lang.Object>
      • set

        public java.lang.Object set​(int arg0,
                                    java.lang.Object arg1)
        Specified by:
        set in interface java.util.List<java.lang.Object>
      • size

        public int size()
        Specified by:
        size in interface java.util.Collection<java.lang.Object>
        Specified by:
        size in interface java.util.List<java.lang.Object>
      • subList

        public java.util.List<java.lang.Object> subList​(int arg0,
                                                        int arg1)
        Specified by:
        subList in interface java.util.List<java.lang.Object>
      • toArray

        public java.lang.Object[] toArray()
        Specified by:
        toArray in interface java.util.Collection<java.lang.Object>
        Specified by:
        toArray in interface java.util.List<java.lang.Object>
      • toArray

        public <T> T[] toArray​(T[] arg0)
        Specified by:
        toArray in interface java.util.Collection<java.lang.Object>
        Specified by:
        toArray in interface java.util.List<java.lang.Object>