Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Product of NIST/ITL Advanced Networking Technologies Division (ANTD). * /
 
 /*
 * This code has been contributed by the author to the public domain.
 */
 package gov.nist.javax.sip.header.extensions;
 
import javax.sip.*;
MinSE SIP Header. (Created by modifying Expires.java)

Author(s):
P. Musgrave <pmusgrave@newheights.com>
Version:
JAIN-SIP-1.1 $Revision: 1.4 $ $Date: 2009/10/18 13:46:36 $
public class MinSE
    extends ParametersHeader implements ExtensionHeaderMinSEHeader {
    // TODO: When the MinSEHeader is added to javax - move this there...pmusgrave
    public static final String NAME = "Min-SE";

    
Comment for serialVersionUID
    private static final long serialVersionUID = 3134344915465784267L;

    
expires field
    public int expires;

    
default constructor
    public MinSE() {
        super();
    }

    
Return canonical form.

Returns:
String
    public String encodeBody() {
        String retval = Integer.toString(); // seems overkill - but Expires did this.
        if (!.isEmpty()) {
            retval +=  + .encode();
        }
        return retval;
    }
    public void setValue(String valuethrows ParseException {
        // not implemented.
        throw new ParseException(value,0);
    }

    
Gets the expires value of the ExpiresHeader. This expires value is relative time.

Returns:
the expires value of the ExpiresHeader.
Since:
JAIN SIP v1.1
    public int getExpires() {
        return ;
    }

    
Sets the relative expires value of the ExpiresHeader. The expires value MUST be greater than zero and MUST be less than 2**31.

Parameters:
expires - the new expires value of this ExpiresHeader
Throws:
javax.sip.InvalidArgumentException if supplied value is less than zero.
Since:
JAIN SIP v1.2
    public void setExpires(int expiresthrows InvalidArgumentException {
        if (expires < 0)
            throw new InvalidArgumentException("bad argument " + expires);
        this. = expires;
    }
New to GrepCode? Check out our FAQ X