Package org.apache.ignite.marshaller
Class AbstractNodeNameAwareMarshaller
- java.lang.Object
- 
- org.apache.ignite.marshaller.AbstractMarshaller
- 
- org.apache.ignite.marshaller.AbstractNodeNameAwareMarshaller
 
 
- 
- All Implemented Interfaces:
- Marshaller
 - Direct Known Subclasses:
- JdkMarshaller
 
 public abstract class AbstractNodeNameAwareMarshaller extends AbstractMarshaller Marshaller allowing forIgnition.localIgnite()calls.
- 
- 
Field Summary- 
Fields inherited from class org.apache.ignite.marshaller.AbstractMarshallerctx, DFLT_BUFFER_SIZE
 
- 
 - 
Constructor SummaryConstructors Constructor Description AbstractNodeNameAwareMarshaller()
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description byte[]marshal(@Nullable Object obj)Marshals object to byte array.voidmarshal(@Nullable Object obj, OutputStream out)Marshals object to the output stream.protected abstract byte[]marshal0(@Nullable Object obj)Marshals object to byte array.protected abstract voidmarshal0(@Nullable Object obj, OutputStream out)Marshals object to the output stream.voidnodeName(@Nullable String nodeName)Set node name.<T> Tunmarshal(byte[] arr, @Nullable ClassLoader clsLdr)Unmarshals object from byte array using given class loader.<T> Tunmarshal(InputStream in, @Nullable ClassLoader clsLdr)Unmarshals object from the input stream using given class loader.protected abstract <T> Tunmarshal0(byte[] arr, @Nullable ClassLoader clsLdr)Unmarshals object from byte array using given class loader.protected abstract <T> Tunmarshal0(InputStream in, @Nullable ClassLoader clsLdr)Unmarshals object from the input stream using given class loader.- 
Methods inherited from class org.apache.ignite.marshaller.AbstractMarshallergetContext, onUndeploy, setContext
 
- 
 
- 
- 
- 
Method Detail- 
nodeNamepublic void nodeName(@Nullable @Nullable String nodeName)Set node name.- Parameters:
- nodeName- Node name.
 
 - 
marshalpublic byte[] marshal(@Nullable @Nullable Object obj) throws IgniteCheckedExceptionMarshals object to byte array.- Parameters:
- obj- Object to marshal.- nullobject will be marshaled to binary- nullrepresentation.
- Returns:
- Byte array.
- Throws:
- IgniteCheckedException- If marshalling failed.
 
 - 
marshalpublic void marshal(@Nullable @Nullable Object obj, OutputStream out) throws IgniteCheckedExceptionMarshals object to the output stream. This method should not close given output stream.- Parameters:
- obj- Object to marshal.- nullobject will be marshaled to binary- nullrepresentation.
- out- Output stream to marshal into.
- Throws:
- IgniteCheckedException- If marshalling failed.
 
 - 
unmarshalpublic <T> T unmarshal(byte[] arr, @Nullable @Nullable ClassLoader clsLdr) throws IgniteCheckedExceptionUnmarshals object from byte array using given class loader.- Type Parameters:
- T- Type of unmarshalled object.
- Parameters:
- arr- Byte array.
- clsLdr- If not- nullthen given class loader will be used for unmarshal object.
- Returns:
- Unmarshalled object.
- Throws:
- IgniteCheckedException- If unmarshalling failed.
 
 - 
unmarshalpublic <T> T unmarshal(InputStream in, @Nullable @Nullable ClassLoader clsLdr) throws IgniteCheckedException Unmarshals object from the input stream using given class loader. This method should not close given input stream.- Type Parameters:
- T- Type of unmarshalled object.
- Parameters:
- in- Input stream.
- clsLdr- If not- nullthen given class loader will be used for unmarshal object.
- Returns:
- Unmarshalled object.
- Throws:
- IgniteCheckedException- If unmarshalling failed.
 
 - 
marshal0protected abstract void marshal0(@Nullable @Nullable Object obj, OutputStream out) throws IgniteCheckedExceptionMarshals object to the output stream. This method should not close given output stream.- Parameters:
- obj- Object to marshal.- nullobject will be marshaled to binary- nullrepresentation.
- out- Output stream to marshal into.
- Throws:
- IgniteCheckedException- If marshalling failed.
 
 - 
marshal0protected abstract byte[] marshal0(@Nullable @Nullable Object obj) throws IgniteCheckedExceptionMarshals object to byte array.- Parameters:
- obj- Object to marshal.- nullobject will be marshaled to binary- nullrepresentation.
- Returns:
- Byte array.
- Throws:
- IgniteCheckedException- If marshalling failed.
 
 - 
unmarshal0protected abstract <T> T unmarshal0(InputStream in, @Nullable @Nullable ClassLoader clsLdr) throws IgniteCheckedException Unmarshals object from the input stream using given class loader. This method should not close given input stream.- Type Parameters:
- T- Type of unmarshalled object.
- Parameters:
- in- Input stream.
- clsLdr- If not- nullthen given class loader will be used for unmarshal object.
- Returns:
- Unmarshalled object.
- Throws:
- IgniteCheckedException- If unmarshalling failed.
 
 - 
unmarshal0protected abstract <T> T unmarshal0(byte[] arr, @Nullable @Nullable ClassLoader clsLdr) throws IgniteCheckedExceptionUnmarshals object from byte array using given class loader.- Type Parameters:
- T- Type of unmarshalled object.
- Parameters:
- arr- Byte array.
- clsLdr- If not- nullthen given class loader will be used for unmarshal object.
- Returns:
- Unmarshalled object.
- Throws:
- IgniteCheckedException- If unmarshalling failed.
 
 
- 
 
-