ch.systemsx.cisd.openbis.plugin.query.shared.api.v1.dto
Class QueryDescription

java.lang.Object
  extended by ch.systemsx.cisd.openbis.plugin.query.shared.api.v1.dto.QueryDescription
All Implemented Interfaces:
java.io.Serializable

@JsonObject(value="QueryDescription")
public class QueryDescription
extends java.lang.Object
implements java.io.Serializable

Description of a query. Contains everything needed on client side to show to the user what queries are available, to specify parameter bindings, and to identify a query uniquely.

See Also:
Serialized Form

Constructor Summary
QueryDescription()
           
 
Method Summary
 boolean equals(java.lang.Object obj)
          Returns true if and only if the specified object is of type QueryDescription and has the same ID as this.
 java.lang.String getDescription()
          Returns an optional description or empty string if undefined.
 long getId()
          Returns the ID of the query.
 java.lang.String getName()
          Returns the name of the query.
 java.util.List<java.lang.String> getParameters()
          Returns the list of parameters to which values should be bound when executing the query.
 int hashCode()
          Returns the ID.
 void setDescription(java.lang.String description)
           
 void setId(long id)
           
 void setName(java.lang.String name)
           
 void setParameters(java.util.List<java.lang.String> parameters)
           
 java.lang.String toString()
          Returns the name.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

QueryDescription

public QueryDescription()
Method Detail

getId

public long getId()
Returns the ID of the query. Will be used to identify the query to be executed.


setId

public void setId(long id)

getName

public java.lang.String getName()
Returns the name of the query.


setName

public void setName(java.lang.String name)

getDescription

public java.lang.String getDescription()
Returns an optional description or empty string if undefined.


setDescription

public void setDescription(java.lang.String description)

getParameters

public java.util.List<java.lang.String> getParameters()
Returns the list of parameters to which values should be bound when executing the query.

Returns:
an empty list if there are no parameters.

setParameters

public void setParameters(java.util.List<java.lang.String> parameters)

equals

public boolean equals(java.lang.Object obj)
Returns true if and only if the specified object is of type QueryDescription and has the same ID as this.

Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Returns the ID.

Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Returns the name.

Overrides:
toString in class java.lang.Object