protected final void ensureBLayerDataInBuffer(int desiredDataSize) throws DisconnectException { if (dssIsContinued_ && (desiredDataSize > dssLength_)) { int continueDssHeaderCount = (((desiredDataSize - dssLength_) / 32767) + 1); ensureALayerDataInBuffer(desiredDataSize + (continueDssHeaderCount * 2)); compressBLayerData(continueDssHeaderCount); return; } ensureALayerDataInBuffer(desiredDataSize); }
protected final void ensureBLayerDataInBuffer(int desiredDataSize) throws DisconnectException { if (dssIsContinued_ && (desiredDataSize > dssLength_)) { int continueDssHeaderCount = (((desiredDataSize - dssLength_) / 32767) + 1); ensureALayerDataInBuffer(desiredDataSize + (continueDssHeaderCount * 2)); compressBLayerData(continueDssHeaderCount); return; } ensureALayerDataInBuffer(desiredDataSize); }
protected final void readDSSContinuationHeader() throws DisconnectException { ensureALayerDataInBuffer(2); dssLength_ = ((buffer_[pos_++] & 0xFF) << 8) + ((buffer_[pos_++] & 0xFF) << 0); if ((dssLength_ & 0x8000) == 0x8000) { dssLength_ = DssConstants.MAX_DSS_LEN; dssIsContinued_ = true; } else { dssIsContinued_ = false; } // it is a syntax error if the dss continuation header length // is less than or equal to two if (dssLength_ <= 2) { doSyntaxrmSemantics(CodePoint.SYNERRCD_DSS_CONT_LESS_OR_EQUAL_2); } dssLength_ -= 2; // avoid consuming the DSS cont header }
protected final void readDSSContinuationHeader() throws DisconnectException { ensureALayerDataInBuffer(2); dssLength_ = ((buffer_[pos_++] & 0xFF) << 8) + ((buffer_[pos_++] & 0xFF) << 0); if ((dssLength_ & 0x8000) == 0x8000) { dssLength_ = DssConstants.MAX_DSS_LEN; dssIsContinued_ = true; } else { dssIsContinued_ = false; } // it is a syntax error if the dss continuation header length // is less than or equal to two if (dssLength_ <= 2) { doSyntaxrmSemantics(CodePoint.SYNERRCD_DSS_CONT_LESS_OR_EQUAL_2); } dssLength_ -= 2; // avoid consuming the DSS cont header }
ensureALayerDataInBuffer(copySize); adjustLengths(copySize); baos.write(buffer_, pos_, copySize);
ensureALayerDataInBuffer(copySize); adjustLengths(copySize); baos.write(buffer_, pos_, copySize);
ensureALayerDataInBuffer(copySize); adjustLengths(copySize); baos.write(buffer_, pos_, copySize); int bytesRead = ensureALayerDataInBuffer(dssLength_); //we need to get back all the data here, and then decrypt if (bytesRead > 0) //we ensuredALayerDAtaInBuffer here and set the flag to true, so we don't need do this again later
ensureALayerDataInBuffer(copySize); adjustLengths(copySize); baos.write(buffer_, pos_, copySize); int bytesRead = ensureALayerDataInBuffer(dssLength_); //we need to get back all the data here, and then decrypt if (bytesRead > 0) //we ensuredALayerDAtaInBuffer here and set the flag to true, so we don't need do this again later
protected final void readDssHeader() throws DisconnectException { int correlationID = 0; int nextCorrelationID = 0; ensureALayerDataInBuffer(6);
protected final void readDssHeader() throws DisconnectException { int correlationID = 0; int nextCorrelationID = 0; ensureALayerDataInBuffer(6);