Class TransmissionMeta
- java.lang.Object
-
- org.apache.ignite.internal.managers.communication.TransmissionMeta
-
- All Implemented Interfaces:
Externalizable,Serializable
public class TransmissionMeta extends Object implements Externalizable
Class represents a file meta information to send to the remote node. Used to initiate a new file transfer process or to continue the previous unfinished from the last transmitted point.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TransmissionMeta()Default constructor, usually used to create meta to read channel data into.TransmissionMeta(Exception err)TransmissionMeta(String name, long offset, long cnt, Map<String,Serializable> params, TransmissionPolicy plc, Exception err)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longcount()booleanequals(Object o)Exceptionerror()TransmissionMetaerror(Exception err)inthashCode()Stringname()longoffset()Map<String,Serializable>params()TransmissionPolicypolicy()voidreadExternal(ObjectInput in)StringtoString()voidwriteExternal(ObjectOutput out)
-
-
-
Constructor Detail
-
TransmissionMeta
public TransmissionMeta()
Default constructor, usually used to create meta to read channel data into.
-
TransmissionMeta
public TransmissionMeta(Exception err)
- Parameters:
err- Last seen error if it has been occurred, ornullthe otherwise.
-
TransmissionMeta
public TransmissionMeta(String name, long offset, long cnt, Map<String,Serializable> params, TransmissionPolicy plc, Exception err)
- Parameters:
name- File name to assoticate particular meta with.offset- The start position of file.cnt- Number of bytes expected to transfer.params- Additional meta params.plc- Policy of how file will be handled.err- Last seen error if it has been occurred, ornullthe otherwise.
-
-
Method Detail
-
name
public String name()
- Returns:
- File name.
-
offset
public long offset()
- Returns:
- Position to start channel transfer at.
-
count
public long count()
- Returns:
- Number of bytes expected to transfer.
-
params
public Map<String,Serializable> params()
- Returns:
- Additional params.
-
policy
public TransmissionPolicy policy()
- Returns:
- Transmission policy.
-
error
public TransmissionMeta error(Exception err)
- Parameters:
err- An exception instance if it has been previously occurred.- Returns:
Thisfor chaining.
-
error
public Exception error()
- Returns:
- An exception instance if it has been previously occurred.
-
writeExternal
public void writeExternal(ObjectOutput out) throws IOException
- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-
readExternal
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
-