com.belerweb.social.weibo.bean
Enum Scope

java.lang.Object
  extended by java.lang.Enum<Scope>
      extended by com.belerweb.social.weibo.bean.Scope
All Implemented Interfaces:
Serializable, Comparable<Scope>

public enum Scope
extends Enum<Scope>

scope是OAuth2.0授权机制中authorize接口的一个参数 通过scope,平台将开放更多的微博核心功能给开发者,同时也加强用户隐私保护,提升了用户体验,用户在新OAuth2.0授权页中有权利选择赋予应用的功能。


Enum Constant Summary
ALL
          请求下列所有scope权限
DIRECT_MESSAGES_READ
          私信读取接口
DIRECT_MESSAGES_WRITE
          私信发送接口
EMAIL
          用户的联系邮箱
FOLLOW_APP_OFFICIAL_MICROBLOG
          关注应用官方微博,该参数不对应具体接口,只需在应用控制台填写官方帐号即可(默认值是应用开发者帐号)
FRIENDSHIPS_GROUPS_READ
          好友分组读取接口组
FRIENDSHIPS_GROUPS_WRITE
          好友分组写入接口组
INVITATION_WRITE
          邀请发送接口
STATUSES_TO_ME_READ
          定向微博读取接口组
 
Method Summary
 String toString()
           
 String value()
           
static Scope valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Scope[] 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, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ALL

public static final Scope ALL
请求下列所有scope权限


EMAIL

public static final Scope EMAIL
用户的联系邮箱


DIRECT_MESSAGES_WRITE

public static final Scope DIRECT_MESSAGES_WRITE
私信发送接口


DIRECT_MESSAGES_READ

public static final Scope DIRECT_MESSAGES_READ
私信读取接口


INVITATION_WRITE

public static final Scope INVITATION_WRITE
邀请发送接口


FRIENDSHIPS_GROUPS_READ

public static final Scope FRIENDSHIPS_GROUPS_READ
好友分组读取接口组


FRIENDSHIPS_GROUPS_WRITE

public static final Scope FRIENDSHIPS_GROUPS_WRITE
好友分组写入接口组


STATUSES_TO_ME_READ

public static final Scope STATUSES_TO_ME_READ
定向微博读取接口组


FOLLOW_APP_OFFICIAL_MICROBLOG

public static final Scope FOLLOW_APP_OFFICIAL_MICROBLOG
关注应用官方微博,该参数不对应具体接口,只需在应用控制台填写官方帐号即可(默认值是应用开发者帐号)

Method Detail

values

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

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

valueOf

public static Scope 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

value

public String value()

toString

public String toString()
Overrides:
toString in class Enum<Scope>


Copyright © 2014. All Rights Reserved.