@Test public void testJoin() { final String codeStr = Scope.join(TEST_SCOPE_LIST); assertEquals(TEST_SCOPE_CODE_STR, codeStr); }
public static String join(@Nullable final List<Scope> scopes) { if (scopes == null || scopes.isEmpty()) { return null; } final List<String> scopeCodeList = convertToCodeList(scopes); return TextUtils.join(SCOPE_DELIMITER, scopeCodeList); }
Scope { public static String join(@Nullable final List<Scope> scopes) { if (scopes == null || scopes.isEmpty()) { return null; } final List<String> scopeCodeList = convertToCodeList(scopes); return TextUtils.join(SCOPE_DELIMITER, scopeCodeList); } }
Scope { public static String join(@Nullable final List<Scope> scopes) { if (scopes == null || scopes.isEmpty()) { return null; } final List<String> scopeCodeList = convertToCodeList(scopes); return TextUtils.join(SCOPE_DELIMITER, scopeCodeList); } Scope(@NonNull final String code); }
Scope { public static String join(@Nullable final List<Scope> scopes) { if (scopes == null || scopes.isEmpty()) { return null; } final List<String> scopeCodeList = convertToCodeList(scopes); return TextUtils.join(SCOPE_DELIMITER, scopeCodeList); } Scope(@NonNull final String code); @Nullable static Scope findScope(final String scopeCode); static String join(@Nullable final List<Scope> scopes); static List<Scope> parseToList(@Nullable final String scopeCodeStr); static List<Scope> convertToScopeList(final List<String> scopeCodeList); static List<String> convertToCodeList(final List<Scope> scopeList); @NonNull String getCode(); @Override boolean equals(final Object o); @Override int hashCode(); @Override String toString(); }
Scope { public static String join(@Nullable final List<Scope> scopes) { if (scopes == null || scopes.isEmpty()) { return null; } final List<String> scopeCodeList = convertToCodeList(scopes); return TextUtils.join(SCOPE_DELIMITER, scopeCodeList); } Scope(@NonNull final String code); @Nullable static Scope findScope(final String scopeCode); static String join(@Nullable final List<Scope> scopes); static List<Scope> parseToList(@Nullable final String scopeCodeStr); static List<Scope> convertToScopeList(final List<String> scopeCodeList); static List<String> convertToCodeList(final List<Scope> scopeList); @NonNull String getCode(); @Override boolean equals(final Object o); @Override int hashCode(); @Override String toString(); static final Scope PROFILE; static final Scope FRIEND; static final Scope GROUP; static final Scope MESSAGE; static final Scope OPENID_CONNECT; static final Scope OC_EMAIL; static final Scope OC_PHONE_NUMBER; static final Scope OC_GENDER; static final Scope OC_BIRTHDATE; static final Scope OC_ADDRESS; static final Scope OC_REAL_NAME; static final Scope ONE_TIME_SHARE; static final Scope OPEN_CHAT_TERM_STATUS; static final Scope OPEN_CHAT_ROOM_CREATE_JOIN; static final Scope OPEN_CHAT_SUBSCRIPTION_INFO; }