Code example for StatusLine

Methods: getProtocolVersion, getStatusCode

0
        if ((reason != null) && ((reason.indexOf('\n') >= 0) ||
                                 (reason.indexOf('\r') >= 0))
            ) { 
            throw new IllegalArgumentException("Line break in reason phrase.");
        } 
        this.statusline = new BasicStatusLine(this.statusline.getProtocolVersion(),
                                              this.statusline.getStatusCode(),
                                              reason);
    } 
 
    // non-javadoc, see interface HttpResponse 
    public void setEntity(final HttpEntity entity) {
        this.entity = entity;
    } 
 
    // non-javadoc, see interface HttpResponse 
    public void setLocale(Locale loc) {
        if (loc == null) {
            throw new IllegalArgumentException("Locale may not be null.");
        } 
        this.locale = loc;