use of org.apache.ignite.binary.BinaryRawWriter in project ignite by apache.
the class IgfsPathSummary method writeBinary.
/**
* {@inheritDoc}
*/
@Override
public void writeBinary(BinaryWriter writer) throws BinaryObjectException {
BinaryRawWriter rawWriter = writer.rawWriter();
rawWriter.writeInt(filesCnt);
rawWriter.writeInt(dirCnt);
rawWriter.writeLong(totalLen);
IgfsUtils.writePath(rawWriter, path);
}
use of org.apache.ignite.binary.BinaryRawWriter in project ignite by apache.
the class IgfsMetaDirectoryCreateProcessor method writeBinary.
/**
* {@inheritDoc}
*/
@Override
public void writeBinary(BinaryWriter writer) throws BinaryObjectException {
BinaryRawWriter out = writer.rawWriter();
out.writeLong(accessTime);
out.writeLong(modificationTime);
IgfsUtils.writeProperties(out, props);
out.writeString(childName);
if (childName != null)
IgfsUtils.writeListingEntry(out, childEntry);
}
use of org.apache.ignite.binary.BinaryRawWriter in project ignite by apache.
the class IgfsBlockLocationImpl method writeBinary.
/**
* {@inheritDoc}
*/
@Override
public void writeBinary(BinaryWriter writer) throws BinaryObjectException {
BinaryRawWriter rawWriter = writer.rawWriter();
assert names != null;
assert hosts != null;
rawWriter.writeLong(start);
rawWriter.writeLong(len);
rawWriter.writeBoolean(nodeIds != null);
if (nodeIds != null) {
rawWriter.writeInt(nodeIds.size());
for (UUID nodeId : nodeIds) U.writeUuid(rawWriter, nodeId);
}
rawWriter.writeInt(names.size());
for (String name : names) rawWriter.writeString(name);
rawWriter.writeInt(hosts.size());
for (String host : hosts) rawWriter.writeString(host);
}
use of org.apache.ignite.binary.BinaryRawWriter in project ignite by apache.
the class IgfsDirectoryInfo method writeBinary.
/**
* {@inheritDoc}
*/
@Override
public void writeBinary(BinaryWriter writer) throws BinaryObjectException {
BinaryRawWriter out = writer.rawWriter();
writeBinary(out);
if (listing != null) {
out.writeBoolean(true);
out.writeInt(listing.size());
for (Map.Entry<String, IgfsListingEntry> entry : listing.entrySet()) {
out.writeString(entry.getKey());
IgfsUtils.writeListingEntry(out, entry.getValue());
}
} else
out.writeBoolean(false);
}
use of org.apache.ignite.binary.BinaryRawWriter in project ignite by apache.
the class IgfsListingEntry method writeBinary.
/**
* {@inheritDoc}
*/
@Override
public void writeBinary(BinaryWriter writer) throws BinaryObjectException {
BinaryRawWriter out = writer.rawWriter();
BinaryUtils.writeIgniteUuid(out, id);
out.writeBoolean(dir);
}
Aggregations