Package i5.las2peer.communication
Class ListMethodsContent
java.lang.Object
i5.las2peer.communication.ListMethodsContent
- All Implemented Interfaces:
java.io.Serializable
public class ListMethodsContent
extends java.lang.Object
implements java.io.Serializable
- See Also:
- Serialized Form
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
ListMethodsContent.MethodComparator
-
Constructor Summary
Constructors Constructor Description ListMethodsContent()
create a new ListMethodContent as a requestListMethodsContent(boolean request)
create a new ListMethodsContent either as a request or as a response, a response is open for adding methods after creation -
Method Summary
Modifier and Type Method Description void
addMethod(java.lang.reflect.Method m)
add a method to this responsevoid
finalize()
close this response for adding methodsjava.lang.String[]
getSortedMethodNames()
get a sorted array with all names of methods stored in this answerjava.lang.String[][]
getSortedMethodParameters(java.lang.String methodName)
get a sorted array of all parameter signatures for the given method nameboolean
isRequest()
is this a request or response message?java.lang.String
toString()
java.lang.String
toXmlString()
get an XML representation of this method list (this class is not xml able since the way back is not implemented (yet?)
-
Constructor Details
-
ListMethodsContent
public ListMethodsContent()create a new ListMethodContent as a request -
ListMethodsContent
public ListMethodsContent(boolean request)create a new ListMethodsContent either as a request or as a response, a response is open for adding methods after creation- Parameters:
request
- If true, this is treated as request or as a response otherwise.
-
-
Method Details
-
addMethod
public void addMethod(java.lang.reflect.Method m)add a method to this response- Parameters:
m
- A method to add
-
finalize
public void finalize()close this response for adding methods- Overrides:
finalize
in classjava.lang.Object
-
getSortedMethodNames
public java.lang.String[] getSortedMethodNames()get a sorted array with all names of methods stored in this answer- Returns:
- array with method names
-
getSortedMethodParameters
public java.lang.String[][] getSortedMethodParameters(java.lang.String methodName)get a sorted array of all parameter signatures for the given method name- Parameters:
methodName
- A method name- Returns:
- sorted array with all parameter signatures
-
isRequest
public boolean isRequest()is this a request or response message?- Returns:
- true, if this is a request message
-
toXmlString
public java.lang.String toXmlString()get an XML representation of this method list (this class is not xml able since the way back is not implemented (yet?)- Returns:
- xml representation
-
toString
public java.lang.String toString()- Overrides:
toString
in classjava.lang.Object
-