com.google.api.client.auth.oauth2.draft10
Enum AccessProtectedResource.Method

java.lang.Object
  extended by java.lang.Enum<AccessProtectedResource.Method>
      extended by com.google.api.client.auth.oauth2.draft10.AccessProtectedResource.Method
All Implemented Interfaces:
Serializable, Comparable<AccessProtectedResource.Method>
Enclosing class:
AccessProtectedResource

public static enum AccessProtectedResource.Method
extends Enum<AccessProtectedResource.Method>

Method of accessing protected resources.

The only method required to be implemented by the specification is AUTHORIZATION_HEADER.


Enum Constant Summary
AUTHORIZATION_HEADER
          Uses the "Authorization" header, as specified in Section 5.1.1.
FORM_ENCODED_BODY
          Uses a form-encoded body parameter, as specified in Section 5.1.3.
QUERY_PARAMETER
          Uses the query parameter, as specified in Section 5.1.2.
 
Method Summary
static AccessProtectedResource.Method valueOf(String name)
          Returns the enum constant of this type with the specified name.
static AccessProtectedResource.Method[] 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

AUTHORIZATION_HEADER

public static final AccessProtectedResource.Method AUTHORIZATION_HEADER
Uses the "Authorization" header, as specified in Section 5.1.1.


QUERY_PARAMETER

public static final AccessProtectedResource.Method QUERY_PARAMETER
Uses the query parameter, as specified in Section 5.1.2.


FORM_ENCODED_BODY

public static final AccessProtectedResource.Method FORM_ENCODED_BODY
Uses a form-encoded body parameter, as specified in Section 5.1.3.

Method Detail

values

public static AccessProtectedResource.Method[] 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 (AccessProtectedResource.Method c : AccessProtectedResource.Method.values())
    System.out.println(c);

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

valueOf

public static AccessProtectedResource.Method 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


Copyright © 2010-2011 Google. All Rights Reserved.