Package com.nimbusds.langtag

Examples of com.nimbusds.langtag.LangTag


    if (! nameEntries.isEmpty()) {

      for (Map.Entry<LangTag,String> entry: nameEntries.entrySet()) {

        LangTag langTag = entry.getKey();
        String name = entry.getValue();

        if (name == null)
          continue;

        if (langTag == null)
          o.put("client_name", entry.getValue());
        else
          o.put("client_name#" + langTag, entry.getValue());
      }
    }


    if (! logoURIEntries.isEmpty()) {

      for (Map.Entry<LangTag,URI> entry: logoURIEntries.entrySet()) {

        LangTag langTag = entry.getKey();
        URI uri = entry.getValue();

        if (uri == null)
          continue;

        if (langTag == null)
          o.put("logo_uri", entry.getValue().toString());
        else
          o.put("logo_uri#" + langTag, entry.getValue().toString());
      }
    }


    if (! uriEntries.isEmpty()) {

      for (Map.Entry<LangTag,URI> entry: uriEntries.entrySet()) {

        LangTag langTag = entry.getKey();
        URI uri = entry.getValue();

        if (uri == null)
          continue;

        if (langTag == null)
          o.put("client_uri", entry.getValue().toString());
        else
          o.put("client_uri#" + langTag, entry.getValue().toString());
      }
    }


    if (! policyURIEntries.isEmpty()) {

      for (Map.Entry<LangTag,URI> entry: policyURIEntries.entrySet()) {

        LangTag langTag = entry.getKey();
        URI uri = entry.getValue();

        if (uri == null)
          continue;

        if (langTag == null)
          o.put("policy_uri", entry.getValue().toString());
        else
          o.put("policy_uri#" + langTag, entry.getValue().toString());
      }
    }


    if (! tosURIEntries.isEmpty()) {

      for (Map.Entry<LangTag,URI> entry: tosURIEntries.entrySet()) {

        LangTag langTag = entry.getKey();
        URI uri = entry.getValue();

        if (uri == null)
          continue;
View Full Code Here


    Map<LangTag,Object> matches = LangTagUtils.find(name, claims);
    Map<LangTag,T> out = new HashMap<>();

    for (Map.Entry<LangTag,Object> entry: matches.entrySet()) {

      LangTag langTag = entry.getKey();
      String compositeKey = name + (langTag != null ? "#" + langTag : "");

      try {
        out.put(langTag, JSONObjectUtils.getGeneric(claims, compositeKey, clazz));
      } catch (ParseException e) {
View Full Code Here

        // Process the key
        String claimNameWithOptLangTag = member.getKey();

        String claimName;
        LangTag langTag = null;

        if (claimNameWithOptLangTag.contains("#")) {

          String[] parts = claimNameWithOptLangTag.split("#", 2);
View Full Code Here

TOP

Related Classes of com.nimbusds.langtag.LangTag

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.