Search in sources :

Example 1 with PAccessNetworkInfo

use of gov.nist.javax.sip.header.ims.PAccessNetworkInfo in project XobotOS by xamarin.

the class PAccessNetworkInfoParser method parse.

public SIPHeader parse() throws ParseException {
    if (debug)
        dbg_enter("AccessNetworkInfoParser.parse");
    try {
        headerName(TokenTypes.P_ACCESS_NETWORK_INFO);
        PAccessNetworkInfo accessNetworkInfo = new PAccessNetworkInfo();
        accessNetworkInfo.setHeaderName(SIPHeaderNamesIms.P_ACCESS_NETWORK_INFO);
        this.lexer.SPorHT();
        lexer.match(TokenTypes.ID);
        Token token = lexer.getNextToken();
        accessNetworkInfo.setAccessType(token.getTokenValue());
        this.lexer.SPorHT();
        while (lexer.lookAhead(0) == ';') {
            this.lexer.match(';');
            this.lexer.SPorHT();
            NameValue nv = super.nameValue('=');
            accessNetworkInfo.setParameter(nv);
            this.lexer.SPorHT();
        }
        this.lexer.SPorHT();
        this.lexer.match('\n');
        return accessNetworkInfo;
    } finally {
        if (debug)
            dbg_leave("AccessNetworkInfoParser.parse");
    }
}
Also used : NameValue(gov.nist.core.NameValue) PAccessNetworkInfo(gov.nist.javax.sip.header.ims.PAccessNetworkInfo) Token(gov.nist.core.Token)

Aggregations

NameValue (gov.nist.core.NameValue)1 Token (gov.nist.core.Token)1 PAccessNetworkInfo (gov.nist.javax.sip.header.ims.PAccessNetworkInfo)1