com.heroku.api.http
Enum Http.Accept

java.lang.Object
  extended by java.lang.Enum<Http.Accept>
      extended by com.heroku.api.http.Http.Accept
All Implemented Interfaces:
Http.Header, Serializable, Comparable<Http.Accept>
Enclosing class:
Http

public static enum Http.Accept
extends Enum<Http.Accept>
implements Http.Header

HTTP Accept header model.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.heroku.api.http.Http.Header
Http.Header.Util
 
Enum Constant Summary
JSON
           
TEXT
           
 
Method Summary
 String getHeaderName()
           
 String getHeaderValue()
           
static Http.Accept valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Http.Accept[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

JSON

public static final Http.Accept JSON

TEXT

public static final Http.Accept TEXT
Method Detail

values

public static Http.Accept[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (Http.Accept c : Http.Accept.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static Http.Accept valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getHeaderName

public String getHeaderName()
Specified by:
getHeaderName in interface Http.Header

getHeaderValue

public String getHeaderValue()
Specified by:
getHeaderValue in interface Http.Header


Copyright © 2012. All Rights Reserved.