Package io.polywrap.plugin
Class PluginWrapper
-
- All Implemented Interfaces:
public final class PluginWrapper<TConfig extends Object> implements Wrapper
Represents a plugin wrapper, allowing the plugin module to be invoked as a Wrapper.
-
-
Field Summary
Fields Modifier and Type Field Description private final PluginModule<TConfig>module
-
Constructor Summary
Constructors Constructor Description PluginWrapper(PluginModule<TConfig> module)
-
Method Summary
Modifier and Type Method Description final PluginModule<TConfig>getModule()The plugin module instance associated with the wrapper. List<UByte>)>invoke(String method, List<UByte> args, List<UByte> env, <Error class: unknown class> invoker)Invokes a method in the Wrapper with the specified options and invoker. Result<ByteArray>invoke(String method, ByteArray args, ByteArray env, Invoker invoker)Invokes a method in the Wrapper with the specified options and invoker. -
-
Constructor Detail
-
PluginWrapper
PluginWrapper(PluginModule<TConfig> module)
-
-
Method Detail
-
getModule
final PluginModule<TConfig> getModule()
The plugin module instance associated with the wrapper.
-
invoke
List<UByte> )>invoke(String method, List<UByte> args, List<UByte> env, <Error class: unknown class> invoker)
Invokes a method in the Wrapper with the specified options and invoker.
- Parameters:
method- The method to be called on the wrapper.args- Arguments for the method, encoded in the MessagePack byte formatenv- Env variables for the wrapper invocation, encoded in the MessagePack byte formatinvoker- The invoker will be used for any sub-invocations that occur.
-
invoke
Result<ByteArray> invoke(String method, ByteArray args, ByteArray env, Invoker invoker)
Invokes a method in the Wrapper with the specified options and invoker.
- Parameters:
method- The method to be called on the wrapper.args- Arguments for the method, encoded in the MessagePack byte formatenv- Env variables for the wrapper invocation, encoded in the MessagePack byte formatinvoker- The Invoker will be used for any sub-invocations that occur.
-
-
-
-