Package org.astonbitecode.j4rs.api.dtos
Class InvocationArg
- java.lang.Object
-
- org.astonbitecode.j4rs.api.dtos.InvocationArg
-
public class InvocationArg extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static StringCONTENTS_ARRAYThe array contents should map to a List.
-
Constructor Summary
Constructors Constructor Description InvocationArg(String className, Object object)InvocationArg(String className, String json)InvocationArg(String className, NativeInvocation nativeInvocation)InvocationArg(NativeInvocation nativeInvocation)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetClassName()The type of this argument.StringgetJson()NativeInvocationgetNativeInvocation()booleanisSerialized()If true, the argument is taken straight by the Java code as Object.StringtoString()
-
-
-
Field Detail
-
CONTENTS_ARRAY
public static final String CONTENTS_ARRAY
The array contents should map to a List. This is in order to allow calls of type Arrays.asList(arg1, arg2, arg3, ...)- See Also:
- Constant Field Values
-
-
Constructor Detail
-
InvocationArg
public InvocationArg(String className, NativeInvocation nativeInvocation)
-
InvocationArg
public InvocationArg(NativeInvocation nativeInvocation)
-
InvocationArg
public InvocationArg(String className, Object object) throws ClassNotFoundException
- Throws:
ClassNotFoundException
-
-
Method Detail
-
isSerialized
public boolean isSerialized()
If true, the argument is taken straight by the Java code as Object. If false, the argument is a json document that need to be deserialized to an Object.- Returns:
- The The argFrom
-
getClassName
public String getClassName()
The type of this argument. This is used when json objects come from Rust, in order to be mapped to proper Java Objects.- Returns:
- The classname
-
getNativeInvocation
public NativeInvocation getNativeInvocation()
-
getJson
public String getJson()
-
-