Package omero.sys

Class ParametersI

  • All Implemented Interfaces:
    Ice.Object, java.io.Serializable, java.lang.Cloneable

    public class ParametersI
    extends Parameters
    Helper subclass of Parameters for simplifying method parameter creation. As of 4.0, this takes over for PojoOptions. See ticket:67.
    See Also:
    Serialized Form
    • Constructor Detail

      • ParametersI

        public ParametersI()
        Default constructor creates the Parameters.map instance to prevent later NullPointerExceptions. To save memory, it is possible to pass null to ParametersI(Map).
      • ParametersI

        public ParametersI​(java.util.Map<java.lang.String,​RType> map)
        Uses (and does not copy) the given Map<String, RType> as the named parameter store in this instance. Be careful if either null is passed or if this instance is being used in a multi-threaded environment. No synchronization takes place.
        Parameters:
        map - the named parameter store to use
    • Method Detail

      • page

        public ParametersI page​(int offset,
                                int limit)
        Sets both the Filter.limit and Filter.offset values by wrapping the arguments in RInt and passing the values to page(RInt, RInt)
        Parameters:
        offset - the offset (to start from)
        limit - the limit (maximum to return)
        Returns:
        this instance, for method chaining
      • page

        public ParametersI page​(RInt offset,
                                RInt limit)
        Creates a Filter if necessary and sets both Filter.limit and Filter.offset.
        Parameters:
        offset - the offset (to start from)
        limit - the limit (maximum to return)
        Returns:
        this instance, for method chaining
      • isPagination

        public boolean isPagination()
        Returns true if the filter contains a limit OR a offset, false otherwise.
        Returns:
        See above.
      • getOffset

        public RInt getOffset()
        Returns the value of the offset parameter.
        Returns:
        See above.
      • getLimit

        public RInt getLimit()
        Returns the value of the limit parameter.
        Returns:
        See above.
      • getUnique

        public RBool getUnique()
      • exp

        public ParametersI exp​(RLong i)
        Sets the value of the experimenter parameter.
        Parameters:
        i - The Id of the experimenter.
        Returns:
        Returns the current object.
      • allExps

        public ParametersI allExps()
        Removes the experimenter parameter from the map.
        Returns:
        Returns the current object.
      • isExperimenter

        public boolean isExperimenter()
        Returns true if the filter contains and ownerId parameter, false otherwise.
        Returns:
        See above.
      • getExperimenter

        public RLong getExperimenter()
        Returns the value of the experimenter parameter.
        Returns:
        See above.
      • grp

        public ParametersI grp​(RLong i)
        Sets the value of the group parameter.
        Parameters:
        i - The value to set.
        Returns:
        See above.
      • allGrps

        public ParametersI allGrps()
        Removes the group parameter from the map.
        Returns:
        Returns the current object.
      • isGroup

        public boolean isGroup()
        Returns true if the filter contains an groupId, false otherwise.
        Returns:
        See above.
      • getGroup

        public RLong getGroup()
        Returns the value of the group parameter.
        Returns:
        See above.
      • startTime

        public ParametersI startTime​(RTime startTime)
        Sets the value of the start time parameter.
        Parameters:
        startTime - The time to set.
        Returns:
        Returns the current object.
      • endTime

        public ParametersI endTime​(RTime endTime)
        Sets the value of the end time parameter.
        Parameters:
        endTime - The time to set.
        Returns:
        Returns the current object.
      • allTimes

        public ParametersI allTimes()
        Removes the time parameters from the map.
        Returns:
        Returns the current object.
      • isStartTime

        public boolean isStartTime()
        Returns true if the map contains the start time parameter, false otherwise.
        Returns:
        See above.
      • isEndTime

        public boolean isEndTime()
        Returns true if the map contains the end time parameter, false otherwise.
        Returns:
        See above.
      • getStartTime

        public RTime getStartTime()
        Returns the value of the start time parameter.
        Returns:
        See above.
      • getEndTime

        public RTime getEndTime()
        Returns the value of the end time parameter.
        Returns:
        See above.
      • leaves

        public ParametersI leaves()
        Sets the leaf parameter to true.
        Returns:
        Returns the current object.
      • noLeaves

        public ParametersI noLeaves()
        Sets the leaf parameter to false.
        Returns:
        Returns the current object.
      • getLeaves

        public RBool getLeaves()
      • orphan

        public ParametersI orphan()
        Sets the orphan parameter to true.
        Returns:
        Returns the current object.
      • noOrphan

        public ParametersI noOrphan()
        Sets the orphan parameter to false.
        Returns:
        Returns the current object.
      • getOrphan

        public RBool getOrphan()
      • acquisitionData

        public ParametersI acquisitionData()
        Sets the acquisition data parameter to true.
        Returns:
        Returns the current object.
      • noAcquisitionData

        public ParametersI noAcquisitionData()
        Sets the acquisition data parameter to false.
        Returns:
        Returns the current object.
      • getAcquisitionData

        public RBool getAcquisitionData()
      • cache

        public ParametersI cache()
        Deprecated.
        experimental: may be wholly removed in next major version
        Set queries to be cacheable. Use with caution.
        Returns:
        this instance, for method chaining
      • noCache

        public ParametersI noCache()
        Set queries to not be cacheable. This is the default.
        Returns:
        this instance, for method chaining
      • getCache

        public RBool getCache()
        Returns:
        if queries are cacheable
      • addIds

        public ParametersI addIds​(java.util.Collection<java.lang.Long> longs)
      • addLong

        public ParametersI addLong​(java.lang.String name,
                                   long l)
      • addLongs

        public ParametersI addLongs​(java.lang.String name,
                                    java.util.Collection<java.lang.Long> longs)