Examples of IdentityObjectType


Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

   public User createUser(String identityName) throws IdentityException
   {
      checkNotNullArgument(identityName, "Identity name");
      checkObjectName(identityName);

      IdentityObjectType iot = getUserObjectType();

      IdentityObject identityObject = getRepository().createIdentityObject(getInvocationContext(), identityName, iot);

      return createUser(identityObject);
   }
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

      checkNotNullArgument(groupName, "Group name");
      checkNotNullArgument(groupType, "Group type");
      checkObjectName(groupName);
      checkObjectName(groupType);

      IdentityObjectType iot = getIdentityObjectType(groupType);

      IdentityObject identityObject = getRepository().createIdentityObject(getInvocationContext(), groupName, iot);

      return createGroup(identityObject);
   }
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

      getRepository().removeIdentityObject(getInvocationContext(), createIdentityObjectForGroupId(groupId));
   }

   public int getUserCount() throws IdentityException
   {
      IdentityObjectType iot = getUserObjectType();

      return getRepository().getIdentityObjectsCount(getInvocationContext(), iot);
   }
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

   public int getGroupTypeCount(String groupType) throws IdentityException
   {
      checkNotNullArgument(groupType, "Group type");

      IdentityObjectType iot = getIdentityObjectType(groupType);

      return getRepository().getIdentityObjectsCount(getInvocationContext(), iot);
   }
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

            throw new IdentityException("identity id cannot be null");
         }

         String dn = id;

         IdentityObjectType type = null;

         //Recognize the type by ctx DN

         IdentityObjectType[] possibleTypes = getConfiguration(ctx).getConfiguredTypes();
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

      featuresDescription = new RelationshipManagerFeaturesDescription()
      {
         public boolean isIdentityAssociationSupported(GroupType fromGroupType)
         {

            IdentityObjectType identityOT = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType();
            IdentityObjectType groupIdentityOT = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType(fromGroupType);

            try
            {
               return getSessionContext().getIdentityStoreRepository().getSupportedFeatures().
                  isRelationshipTypeSupported(groupIdentityOT, identityOT, MEMBER);
            }
            catch (IdentityException e)
            {
               return false;
            }

         }

         public boolean isGroupAssociationSupported(GroupType fromGroupType, GroupType toGroupType)
         {
            IdentityObjectType toGroupOT = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType(toGroupType);
            IdentityObjectType fromGroupOT = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType(fromGroupType);

            try
            {
               return getSessionContext().getIdentityStoreRepository().getSupportedFeatures().
                  isRelationshipTypeSupported(fromGroupOT, toGroupOT, MEMBER);
            }
            catch (IdentityException e)
            {
               return false;
            }
         }

         public boolean isIdentitiesSearchControlSupported(IdentitySearchControl control)
         {
            IdentityObjectType objectType = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType();

            if (control instanceof IdentityObjectSearchControl)
            {
               return getSessionContext().getIdentityStoreRepository().getSupportedFeatures().
                  isControlSupported(objectType, (IdentityObjectSearchControl)control);
            }
           
            return false;
         }


         public boolean isIdentitiesSearchControlSupported(Class controlClazz)
         {
            IdentityObjectType objectType = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType();

            return getSessionContext().getIdentityStoreRepository().getSupportedFeatures().
               isControlSupported(objectType, controlClazz);

         }

         public boolean isGroupsSearchControlSupported(GroupType groupType, IdentitySearchControl control)
         {
            IdentityObjectType objectType = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType(groupType);

            if (control instanceof IdentityObjectSearchControl)
            {
               return getSessionContext().getIdentityStoreRepository().getSupportedFeatures().
                  isControlSupported(objectType, (IdentityObjectSearchControl)control);
            }

            return false;
         }

         public boolean isGroupsSearchControlSupported(GroupType groupType, Class controlClazz)
         {
            IdentityObjectType objectType = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType(groupType);

            return getSessionContext().getIdentityStoreRepository().getSupportedFeatures().
               isControlSupported(objectType, controlClazz);
         }
      };
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

   public Collection<Group> findAssociatedGroups(Group group, GroupType groupType, boolean parent, boolean inherited, IdentitySearchControl[] controls) throws IdentityException
   {

      List<Group> identities = new LinkedList<Group>();

      IdentityObjectType iot = getIdentityObjectType(groupType);

      //TODO Handle inherited
      if (inherited)
      {
         throw new NotYetImplementedException("Support for 'inherited' argument is not yet implemented. Please use 'false' value for now");
      }

      Collection<IdentityObject> ios = getRepository().findIdentityObject(getInvocationContext(), createIdentityObject(group), MEMBER, parent, convertSearchControls(controls));

      for (IdentityObject io : ios)
      {
         if (io.getIdentityType().getName().equals(iot.getName()))
         {
            identities.add(createGroup(io));
         }
      }
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

   public Collection<Group> findAssociatedGroups(Identity identity, GroupType groupType, IdentitySearchControl[] controls) throws IdentityException
   {
      List<Group> identities = new LinkedList<Group>();

      IdentityObjectType iot = getIdentityObjectType(groupType);

      Collection<IdentityObject> ios = getRepository().findIdentityObject(getInvocationContext(), createIdentityObject(identity), MEMBER, false, convertSearchControls(controls));

      for (IdentityObject io : ios)
      {
         if (io.getIdentityType().getName().equals(iot.getName()))
         {
            identities.add(createGroup(io));
         }
      }
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

      return new SimpleGroup(identityObject.getName(), identityObject.getId(), groupType);
   }

   protected IdentityObject createIdentityObject(Identity identity)
   {
      IdentityObjectType iot = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType();

      return new SimpleIdentityObject(identity.getName(), identity.getId(), iot);
   }
View Full Code Here

Examples of org.jboss.identity.idm.spi.model.IdentityObjectType

      return new SimpleIdentityObject(identity.getName(), identity.getId(), iot);
   }

   protected IdentityObject createIdentityObject(Group group)
   {
      IdentityObjectType iot = getSessionContext().getIdentityObjectTypeMapper().getIdentityObjectType(group.getGroupType());

      return new SimpleIdentityObject(group.getName(), group.getId(), iot);
   }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.