Examples of BerValue


Examples of org.apache.directory.shared.asn1.ber.tlv.BerValue

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( I18n.err( I18n.ERR_04067 ) );
        }

        // The etype is an integer
        BerValue value = tlv.getValue();

        EncryptionType etype = null;
        ETypeInfo2Entry etypeInfo2Entry = eTypeInfo2EntryContainer.getETypeInfo2Entry();

        try
        {
            int eType = IntegerDecoder.parse( value );
            etype = EncryptionType.getTypeByValue( eType );

            etypeInfo2Entry.setEType( etype );

            if ( IS_DEBUG )
            {
                LOG.debug( "etype : " + etype );
            }

            // The next tag is optional, we can end here
            eTypeInfo2EntryContainer.setGrammarEndAllowed( true );
        }
        catch ( IntegerDecoderException ide )
        {
            LOG.error( I18n.err( I18n.ERR_04070, Strings.dumpBytes( value.getData() ), ide
                .getLocalizedMessage() ) );

            // This will generate a PROTOCOL_ERROR
            throw new DecoderException( ide.getMessage() );
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.