buffer.put( BerValue.getBytes( getSyncStateType().getValue() ) );
buffer.put( BerValue.getBytes( getSyncStateType().getValue() ) );
buffer.put( BerValue.getBytes( getSyncStateType().getValue() ) );
/** * Encode the SyncStateValue control * * @param buffer The encoded sink * @return A ByteBuffer that contains the encoded PDU * @throws EncoderException If anything goes wrong. */ @Override public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException { if ( buffer == null ) { throw new EncoderException( I18n.err( I18n.ERR_08000_CANNOT_PUT_A_PDU_IN_NULL_BUFFER ) ); } // Encode the SEQ buffer.put( UniversalTag.SEQUENCE.getValue() ); buffer.put( TLV.getBytes( syncStateSeqLength ) ); // The mode buffer.put( UniversalTag.ENUMERATED.getValue() ); buffer.put( ( byte ) 0x01 ); buffer.put( BerValue.getBytes( getSyncStateType().getValue() ) ); // the entryUUID BerValue.encode( buffer, getEntryUUID() ); // The cookie if ( getCookie() != null ) { BerValue.encode( buffer, getCookie() ); } return buffer; }
/** * Encode the SyncStateValue control * * @param buffer The encoded sink * @return A ByteBuffer that contains the encoded PDU * @throws EncoderException If anything goes wrong. */ @Override public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException { if ( buffer == null ) { throw new EncoderException( I18n.err( I18n.ERR_08000_CANNOT_PUT_A_PDU_IN_NULL_BUFFER ) ); } // Encode the SEQ buffer.put( UniversalTag.SEQUENCE.getValue() ); buffer.put( TLV.getBytes( syncStateSeqLength ) ); // The mode buffer.put( UniversalTag.ENUMERATED.getValue() ); buffer.put( ( byte ) 0x01 ); buffer.put( BerValue.getBytes( getSyncStateType().getValue() ) ); // the entryUUID BerValue.encode( buffer, getEntryUUID() ); // The cookie if ( getCookie() != null ) { BerValue.encode( buffer, getCookie() ); } return buffer; }
/** * Encode the SyncStateValue control * * @param buffer The encoded sink * @return A ByteBuffer that contains the encoded PDU * @throws EncoderException If anything goes wrong. */ @Override public ByteBuffer encode( ByteBuffer buffer ) throws EncoderException { if ( buffer == null ) { throw new EncoderException( I18n.err( I18n.ERR_08000_CANNOT_PUT_A_PDU_IN_NULL_BUFFER ) ); } // Encode the SEQ buffer.put( UniversalTag.SEQUENCE.getValue() ); buffer.put( TLV.getBytes( syncStateSeqLength ) ); // The mode buffer.put( UniversalTag.ENUMERATED.getValue() ); buffer.put( ( byte ) 0x01 ); buffer.put( BerValue.getBytes( getSyncStateType().getValue() ) ); // the entryUUID BerValue.encode( buffer, getEntryUUID() ); // The cookie if ( getCookie() != null ) { BerValue.encode( buffer, getCookie() ); } return buffer; }