Class KiiThingQuery


  • public class KiiThingQuery
    extends java.lang.Object
    Represents query object to obtain things.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void setLimit​(int limit)
      Set the maximum number of results returned on response.
      void setThingType​(java.lang.String thingType)
      Sets the thing type to filter the results.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • KiiThingQuery

        public KiiThingQuery​(@Nullable
                             KiiUser owner,
                             @Nullable
                             java.util.List<KiiGroup> groups)
        Creates a query to search things owned by the specified user and groups. Both the owner and groupOwners parameter are optional, but at least one of them must be supplied.
        Parameters:
        owner - User object must be current user.
        groups - List of groups must be belonged by current user.
      • KiiThingQuery

        public KiiThingQuery​(@NonNull
                             KiiThingQuery query)
        Copy constructor.
        Parameters:
        query -
    • Method Detail

      • setThingType

        public void setThingType​(java.lang.String thingType)
        Sets the thing type to filter the results.
        Parameters:
        thingType -
      • setLimit

        public void setLimit​(int limit)
        Set the maximum number of results returned on response. This limit behaves in a best effort way, actual number of
        returned result may be different with that of requested number.
        Server will try to recover the number of objects requested and it will
        succeed if the limit is not higher than the maximum page size supported by the server.
        If the limit is higher, the number of objects returned will be the maximum page size.
        Parameters:
        limit - Maximum return items. If specified limit is <= 0, 0 will be applied. If the specified limit is greater than the limit of the server or limit is set to 0, limit defined in server will be applied.
      • toString

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