public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getVarNameBytes().isEmpty()) { com.google.protobuf.GeneratedMessage.writeString(output, 1, varName_); } if (dataType_ != ucar.nc2.stream.NcStreamProto.DataType.CHAR.getNumber()) { output.writeEnum(2, dataType_); } if (section_ != null) { output.writeMessage(3, getSection()); } if (bigendPresentCase_ == 4) { output.writeBool( 4, (boolean)((java.lang.Boolean) bigendPresent_)); } if (version_ != 0) { output.writeUInt32(5, version_); } if (compress_ != ucar.nc2.stream.NcStreamProto.Compress.NONE.getNumber()) { output.writeEnum(6, compress_); } if (vdata_ != false) { output.writeBool(7, vdata_); } if (uncompressedSize_ != 0) { output.writeUInt32(8, uncompressedSize_); } }
.computeMessageSize(3, getSection());
dataStorage.size = dsize; dataStorage.filePos = raf.getFilePointer(); dataStorage.section = NcStream.decodeSection(dproto.getSection()); dataStorage.nelems = (int) dataStorage.section.computeSize(); dataStorage.isDeflate = dproto.getCompress() == NcStreamProto.Compress.DEFLATE; dataStorage.nelems = nelems; dataStorage.size = totalSize; dataStorage.section = NcStream.decodeSection(dproto.getSection()); if (ncm != null) ncm.add(new NcsMess(dataStorage.filePos, totalSize, dataStorage)); storage.add(dataStorage);
dataStorage.size = dsize; dataStorage.filePos = raf.getFilePointer(); dataStorage.section = NcStream.decodeSection(dproto.getSection()); dataStorage.nelems = (int) dataStorage.section.computeSize(); dataStorage.isDeflate = dproto.getCompress() == NcStreamProto.Compress.DEFLATE; dataStorage.nelems = nelems; dataStorage.size = totalSize; dataStorage.section = NcStream.decodeSection(dproto.getSection()); if (ncm != null) ncm.add(new NcsMess(dataStorage.filePos, totalSize, dataStorage)); storage.add(dataStorage);
Section section = (dataType == DataType.SEQUENCE) ? new Section() : NcStream.decodeSection(dproto.getSection());
Section section = (dataType == DataType.SEQUENCE) ? new Section() : NcStream.decodeSection(dproto.getSection());
Section section = (dataType == DataType.SEQUENCE) ? new Section() : NcStream.decodeSection(dproto.getSection());
mergeSection(other.getSection());
mergeSection(other.getSection());
mergeSection(other.getSection());
public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized != -1) return isInitialized == 1; if (!hasVarName()) { memoizedIsInitialized = 0; return false; } if (!hasDataType()) { memoizedIsInitialized = 0; return false; } if (hasSection()) { if (!getSection().isInitialized()) { memoizedIsInitialized = 0; return false; } } memoizedIsInitialized = 1; return true; }
public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized != -1) return isInitialized == 1; if (!hasVarName()) { memoizedIsInitialized = 0; return false; } if (!hasDataType()) { memoizedIsInitialized = 0; return false; } if (hasSection()) { if (!getSection().isInitialized()) { memoizedIsInitialized = 0; return false; } } memoizedIsInitialized = 1; return true; }
public NcsMess(long filePos, int len, Object what) { this.filePos = filePos; this.len = len; this.what = what; if (what instanceof NcStreamProto.Data) { NcStreamProto.Data dataMess = (NcStreamProto.Data) what; this.dataType = NcStream.convertDataType(dataMess.getDataType()); this.varName = dataMess.getVarName(); Section s = NcStream.decodeSection(dataMess.getSection()); if (s != null) this.nelems = (int) s.computeSize(); } else if (what instanceof DataStorage) this.nelems = ((DataStorage) what).nelems; }
DataStorage(int size, long filePos, NcStreamProto.Data dproto) { this.size = size; this.filePos = filePos; section = NcStream.decodeSection(dproto.getSection()); nelems = (int) section.computeSize(); bo = NcStream.decodeDataByteOrder(dproto); isVlen = dproto.getVdata(); isDeflate = dproto.getCompress() == NcStreamProto.Compress.DEFLATE; if (isDeflate) uncompressedLen = dproto.getUncompressedSize(); }
/** * <code>optional .Section section = 3;</code> * * <pre> * not required for SEQUENCE * </pre> */ public ucar.nc2.stream.NcStreamProto.SectionOrBuilder getSectionOrBuilder() { return getSection(); }