1 package com.android.hotspot2.utils;
2 
3 import java.io.InputStream;
4 import java.nio.ByteBuffer;
5 import java.util.Map;
6 
7 public interface HTTPMessage {
8     public static final String HTTPVersion = "HTTP/1.1";
9     public static final String AgentHeader = "User-Agent";
10     public static final String AgentName = "Android HS Client";
11     public static final String HostHeader = "Host";
12     public static final String AcceptHeader = "Accept";
13     public static final String LengthHeader = "Content-Length";
14     public static final String ContentTypeHeader = "Content-Type";
15     public static final String ContentLengthHeader = "Content-Length";
16     public static final String ContentEncodingHeader = "Content-Transfer-Encoding";
17     public static final String AuthHeader = "WWW-Authenticate";
18     public static final String AuthorizationHeader = "Authorization";
19 
20     public static final String ContentTypeSOAP = "application/soap+xml";
21 
22     public static final int RX_BUFFER = 32768;
23     public static final String CRLF = "\r\n";
24     public static final int BODY_SEPARATOR = 0x0d0a0d0a;
25     public static final int BODY_SEPARATOR_LENGTH = 4;
26 
27     public enum Method {GET, PUT, POST}
28 
getHeaders()29     public Map<String, String> getHeaders();
30 
getPayloadStream()31     public InputStream getPayloadStream();
32 
getPayload()33     public ByteBuffer getPayload();
34 
getBinaryPayload()35     public ByteBuffer getBinaryPayload();
36 }
37