本文整理汇总了Java中com.hazelcast.nio.ObjectDataOutput.writeByte方法的典型用法代码示例。如果您正苦于以下问题:Java ObjectDataOutput.writeByte方法的具体用法?Java ObjectDataOutput.writeByte怎么用?Java ObjectDataOutput.writeByte使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.hazelcast.nio.ObjectDataOutput
的用法示例。
在下文中一共展示了ObjectDataOutput.writeByte方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: write
import com.hazelcast.nio.ObjectDataOutput; //导入方法依赖的package包/类
@Override
public void write(ObjectDataOutput out, Expression exp) throws IOException {
out.writeInt(exp.getCollectionId());
out.writeInt(exp.getCompType().ordinal());
if (exp instanceof AlwaysExpression) {
out.writeByte(0);
} else if (exp instanceof BinaryExpression) {
out.writeByte(1);
out.writeObject(exp.getPath());
} else {
out.writeByte(2);
out.writeObject(exp.getPath());
out.writeUTF(((PathExpression) exp).getParamName());
out.writeObject(((PathExpression) exp).getCachedPath());
}
}
示例2: writeData
import com.hazelcast.nio.ObjectDataOutput; //导入方法依赖的package包/类
@Override
public void writeData(ObjectDataOutput out) throws IOException {
super.writeData(out);
out.writeByte(status != null ? status.value() : Byte.MIN_VALUE);
out.writeInt(qos != null ? qos.value() : Byte.MIN_VALUE);
}
示例3: writeData
import com.hazelcast.nio.ObjectDataOutput; //导入方法依赖的package包/类
@Override
public void writeData(ObjectDataOutput out) throws IOException {
super.writeData(out);
out.writeInt(recordIndex);
out.writeInt(recordOffset);
out.writeByte(getSplitType());
}
示例4: write
import com.hazelcast.nio.ObjectDataOutput; //导入方法依赖的package包/类
@Override
public void write(ObjectDataOutput out, LogValue object) throws IOException {
if (object instanceof ByteValue) {
out.writeByte(BYTE_VALUE);
ByteValue bytes = (ByteValue) object;
out.writeObject(bytes.getBytes());
} else if (object instanceof NoOp) {
out.writeByte(NO_OP);
} else {
log.error("Unexpected type encountered: {}", object);
}
}
示例5: writeData
import com.hazelcast.nio.ObjectDataOutput; //导入方法依赖的package包/类
@Override
public void writeData(ObjectDataOutput out) throws IOException {
super.writeData(out);
out.writeByte(status != null ? status.value() : Byte.MIN_VALUE);
}