Class UmaRptService


  • @ApplicationScoped
    public class UmaRptService
    extends java.lang.Object
    RPT manager component
    Version:
    June 28, 2017
    Author:
    Yuriy Zabrovarnyy, Javier Rojas Blum
    • Constructor Detail

      • UmaRptService

        public UmaRptService()
    • Method Detail

      • getPermissionDns

        public static java.util.List<java.lang.String> getPermissionDns​(java.util.Collection<io.jans.as.model.uma.persistence.UmaPermission> permissions)
      • createDn

        public java.lang.String createDn​(java.lang.String tokenCode)
      • branchDn

        public java.lang.String branchDn()
      • persist

        public void persist​(UmaRPT rpt)
      • getRPTByCode

        public UmaRPT getRPTByCode​(java.lang.String rptCode)
      • deleteByCode

        public void deleteByCode​(java.lang.String rptCode)
      • addPermissionToRPT

        public boolean addPermissionToRPT​(UmaRPT rpt,
                                          java.util.Collection<io.jans.as.model.uma.persistence.UmaPermission> permissions)
      • addPermissionToRPT

        public boolean addPermissionToRPT​(UmaRPT rpt,
                                          io.jans.as.model.uma.persistence.UmaPermission... permission)
      • getRptPermissions

        public java.util.List<io.jans.as.model.uma.persistence.UmaPermission> getRptPermissions​(UmaRPT rpt)
      • rptExpirationDate

        public java.util.Date rptExpirationDate()
      • createRPTAndPersist

        public UmaRPT createRPTAndPersist​(ExecutionContext executionContext,
                                          java.util.List<io.jans.as.model.uma.persistence.UmaPermission> permissions)
      • merge

        public void merge​(UmaRPT rpt)
      • buildPermissionsJSONObject

        public org.json.JSONArray buildPermissionsJSONObject​(java.util.List<io.jans.as.model.uma.persistence.UmaPermission> permissions)
                                                      throws java.io.IOException,
                                                             org.json.JSONException
        Throws:
        java.io.IOException
        org.json.JSONException
      • addBranch

        public void addBranch()
      • addBranchIfNeeded

        public void addBranchIfNeeded()
      • containsBranch

        public boolean containsBranch()