public void decode(AsnInputStream ais) throws ParseException {
        try {
            AsnInputStream localAis = ais.readSequenceStream();
            int tag = localAis.readTag();
            if (tag != Tag.OBJECT_IDENTIFIER || localAis.getTagClass() != Tag.CLASS_UNIVERSAL)
                throw new ParseException(PAbortCauseType.IncorrectTxPortion, null,
                        "Error decoding ApplicationContextName: bad tag or tagClass, found tag=" + tag + ", tagClass="
                                + localAis.getTagClass());
            this.oid = localAis.readObjectIdentifier();

        } catch (IOException e) {
            throw new ParseException(PAbortCauseType.BadlyFormattedTxPortion, null,
                    "IOException while decoding ApplicationContextName: " + e.getMessage(), e);
        } catch (AsnException e) {
            throw new ParseException(PAbortCauseType.BadlyFormattedTxPortion, null,
                    "AsnException while decoding ApplicationContextName: " + e.getMessage(), e);
        }

    }
public void decode ( AsnInputStream ais ) throws ParseException { try { AsnInputStream localAis = ais . readSequenceStream ( ) ; int tag = localAis . readTag ( ) ; if ( tag != Tag . OBJECT_IDENTIFIER || localAis . getTagClass ( ) != Tag . CLASS_UNIVERSAL ) throw new ParseException ( PAbortCauseType . IncorrectTxPortion , null , "Error decoding ApplicationContextName: bad tag or tagClass, found tag=" + tag + ", tagClass=" + localAis . getTagClass ( ) ) ; this . oid = localAis . readObjectIdentifier ( ) ; } catch ( IOException e ) { throw new ParseException ( PAbortCauseType . BadlyFormattedTxPortion , null , "IOException while decoding ApplicationContextName: " + e . getMessage ( ) , e ) ; } catch ( AsnException e ) { throw new ParseException ( PAbortCauseType . BadlyFormattedTxPortion , null , "AsnException while decoding ApplicationContextName: " + e . getMessage ( ) , e ) ; } }
/*
(non-Javadoc)

@see org.restcomm.protocols.ss7.tcap.asn.Encodable#decode(org.mobicents.protocols .asn.AsnInputStream)