com.rabbitmq.tools.jsonrpc
Class ServiceDescription

java.lang.Object
  extended by com.rabbitmq.tools.jsonrpc.ServiceDescription

public class ServiceDescription
extends java.lang.Object

Description of a JSON-RPC service.


Field Summary
 java.lang.String help
          Human-readable instructions for how to get information on the service's operation
 java.lang.String id
          ID for the service
static java.lang.String JSON_RPC_VERSION
           
 java.lang.String name
          The service name
 java.lang.String summary
          Human-readable summary for the service
 java.lang.String version
          Version of the service
 
Constructor Summary
ServiceDescription()
           
ServiceDescription(java.lang.Class<?> klass)
           
ServiceDescription(java.util.Map<java.lang.String,java.lang.Object> rawServiceDescription)
           
 
Method Summary
 ProcedureDescription getProcedure(java.lang.String newname, int arity)
          Looks up a single ProcedureDescription by name and arity.
 java.util.Collection<ProcedureDescription> getProcs()
          Gets a collection of all ProcedureDescription for this service
 void setProcs(java.util.Collection<java.util.Map<java.lang.String,java.lang.Object>> p)
          Private API - used via reflection during parsing/loading
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

JSON_RPC_VERSION

public static final java.lang.String JSON_RPC_VERSION
See Also:
Constant Field Values

name

public java.lang.String name
The service name


id

public java.lang.String id
ID for the service


version

public java.lang.String version
Version of the service


summary

public java.lang.String summary
Human-readable summary for the service


help

public java.lang.String help
Human-readable instructions for how to get information on the service's operation

Constructor Detail

ServiceDescription

public ServiceDescription(java.util.Map<java.lang.String,java.lang.Object> rawServiceDescription)

ServiceDescription

public ServiceDescription(java.lang.Class<?> klass)

ServiceDescription

public ServiceDescription()
Method Detail

getProcs

public java.util.Collection<ProcedureDescription> getProcs()
Gets a collection of all ProcedureDescription for this service


setProcs

public void setProcs(java.util.Collection<java.util.Map<java.lang.String,java.lang.Object>> p)
Private API - used via reflection during parsing/loading


getProcedure

public ProcedureDescription getProcedure(java.lang.String newname,
                                         int arity)
Looks up a single ProcedureDescription by name and arity.

Returns:
non-null ProcedureDescription if a match is found
Throws:
java.lang.IllegalArgumentException - if no match is found