• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java Converters类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中org.pac4j.core.profile.converter.Converters的典型用法代码示例。如果您正苦于以下问题:Java Converters类的具体用法?Java Converters怎么用?Java Converters使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



Converters类属于org.pac4j.core.profile.converter包,在下文中一共展示了Converters类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: convert

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
@Override
public Date convert(final Object attribute) {
    if (attribute instanceof Long) {
        final long seconds = (Long) attribute;
        return new FormattedDate(new Date(seconds * 1000), Converters.DATE_TZ_GENERAL_FORMAT, Locale.getDefault());
    } else if (attribute instanceof String) {
        final SimpleDateFormat sdf = new SimpleDateFormat(Converters.DATE_TZ_GENERAL_FORMAT);
        try {
            return new FormattedDate(sdf.parse((String) attribute), Converters.DATE_TZ_GENERAL_FORMAT, Locale.getDefault());
        } catch (final ParseException e) {
            throw new TechnicalException(e);
        }
    } else if (attribute instanceof FormattedDate) {
        return (Date) attribute;
    }
    return null;
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:18,代码来源:OidcLongTimeConverter.java


示例2: YahooAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public YahooAttributesDefinition() {
    Arrays.stream(new String[] {ABOUT_ME, FAMILY_NAME, GIVEN_NAME, LOCATION, NICKNAME, PROFILE_URL, TIME_ZONE, URI, AGE_CATEGORY})
            .forEach(a -> primary(a, Converters.STRING));
    primary(IS_CONNECTED, Converters.BOOLEAN);
    primary(BIRTH_YEAR, Converters.INTEGER);
    primary(LANG, Converters.LOCALE);
    primary(DISPLAY_AGE, Converters.INTEGER);
    primary(BIRTHDATE, new FormattedDateConverter("MM/dd"));
    primary(ADDRESSES, new JsonListConverter(YahooAddress.class, YahooAddress[].class));
    primary(DISCLOSURES, new JsonListConverter(YahooDisclosure.class, YahooDisclosure[].class));
    primary(EMAILS, new JsonListConverter(YahooEmail.class, YahooEmail[].class));
    primary(GENDER, new GenderConverter("m", "f"));
    primary(IMAGE, new JsonConverter<>(YahooImage.class));
    primary(INTERESTS, new JsonListConverter(YahooInterest.class, YahooInterest[].class));
    primary(CREATED, Converters.DATE_TZ_RFC822);
    primary(MEMBER_SINCE, Converters.DATE_TZ_RFC822);
    primary(UPDATED, Converters.DATE_TZ_RFC822);
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:19,代码来源:YahooAttributesDefinition.java


示例3: TwitterAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public TwitterAttributesDefinition() {
    Arrays.stream(new String[] {DESCRIPTION, LOCATION, NAME, SCREEN_NAME, TIME_ZONE, URL})
            .forEach(a -> primary(a, Converters.STRING));
    Arrays.stream(new String[] {CONTRIBUTORS_ENABLED, DEFAULT_PROFILE, DEFAULT_PROFILE_IMAGE, FOLLOW_REQUEST_SENT, FOLLOWING,
            GEO_ENABLED, IS_TRANSLATOR, NOTIFICATIONS, PROFILE_USE_BACKGROUND_IMAGE, PROTECTED, SHOW_ALL_INLINE_MEDIA,
            PROFILE_BACKGROUND_TILE, VERIFIED})
            .forEach(a -> primary(a, Converters.BOOLEAN));
    Arrays.stream(new String[] {FAVOURITES_COUNT, FOLLOWERS_COUNT, FRIENDS_COUNT, LISTED_COUNT, STATUSES_COUNT, UTC_OFFSET})
            .forEach(a -> primary(a, Converters.INTEGER));
    Arrays.stream(new String[] {PROFILE_BACKGROUND_IMAGE_URL, PROFILE_BACKGROUND_IMAGE_URL_HTTPS,
            PROFILE_IMAGE_URL, PROFILE_IMAGE_URL_HTTPS}).forEach(a -> primary(a, Converters.URL));
    Arrays.stream(new String[] {PROFILE_BACKGROUND_COLOR, PROFILE_LINK_COLOR, PROFILE_SIDEBAR_BORDER_COLOR,
            PROFILE_SIDEBAR_FILL_COLOR, PROFILE_TEXT_COLOR}).forEach(a -> primary(a, Converters.COLOR));
    primary(LANG, Converters.LOCALE);
    primary(CREATED_AT, new FormattedDateConverter("EEE MMM dd HH:mm:ss Z yyyy", Locale.US));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:17,代码来源:TwitterAttributesDefinition.java


示例4: StravaAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public StravaAttributesDefinition() {
    Arrays.stream(new String[] { FIRST_NAME, LAST_NAME, PROFILE_MEDIUM, PROFILE, CITY, STATE, COUNTRY,
            DATE_PREFERENCE, MEASUREMENT_PREFERENCE, EMAIL }).forEach(a -> primary(a, Converters.STRING));
    primary(ID, Converters.LONG);
    primary(RESOURCE_STATE, Converters.INTEGER);
    primary(BADGE_TYPE_ID, Converters.INTEGER);
    primary(FOLLOWER_COUNT, Converters.INTEGER);
    primary(FRIEND_COUNT, Converters.INTEGER);
    primary(PREMIUM, Converters.BOOLEAN);
    primary(SEX, new GenderConverter("m", "f"));
    primary(CREATED_AT, Converters.DATE_TZ_RFC822);
    primary(UPDATED_AT, Converters.DATE_TZ_RFC822);
    primary(CLUBS, new JsonListConverter(StravaClub.class, StravaClub[].class));
    final JsonListConverter multiGearConverter = new JsonListConverter(StravaGear.class, StravaGear[].class);
    primary(BIKES, multiGearConverter);
    primary(SHOES, multiGearConverter);
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:18,代码来源:StravaAttributesDefinition.java


示例5: QQAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public QQAttributesDefinition() {
    Arrays.stream(new String[] {DESCRIPTION, LOCATION, NAME, SCREEN_NAME, TIME_ZONE, URL})
            .forEach(a -> primary(a, Converters.STRING));
    Arrays.stream(new String[] {CONTRIBUTORS_ENABLED, DEFAULT_PROFILE, DEFAULT_PROFILE_IMAGE, FOLLOW_REQUEST_SENT, FOLLOWING,
            GEO_ENABLED, IS_TRANSLATOR, NOTIFICATIONS, PROFILE_USE_BACKGROUND_IMAGE, PROTECTED, SHOW_ALL_INLINE_MEDIA,
            PROFILE_BACKGROUND_TILE, VERIFIED})
            .forEach(a -> primary(a, Converters.BOOLEAN));
    Arrays.stream(new String[] {FAVOURITES_COUNT, FOLLOWERS_COUNT, FRIENDS_COUNT, LISTED_COUNT, STATUSES_COUNT, UTC_OFFSET})
            .forEach(a -> primary(a, Converters.INTEGER));
    Arrays.stream(new String[] {PROFILE_BACKGROUND_IMAGE_URL, PROFILE_BACKGROUND_IMAGE_URL_HTTPS,
            PROFILE_IMAGE_URL, PROFILE_IMAGE_URL_HTTPS}).forEach(a -> primary(a, Converters.URL));
    Arrays.stream(new String[] {PROFILE_BACKGROUND_COLOR, PROFILE_LINK_COLOR, PROFILE_SIDEBAR_BORDER_COLOR,
            PROFILE_SIDEBAR_FILL_COLOR, PROFILE_TEXT_COLOR}).forEach(a -> primary(a, Converters.COLOR));
    primary(LANG, Converters.LOCALE);
    primary(CREATED_AT, new FormattedDateConverter("EEE MMM dd HH:mm:ss Z yyyy", Locale.US));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:17,代码来源:QQAttributesDefinition.java


示例6: SinaAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public SinaAttributesDefinition() {
    Arrays.stream(new String[] {DESCRIPTION, LOCATION, NAME, SCREEN_NAME, TIME_ZONE, URL})
            .forEach(a -> primary(a, Converters.STRING));
    Arrays.stream(new String[] {CONTRIBUTORS_ENABLED, DEFAULT_PROFILE, DEFAULT_PROFILE_IMAGE, FOLLOW_REQUEST_SENT, FOLLOWING,
            GEO_ENABLED, IS_TRANSLATOR, NOTIFICATIONS, PROFILE_USE_BACKGROUND_IMAGE, PROTECTED, SHOW_ALL_INLINE_MEDIA,
            PROFILE_BACKGROUND_TILE, VERIFIED})
            .forEach(a -> primary(a, Converters.BOOLEAN));
    Arrays.stream(new String[] {FAVOURITES_COUNT, FOLLOWERS_COUNT, FRIENDS_COUNT, LISTED_COUNT, STATUSES_COUNT, UTC_OFFSET})
            .forEach(a -> primary(a, Converters.INTEGER));
    Arrays.stream(new String[] {PROFILE_BACKGROUND_IMAGE_URL, PROFILE_BACKGROUND_IMAGE_URL_HTTPS,
            PROFILE_IMAGE_URL, PROFILE_IMAGE_URL_HTTPS}).forEach(a -> primary(a, Converters.URL));
    Arrays.stream(new String[] {PROFILE_BACKGROUND_COLOR, PROFILE_LINK_COLOR, PROFILE_SIDEBAR_BORDER_COLOR,
            PROFILE_SIDEBAR_FILL_COLOR, PROFILE_TEXT_COLOR}).forEach(a -> primary(a, Converters.COLOR));
    primary(LANG, Converters.LOCALE);
    primary(CREATED_AT, new FormattedDateConverter("EEE MMM dd HH:mm:ss Z yyyy", Locale.US));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:17,代码来源:SinaAttributesDefinition.java


示例7: WeiXinAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public WeiXinAttributesDefinition(){
    addAttribute(OPEN_ID, Converters.stringConverter);
    addAttribute(NICK_NAME, Converters.stringConverter);
    addAttribute(SEX, Converters.integerConverter);
    addAttribute(COUNTRY, Converters.stringConverter);
    addAttribute(PROVINCE, Converters.stringConverter);
    addAttribute(CITY, Converters.stringConverter);
    addAttribute(HEAD_IMG_URL, Converters.stringConverter);
    addAttribute(UNION_ID, Converters.stringConverter);
}
 
开发者ID:luotuo,项目名称:cas4.0.x-server-wechat,代码行数:11,代码来源:WeiXinAttributesDefinition.java


示例8: FacebookProfileDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public FacebookProfileDefinition() {
    super(x -> new FacebookProfile());
    Arrays.stream(new String[] {
        NAME, MIDDLE_NAME, LAST_NAME, THIRD_PARTY_ID, ABOUT, POLITICAL, QUOTES, RELIGION, WEBSITE
    }).forEach(a -> primary(a, Converters.STRING));
    primary(TIMEZONE, Converters.INTEGER);
    primary(VERIFIED, Converters.BOOLEAN);
    primary(LINK, Converters.URL);
    final JsonConverter<FacebookObject> objectConverter = new JsonConverter<>(FacebookObject.class);
    final JsonConverter multiObjectConverter = new JsonConverter(List.class, new TypeReference<List<FacebookObject>>() {});
    final JsonConverter multiInfoConverter = new JsonConverter(List.class, new TypeReference<List<FacebookInfo>>() {});
    primary(UPDATED_TIME, Converters.DATE_TZ_GENERAL);
    primary(BIRTHDAY, new DateConverter("MM/dd/yyyy"));
    primary(RELATIONSHIP_STATUS, new FacebookRelationshipStatusConverter());
    primary(LANGUAGES, multiObjectConverter);
    primary(EDUCATION, new JsonConverter(List.class, new TypeReference<List<FacebookEducation>>() {}));
    primary(HOMETOWN, objectConverter);
    primary(INTERESTED_IN, new JsonConverter(List.class, new TypeReference<List<String>>() {}));
    primary(LOCATION, objectConverter);
    primary(FAVORITE_ATHLETES, multiObjectConverter);
    primary(FAVORITE_TEAMS, multiObjectConverter);
    primary(SIGNIFICANT_OTHER, objectConverter);
    primary(WORK, new JsonConverter(List.class, new TypeReference<List<FacebookWork>>() {}));
    secondary(FRIENDS, multiObjectConverter);
    secondary(MOVIES, multiInfoConverter);
    secondary(MUSIC, multiInfoConverter);
    secondary(BOOKS, multiInfoConverter);
    secondary(LIKES, multiInfoConverter);
    secondary(ALBUMS, new JsonConverter(List.class, new TypeReference<List<FacebookPhoto>>() {}));
    secondary(EVENTS, new JsonConverter(List.class, new TypeReference<List<FacebookEvent>>() {}));
    secondary(GROUPS, new JsonConverter(List.class, new TypeReference<List<FacebookGroup>>() {}));
    secondary(MUSIC_LISTENS, new JsonConverter(List.class, new TypeReference<List<FacebookMusicListen>>() {}));
    secondary(PICTURE, new JsonConverter<>(FacebookPicture.class));
}
 
开发者ID:millross,项目名称:pac4j-async,代码行数:35,代码来源:FacebookProfileDefinition.java


示例9: OrcidAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public OrcidAttributesDefinition() {
    primary(ORCID, Converters.STRING);
    primary(FIRST_NAME, Converters.STRING);
    primary(FAMILY_NAME, Converters.STRING);
    primary(URI, Converters.STRING);
    primary(CREATION_METHOD, Converters.STRING);
    primary(CLAIMED, Converters.BOOLEAN);
    primary(LOCALE, Converters.LOCALE);
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:10,代码来源:OrcidAttributesDefinition.java


示例10: GitHubAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public GitHubAttributesDefinition() {
    Arrays.asList(new String[] {
        URL, COMPANY, NAME, BLOG, LOGIN, EMAIL, LOCATION, TYPE, GRAVATAR_ID, AVATAR_URL, HTML_URL, BIO
    }).forEach(a -> primary(a, Converters.STRING));
    Arrays.asList(new String[] {
        FOLLOWING, PUBLIC_REPOS, PUBLIC_GISTS, DISK_USAGE, COLLABORATORS, OWNED_PRIVATE_REPOS, TOTAL_PRIVATE_REPOS,
        PRIVATE_GISTS, FOLLOWERS
    }).forEach(a -> primary(a, Converters.INTEGER));
    primary(HIREABLE, Converters.BOOLEAN);
    primary(CREATED_AT, Converters.DATE_TZ_RFC822);
    primary(UPDATED_AT, Converters.DATE_TZ_RFC822);
    primary(PLAN, new JsonConverter<>(GitHubPlan.class));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:14,代码来源:GitHubAttributesDefinition.java


示例11: DefaultGenericAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public DefaultGenericAttributesDefinition() {
    primary(EMAIL, Converters.STRING);
    primary(FIRST_NAME, Converters.STRING);
    primary(FAMILY_NAME, Converters.STRING);
    primary(DISPLAY_NAME, Converters.STRING);
    primary(GENDER, Converters.GENDER);
    primary(LOCALE, Converters.LOCALE);
    primary(PICTURE_URL, Converters.URL);
    primary(PROFILE_URL, Converters.URL);
    primary(EMAIL, Converters.STRING);
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:12,代码来源:DefaultGenericAttributesDefinition.java


示例12: WordPressAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public WordPressAttributesDefinition() {
    primary(DISPLAY_NAME, Converters.STRING);
    primary(Pac4jConstants.USERNAME, Converters.STRING);
    primary(EMAIL, Converters.STRING);
    primary(PRIMARY_BLOG, Converters.INTEGER);
    primary(AVATAR_URL, Converters.URL);
    primary(PROFILE_URL, Converters.URL);
    secondary(LINKS, new JsonConverter<>(WordPressLinks.class));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:10,代码来源:WordPressAttributesDefinition.java


示例13: FoursquareAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public FoursquareAttributesDefinition() {
    Arrays.stream(new String[] {
            FIRST_NAME, LAST_NAME, GENDER, HOME_CITY, BIO, EMAIL, PHOTO
    }).forEach(a -> primary(a, Converters.STRING));
    primary(GENDER, Converters.GENDER);
    primary(FIRENDS, new JsonConverter<>(FoursquareUserFriends.class));
    primary(CONTACT, new JsonConverter<>(FoursquareUserContact.class));
    primary(PHOTO, new JsonConverter<>(FoursquareUserPhoto.class));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:10,代码来源:FoursquareAttributesDefinition.java


示例14: CasOAuthWrapperAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public CasOAuthWrapperAttributesDefinition() {
    primary(IS_FROM_NEW_LOGIN, Converters.BOOLEAN);
    primary(AUTHENTICATION_DATE, new CasAuthenticationDateFormatter());
    primary(AUTHENTICATION_METHOD, Converters.STRING);
    primary(SUCCESSFUL_AUTHENTICATION_HANDLERS, Converters.STRING);
    primary(LONG_TERM_AUTHENTICATION_REQUEST_TOKEN_USED, Converters.BOOLEAN);
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:8,代码来源:CasOAuthWrapperAttributesDefinition.java


示例15: LinkedIn2AttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public LinkedIn2AttributesDefinition() {
    Arrays.stream(new String[] { FIRST_NAME, LAST_NAME, MAIDEN_NAME, FORMATTED_NAME, PHONETIC_FIRST_NAME, PHONETIC_LAST_NAME,
            FORMATTED_PHONETIC_NAME, HEADLINE, INDUSTRY, CURRENT_SHARE, SUMMARY, SPECIALTIES, PICTURE_URL, PUBLIC_PROFILE_URL,
            EMAIL_ADDRESS}).forEach(a -> primary(a, Converters.STRING));
    primary(NUM_CONNECTIONS, Converters.INTEGER);
    primary(NUM_CONNECTIONS_CAPPED, Converters.BOOLEAN);
    primary(LOCATION, new JsonConverter<>(LinkedIn2Location.class));
    secondary(POSITIONS, new JsonListConverter(LinkedIn2Position.class, LinkedIn2Position[].class));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:10,代码来源:LinkedIn2AttributesDefinition.java


示例16: FacebookAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public FacebookAttributesDefinition() {
    Arrays.stream(new String[] {
        NAME, FIRST_NAME, MIDDLE_NAME, LAST_NAME, LINK, THIRD_PARTY_ID, ABOUT, EMAIL, POLITICAL, QUOTES,
        RELIGION, WEBSITE
    }).forEach(a -> primary(a, Converters.STRING));
    primary(TIMEZONE, Converters.INTEGER);
    primary(VERIFIED, Converters.BOOLEAN);
    final JsonConverter<FacebookObject> objectConverter = new JsonConverter<>(FacebookObject.class);
    final JsonListConverter multiObjectConverter = new JsonListConverter(FacebookObject.class, FacebookObject[].class);
    final JsonListConverter multiStringConverter = new JsonListConverter(String.class, String[].class);
    final JsonListConverter multiInfoConverter = new JsonListConverter(FacebookInfo.class, FacebookInfo[].class);
    primary(GENDER, Converters.GENDER);
    primary(LOCALE, Converters.LOCALE);
    primary(UPDATED_TIME, Converters.DATE_TZ_GENERAL);
    primary(BIRTHDAY, new FormattedDateConverter("MM/dd/yyyy"));
    primary(RELATIONSHIP_STATUS, new FacebookRelationshipStatusConverter());
    primary(LANGUAGES, multiObjectConverter);
    primary(EDUCATION, new JsonListConverter(FacebookEducation.class, FacebookEducation[].class));
    primary(HOMETOWN, objectConverter);
    primary(INTERESTED_IN, multiStringConverter);
    primary(LOCATION, objectConverter);
    primary(FAVORITE_ATHLETES, multiObjectConverter);
    primary(FAVORITE_TEAMS, multiObjectConverter);
    primary(SIGNIFICANT_OTHER, objectConverter);
    primary(WORK, new JsonListConverter(FacebookWork.class, FacebookWork[].class));
    secondary(FRIENDS, multiObjectConverter);
    secondary(MOVIES, multiInfoConverter);
    secondary(MUSIC, multiInfoConverter);
    secondary(BOOKS, multiInfoConverter);
    secondary(LIKES, multiInfoConverter);
    secondary(ALBUMS, new JsonListConverter(FacebookPhoto.class, FacebookPhoto[].class));
    secondary(EVENTS, new JsonListConverter(FacebookEvent.class, FacebookEvent[].class));
    secondary(GROUPS, new JsonListConverter(FacebookGroup.class, FacebookGroup[].class));
    secondary(MUSIC_LISTENS, new JsonListConverter(FacebookMusicListen.class, FacebookMusicListen[].class));
    secondary(PICTURE, new JsonConverter<>(FacebookPicture.class));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:37,代码来源:FacebookAttributesDefinition.java


示例17: Google2AttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public Google2AttributesDefinition() {
    primary(DISPLAY_NAME, Converters.STRING);
    primary(GIVEN_NAME, Converters.STRING);
    primary(FAMILY_NAME, Converters.STRING);
    primary(URL, Converters.STRING);
    primary(PICTURE, Converters.STRING);
    primary(GENDER, Converters.GENDER);
    primary(LANGUAGE, Converters.LOCALE);
    primary(BIRTHDAY, new FormattedDateConverter("yyyy-MM-dd"));
    primary(EMAILS, new JsonListConverter(Google2Email.class, Google2Email[].class));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:12,代码来源:Google2AttributesDefinition.java


示例18: DropBoxAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public DropBoxAttributesDefinition() {
    primary(REFERRAL_LINK, Converters.STRING);
    primary(DISPLAY_NAME, Converters.STRING);
    primary(COUNTRY, Converters.LOCALE);
    secondary(SHARED, Converters.LONG);
    secondary(QUOTA, Converters.LONG);
    secondary(NORMAL, Converters.LONG);
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:9,代码来源:DropBoxAttributesDefinition.java


示例19: VkAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public VkAttributesDefinition() {
	Arrays.stream(new String[] {FIRST_NAME, LAST_NAME, PHOTO_50, PHOTO_100, PHOTO_200_ORIG, PHOTO_200, PHOTO_400_ORIG,
			PHOTO_MAX, PHOTO_MAX_ORIG, DOMAIN, MOBILE_PHONE, HOME_PHONE, SKYPE, SITE, STATUS}).forEach(a -> primary(a, Converters.STRING));
	primary(COMMON_COUNT, Converters.INTEGER);
	primary(RELATION, Converters.INTEGER);
	final VkBooleanConverter booleanConverter = new VkBooleanConverter();
	Arrays.stream(new String[] {ONLINE, ONLINE_MOBILE, HAS_MOBILE, CAN_POST, CAN_SEE_ALL_POST, CAN_SEE_AUDIO, CAN_WRITE_PRIVATE_MESSAGE})
			.forEach(a -> primary(a, booleanConverter));
	primary(BIRTH_DATE, new FormattedDateConverter("dd.MM.yyyy"));
	primary(SEX, new GenderIntegerConverter(2, 1));
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:12,代码来源:VkAttributesDefinition.java


示例20: GaeUserServiceAttributesDefinition

import org.pac4j.core.profile.converter.Converters; //导入依赖的package包/类
public GaeUserServiceAttributesDefinition() {
    primary(DISPLAYNAME, Converters.STRING);
    primary(EMAIL, Converters.STRING);
}
 
开发者ID:yaochi,项目名称:pac4j-plus,代码行数:5,代码来源:GaeUserServiceAttributesDefinition.java



注:本文中的org.pac4j.core.profile.converter.Converters类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java HighPerformanceRectangleVertexBufferObject类代码示例发布时间:2022-05-22
下一篇:
Java SchemaNode类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap