Class AttributesManagerEntry
- All Implemented Interfaces:
AttributesManager
- Author:
- Slavek Licehammer glory@ics.muni.cz
-
Field Summary
Fields inherited from interface cz.metacentrum.perun.core.api.AttributesManager
ATTRIBUTES_REGEXP, ENTITY_TYPES, LOGIN_NAMESPACE, NS_ENTITYLESS_ATTR, NS_ENTITYLESS_ATTR_DEF, NS_ENTITYLESS_ATTR_OPT, NS_FACILITY_ATTR, NS_FACILITY_ATTR_CORE, NS_FACILITY_ATTR_DEF, NS_FACILITY_ATTR_OPT, NS_FACILITY_ATTR_VIRT, NS_GROUP_ATTR, NS_GROUP_ATTR_CORE, NS_GROUP_ATTR_DEF, NS_GROUP_ATTR_OPT, NS_GROUP_ATTR_VIRT, NS_GROUP_RESOURCE_ATTR, NS_GROUP_RESOURCE_ATTR_DEF, NS_GROUP_RESOURCE_ATTR_OPT, NS_GROUP_RESOURCE_ATTR_VIRT, NS_HOST_ATTR, NS_HOST_ATTR_CORE, NS_HOST_ATTR_DEF, NS_HOST_ATTR_OPT, NS_HOST_ATTR_VIRT, NS_MEMBER_ATTR, NS_MEMBER_ATTR_CORE, NS_MEMBER_ATTR_DEF, NS_MEMBER_ATTR_OPT, NS_MEMBER_ATTR_VIRT, NS_MEMBER_GROUP_ATTR, NS_MEMBER_GROUP_ATTR_DEF, NS_MEMBER_GROUP_ATTR_OPT, NS_MEMBER_GROUP_ATTR_VIRT, NS_MEMBER_RESOURCE_ATTR, NS_MEMBER_RESOURCE_ATTR_DEF, NS_MEMBER_RESOURCE_ATTR_OPT, NS_MEMBER_RESOURCE_ATTR_VIRT, NS_RESOURCE_ATTR, NS_RESOURCE_ATTR_CORE, NS_RESOURCE_ATTR_DEF, NS_RESOURCE_ATTR_OPT, NS_RESOURCE_ATTR_VIRT, NS_UES_ATTR, NS_UES_ATTR_CORE, NS_UES_ATTR_DEF, NS_UES_ATTR_OPT, NS_UES_ATTR_VIRT, NS_USER_ATTR, NS_USER_ATTR_CORE, NS_USER_ATTR_DEF, NS_USER_ATTR_OPT, NS_USER_ATTR_VIRT, NS_USER_FACILITY_ATTR, NS_USER_FACILITY_ATTR_DEF, NS_USER_FACILITY_ATTR_OPT, NS_USER_FACILITY_ATTR_VIRT, NS_VO_ATTR, NS_VO_ATTR_CORE, NS_VO_ATTR_DEF, NS_VO_ATTR_OPT, NS_VO_ATTR_VIRT, ORACLE_ARRAY_OF_NUMBERS, ORACLE_ARRAY_OF_STRINGS
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
checkAttributeSemantics
(PerunSession sess, Facility facility, Attribute attribute) Check if value of this facility attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Facility facility, User user, Attribute attribute) Check if value of this user-facility attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Group group, Attribute attribute) Checks if value of this group attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Host host, Attribute attribute) Checks if value of this host attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Member member, Attribute attribute) Check if value of this member attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Member member, Group group, Attribute attribute) Check if value of this member-group attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Member member, Resource resource, Attribute attribute) Check if value of this member-resource attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Resource resource, Attribute attribute) Check if value of this resource attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Resource resource, Group group, Attribute attribute) Checks if value of this group-resource attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, UserExtSource ues, Attribute attribute) Checks if value of this user external source attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, User user, Attribute attribute) Check if value of this user attribute has valid semantics.void
checkAttributeSemantics
(PerunSession sess, Vo vo, Attribute attribute) Check if value of this vo attribute has valid semantics.void
checkAttributesSemantics
(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<Attribute> attributes) Check if value of attributes has valid semantics.void
checkAttributesSemantics
(PerunSession sess, Facility facility, User user, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on themvoid
checkAttributesSemantics
(PerunSession sess, Facility facility, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Host host, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Member member, Group group, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Member member, Group group, List<Attribute> attributes, boolean workWithUserAttributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes, boolean workWithUserAttributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Member member, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on themvoid
checkAttributesSemantics
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes, boolean workWithGroupAttribute) void
checkAttributesSemantics
(PerunSession sess, Resource resource, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, UserExtSource ues, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, User user, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSemantics
(PerunSession sess, Vo vo, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<Attribute> attributes) Check if value of attributes has valid syntax.void
checkAttributesSyntax
(PerunSession sess, Facility facility, User user, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on themvoid
checkAttributesSyntax
(PerunSession sess, Facility facility, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Host host, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Member member, Group group, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Member member, Group group, List<Attribute> attributes, boolean workWithUserAttributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes, boolean workWithUserAttributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Member member, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on themvoid
checkAttributesSyntax
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes, boolean workWithGroupAttribute) void
checkAttributesSyntax
(PerunSession sess, Resource resource, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, UserExtSource ues, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, User user, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributesSyntax
(PerunSession sess, Vo vo, List<Attribute> attributes) PRIVILEGE: Check attributes only when principal has access to write on them.void
checkAttributeSyntax
(PerunSession sess, Facility facility, Attribute attribute) Check if value of this facility attribute has valid syntax.void
checkAttributeSyntax
(PerunSession sess, Facility facility, User user, Attribute attribute) Check if value of this user-facility attribute has valid syntax.void
checkAttributeSyntax
(PerunSession sess, Group group, Attribute attribute) Checks if value of this group attribute has valid syntaxvoid
checkAttributeSyntax
(PerunSession sess, Host host, Attribute attribute) Checks if value of this host attribute has valid syntaxvoid
checkAttributeSyntax
(PerunSession sess, Member member, Attribute attribute) Check if value of this member attribute has valid syntax.void
checkAttributeSyntax
(PerunSession sess, Member member, Group group, Attribute attribute) Check if value of this member-group attribute has valid syntax.void
checkAttributeSyntax
(PerunSession sess, Member member, Resource resource, Attribute attribute) Check if value of this member-resource attribute has valid syntax.void
checkAttributeSyntax
(PerunSession sess, Resource resource, Attribute attribute) Check if value of this resource attribute has valid syntax.void
checkAttributeSyntax
(PerunSession sess, Resource resource, Group group, Attribute attribute) Checks if value of this group-resource attribute has valid syntaxvoid
checkAttributeSyntax
(PerunSession sess, UserExtSource ues, Attribute attribute) Checks if value of this user external source attribute has valid syntaxvoid
checkAttributeSyntax
(PerunSession sess, User user, Attribute attribute) Check if value of this user attribute has valid syntax.void
checkAttributeSyntax
(PerunSession sess, Vo vo, Attribute attribute) Check if value of this vo attribute has valid syntax.void
checkNamespace
(PerunSession sess, AttributeDefinition attribute, String namespace) Determine if attribute is from specified namespace.void
checkNamespace
(PerunSession sess, List<? extends AttributeDefinition> attributes, String namespace) Determine if attributes are from specified namespace.void
convertAttributeToNonunique
(PerunSession session, int attrId) Converts attribute to non-unique.void
convertAttributeToUnique
(PerunSession session, int attrId) Converts attribute to unique.createAttribute
(PerunSession sess, AttributeDefinition attribute) Creates an attribute, the attribute is stored into the appropriate DB table according to the namespacevoid
deleteAttribute
(PerunSession sess, AttributeDefinition attribute) Deletes the attribute.void
deleteAttribute
(PerunSession sess, AttributeDefinition attributeDefinition, boolean force) Deletes the attribute.void
doTheMagic
(PerunSession sess, Member member) PRIVILEGE: Only for PerunAdmin.void
doTheMagic
(PerunSession sess, Member member, boolean trueMagic) This function takes all member-related attributes (member, user, member-resource, user-facility) and tries to fill them and set them.fillAttribute
(PerunSession sess, Facility facility, User user, Attribute attribute) This method tries to fill value of the user-facility attribute.fillAttribute
(PerunSession sess, Group group, Attribute attribute) This method tries to fill group attribute.fillAttribute
(PerunSession sess, Host host, Attribute attribute) This method tries to fill host attribute.fillAttribute
(PerunSession sess, Member member, Attribute attribute) This method tries to fill value of the member attribute.fillAttribute
(PerunSession sess, Member member, Group group, Attribute attribute) This method tries to fill value of the member-group attribute.fillAttribute
(PerunSession sess, Member member, Resource resource, Attribute attribute) This method tries to fill value of the member-resource attribute.fillAttribute
(PerunSession sess, Resource resource, Attribute attribute) This method tries to fill a value of the resource attribute.fillAttribute
(PerunSession sess, Resource resource, Group group, Attribute attribute) This method tries to fill group-resource attribute.fillAttribute
(PerunSession sess, UserExtSource ues, Attribute attribute) This method tries to fill value of the user external source attribute.fillAttribute
(PerunSession sess, User user, Attribute attribute) This method tries to fill value of the user attribute.fillAttributes
(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<Attribute> attributes) This method tries to fill value of the user, member, member-resource and user-facility attributes.fillAttributes
(PerunSession sess, Facility facility, User user, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Group group, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Host host, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Member member, Group group, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Member member, Group group, List<Attribute> attributes, boolean workWithUserAttributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes, boolean workWithUserAttributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Member member, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes, boolean workWithGroupAttributes) fillAttributes
(PerunSession sess, Resource resource, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, UserExtSource ues, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.fillAttributes
(PerunSession sess, User user, List<Attribute> attributes) PRIVILEGE: Fill attributes only when principal has access to write on them.getAllAttributesStartWithNameWithoutNullValue
(PerunSession sess, Group group, String startPartOfName) Get all non-empty attributes associated with the group starts with name startPartOfName.getAllAttributesStartWithNameWithoutNullValue
(PerunSession sess, Resource resource, String startPartOfName) Get all non-empty attributes associated with the resource starts with name startPartOfName.getAllNamespaces
(PerunSession sess) Returns list of all possible namespaces.getAttribute
(PerunSession sess, Facility facility, User user, String attributeName) Get particular attribute for the user on this facility.getAttribute
(PerunSession sess, Facility facility, String attributeName) Get particular attribute for the facility.getAttribute
(PerunSession sess, Group group, String attributeName) Get particular attribute for the group.getAttribute
(PerunSession sess, Host host, String attributeName) Get particular attribute for the hostgetAttribute
(PerunSession sess, Member member, Group group, String attributeName) Get particular attribute for the member in this group.getAttribute
(PerunSession sess, Member member, Resource resource, String attributeName) Get particular attribute for the member on this resource.getAttribute
(PerunSession sess, Member member, String attributeName) Get particular attribute for the member.getAttribute
(PerunSession sess, Resource resource, Group group, String attributeName) Get particular group attribute on resourcegetAttribute
(PerunSession sess, Resource resource, String attributeName) Get particular attribute for the resource.getAttribute
(PerunSession sess, UserExtSource ues, String attributeName) Get particular attribute for the user external source.getAttribute
(PerunSession sess, User user, String attributeName) Get particular attribute for the user.getAttribute
(PerunSession sess, Vo vo, String attributeName) Get particular attribute for the vo.getAttribute
(PerunSession sess, String key, String attributeName) Get particular entityless attributegetAttributeById
(PerunSession sess, Facility facility, int id) Get particular attribute for the facility.getAttributeById
(PerunSession sess, Facility facility, User user, int id) Get particular attribute for the user on this facility.getAttributeById
(PerunSession sess, Group group, int id) Get particular attribute for groupgetAttributeById
(PerunSession sess, Host host, int id) Get particular attribute for the hostgetAttributeById
(PerunSession sess, Member member, int id) Get particular attribute for the member.getAttributeById
(PerunSession sess, Member member, Group group, int id) Get particular attribute for the member in this group.getAttributeById
(PerunSession sess, Member member, Resource resource, int id) Get particular attribute for the member on this resource.getAttributeById
(PerunSession sess, Resource resource, int id) Get particular attribute for the resource.getAttributeById
(PerunSession sess, Resource resource, Group group, int id) Get particular group attribute on this resourcegetAttributeById
(PerunSession sess, UserExtSource ues, int id) Get particular attribute for user external sourcegetAttributeById
(PerunSession sess, User user, int id) Get particular attribute for the user.getAttributeById
(PerunSession sess, Vo vo, int id) Get particular attribute for the vo.getAttributeDefinition
(PerunSession sess, String attributeName) Get attribute definition (attribute without defined value).getAttributeDefinitionById
(PerunSession sess, int id) Get attribute definition (attribute without defined value).getAttributePolicyCollections
(PerunSession sess, int attributeId) Gets attribute policy collections for an attribute definition with given id.getAttributeRights
(PerunSession sess, int attributeId) Deprecated.getAttributeRules
(PerunSession sess, int attributeId) Gets attribute rules containing policy collections and critical actions for an attribute definition with given idgetAttributes
(PerunSession sess, Facility facility) Get all non-empty attributes associated with the facility.getAttributes
(PerunSession sess, Facility facility, Resource resource, User user, Member member) Get all non-empty member, user, member-resource and user-facility attributes.getAttributes
(PerunSession sess, Facility facility, User user) Get all non-empty attributes associated with the user on the facility.getAttributes
(PerunSession sess, Facility facility, List<String> attrNames) Get all attributes associated with the facility which have name in list attrNames (empty too).getAttributes
(PerunSession sess, Group group) Get all non-empty attributes associated with the group.getAttributes
(PerunSession sess, Group group, List<String> attrNames) Get all attributes associated with the group which have name in list attrNames (empty too).getAttributes
(PerunSession sess, Host host) Get all non-empty attributes associated with the hostgetAttributes
(PerunSession sess, Host host, List<String> attrNames) Get all attributes associated with the host which have name in list attrNames (empty too).getAttributes
(PerunSession sess, Member member) Get all non-empty attributes associated with the member.getAttributes
(PerunSession sess, Member member, boolean workWithUserAttributes) Get all non-empty attributes associated with the member and if workWithUserAttributes is true, get all non-empty attributes associated with user, who is this member.getAttributes
(PerunSession sess, Member member, Group group) Get all non-empty attributes associated with the member in the group.getAttributes
(PerunSession sess, Member member, Group group, List<String> attrNames) Get all attributes (empty and virtual too)associated with the member in the group which have name in list attrNames.getAttributes
(PerunSession sess, Member member, Group group, List<String> attrNames, boolean workWithUserAttributes) Get all attributes associated with the member in the group which have name in list attrNames (empty too).getAttributes
(PerunSession sess, Member member, Resource resource) Get all non-empty attributes associated with the member on the resource.getAttributes
(PerunSession sess, Member member, Resource resource, boolean workWithUserAttributes) Gets all non-empty attributes associated with the member on the resource and if workWithUserAttributes is true, gets also all non-empty user, user-facility and member attributes.getAttributes
(PerunSession sess, Member member, Resource resource, List<String> attrNames, boolean workWithUserAttributes) Gets selected non-empty attributes associated with the member and the resource.getAttributes
(PerunSession sess, Member member, List<String> attrNames) Get all attributes associated with the member which have name in list attrNames (empty too).getAttributes
(PerunSession sess, Member member, List<String> attrNames, boolean workWithUserAttributes) Get all attributes associated with the member which have name in list attrNames (empty too) Virtual attributes too.getAttributes
(PerunSession sess, Resource resource) Get all non-empty attributes associated with the resource.getAttributes
(PerunSession sess, Resource resource, Group group) Get all non-empty attributes associated with the group on resourcegetAttributes
(PerunSession sess, Resource resource, Group group, boolean workWithGroupAttributes) Get all non-empty attributes associated with the group and resource.getAttributes
(PerunSession sess, Resource resource, Group group, Member member, List<String> attrNames) Get all attributes by the list of attrNames if they are in one of these namespaces: - member - group - member-group - resource - member-resource - group-resource - user (get from member object) - facility (get from resource object) - user-facilitygetAttributes
(PerunSession sess, Resource resource, Group group, List<String> attrNames, boolean workWithGroupAttributes) Get all attributes associated with the group and the resource which have their name in list attrNames (empty too).getAttributes
(PerunSession sess, Resource resource, List<String> attrNames) Get all attributes associated with the resource which have name in list attrNames (empty too).getAttributes
(PerunSession sess, User user) Get all non-empty attributes associated with the user.getAttributes
(PerunSession sess, UserExtSource ues) Get all non-empty attributes associated with the UserExtSource.getAttributes
(PerunSession sess, UserExtSource ues, List<String> attrNames) Get all attributes associated with the userExtSource which have name in list attrNames (empty too).getAttributes
(PerunSession sess, User user, List<String> attrNames) Get all attributes associated with the user which have name in list attrNames (empty too).getAttributes
(PerunSession sess, Vo vo) Get all non-empty attributes associated with the vo.getAttributes
(PerunSession sess, Vo vo, List<String> attrNames) Get all attributes associated with the vo which have name in list attrNames (empty too).getAttributes
(PerunSession sess, String key) Get all entityless attributes with subject equaled String keygetAttributesByAttributeDefinition
(PerunSession sess, AttributeDefinition attributeDefinition) Returns all attributes with not-null value which fits the attributeDefinition.Get all attributes definition (attribute without defined value).getAttributesDefinition
(PerunSession sess, List<String> listOfAttributesNames) From listOfAttributesNames get list of attributeDefinitionsgetAttributesDefinitionByNamespace
(PerunSession sess, String namespace) Get attributes definition (attribute without defined value) with specified namespace.getAttributesDefinitionWithRights
(PerunSession sess, List<PerunBean> entities) Get all (for entities) attributeDefinitions which user has right to READ them and fill attribute writable (if user has also right to WRITE them).Gets the attributesManagerBl for this instance.getEntitylessAttributes
(PerunSession sess, String attrName) Get all entityless attributes with attributeNamegetEntitylessAttributesWithKeys
(PerunSession sess, String attrName) Get entityless attributes mapped by their keys.getEntitylessAttributesWithKeys
(PerunSession sess, String attrName, List<String> keys) Get entityless attributes mapped by their keys.getEntitylessKeys
(PerunSession sess, AttributeDefinition attributeDefinition) Returns list of Keys which fits the attributeDefinition.getFriendlyNameFromAttributeName
(String attributeName) Gets the friendly name from the attribute name.Returns list of definitions of IdP attributes that are filled to fedInfogetLogins
(PerunSession sess, User user) Get all attributes with user's logins.getModulesDependenciesGraph
(PerunSession session, GraphTextFormat format) Generates graph describing attribute modules dependencies.getModulesDependenciesGraph
(PerunSession session, GraphTextFormat format, String attributeName) Generates graph describing dependencies for given AttributeDefinition.getNamespaceFromAttributeName
(String attributeName) Gets the namespace from the attribute name.getRequiredAttributes
(PerunSession sess, Facility facility) Get facility attributes which are required by all services which are related to this facility.getRequiredAttributes
(PerunSession sess, Facility facility, User user) Get user-facility attributes which are required by services which are related to this user-facility.getRequiredAttributes
(PerunSession sess, Member member, boolean workWithUserAttributes) Get member attributes which are required by services which are relater to this member.getRequiredAttributes
(PerunSession sess, Member member, Group group, boolean workWithUserAttributes) Get member, member-group attributes which are required by services which are relater to this member.getRequiredAttributes
(PerunSession sess, Member member, Resource resource) Get member-resource attributes which are required by services which are relater to this member-resource.getRequiredAttributes
(PerunSession sess, Member member, Resource resource, boolean workWithUserAttributes) If workWithUserAttribute is false => Get member-resource attributes which are required by services which are relater to this member-resource.getRequiredAttributes
(PerunSession sess, Resource resource) Get resource attributes which are required by services which is relatod to this resource.getRequiredAttributes
(PerunSession sess, Resource resource, Service service, List<Member> members) Get member attributes which are required by service for each member in list of members.getRequiredAttributes
(PerunSession sess, Service service, Facility facility) Get facility attributes which are required by the service.getRequiredAttributes
(PerunSession sess, Service service, Facility facility, List<User> users) Get user-facility attributes which are required by the service for each user in list of users.getRequiredAttributes
(PerunSession sess, Service service, Group group) Get group required attributes for the servicegetRequiredAttributes
(PerunSession sess, Service service, Host host) Get host required attributes for the servicegetRequiredAttributes
(PerunSession sess, Service service, Member member) Get member attributes which are required by the service.getRequiredAttributes
(PerunSession sess, Service service, Member member, Group group) Get member-group attributes which are required by the service.getRequiredAttributes
(PerunSession sess, Service service, Member member, Group group, boolean workWithUserAttributes) PRIVILEGE: Get only those required attributes principal has access to.getRequiredAttributes
(PerunSession sess, Service service, Member member, Resource resource) Get member-resource attributes which are required by the service.getRequiredAttributes
(PerunSession sess, Service service, Member member, Resource resource, boolean workWithUserAttributes) PRIVILEGE: Get only those required attributes principal has access to.getRequiredAttributes
(PerunSession sess, Service service, Resource resource) Get resource attributes which are required by the service.getRequiredAttributes
(PerunSession sess, Service service, Resource resource, Group group) Get group-resource attributes required for the service.getRequiredAttributes
(PerunSession sess, Service service, Resource resource, Group group, boolean workWithGroupAttributes) Get group-resource attributes required for the service.getRequiredAttributes
(PerunSession sess, Service service, Resource resource, Group group, Member member, boolean workWithUserAttributes) Get member, member-resource and member-group attributes required by the specified service.getRequiredAttributes
(PerunSession sess, Service service, Resource resource, List<Member> members) Get member-resource attributes which are required by service for each member in list of members.getRequiredAttributes
(PerunSession sess, Service service, Resource resource, List<Member> members, boolean workWithUserAttributes) Get member-resource, member, user-facility and user attributes which are required by service for each member in list of members.getRequiredAttributes
(PerunSession sess, Service service, Vo vo) Get vo attributes which are required by the service.getRequiredAttributes
(PerunSession sess, Service service, List<User> users) Get user attributes which are required by the service for each user in list of users.getRequiredAttributes
(PerunSession sess, User user) Get user attributes which are required by services which are relater to this user.getRequiredAttributes
(PerunSession sess, List<Service> services, Facility facility) Get facility attributes which are required by the services.getRequiredAttributes
(PerunSession sess, List<Service> services, Resource resource) Get resource attributes which are required by the services.getRequiredAttributesDefinition
(PerunSession sess, Service service) Get all attributes which are required by service.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Facility facility, Resource resource, User user, Member member) Get member, user, member-resource and user-facility attributes which are required by services which are defined on "resourceToGetServicesFrom" resource.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Facility facility, User user) Get user-facility attributes which are required by services which are defined on specified resourcegetResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Group group) Get group attributes which are required by services defined on specified resourcegetResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Host host) Get host attributes which are required by services defined on specified resourcegetResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Member member) Get member attributes which are required by services defined on specified resourcegetResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Member member, Group group) Get member-group attributes which are required by services defined on specified resource Services are known from the resourceToGetServicesFrom.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Member member, Group group, boolean workWithUserAttributes) Get member-group attributes which are required by services defined on specified resource and if workWithUserAttributes is true also user and member attributes.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Member member, Resource resource) Get member-resource attributes which are required by services which are defined on "resourceToGetServicesFrom" resource.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Member member, Resource resource, boolean workWithUserAttributes) Get member-resource attributes which are required by services and if workWithUserAttributes is true also user, user-facility and member attributes.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Resource resource, Group group) Get group-resource attributes which are required by services defined on specified resourcegetResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Resource resource, Group group, boolean workWithGroupAttributes) Get group-resource attributes which are required by services defined on specified resource Get also group attributes, if workWithGroupAttributes is true.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, Resource resource, Group group, Member member, boolean workWithUserAttributes) Get member-group and member-resource attributes required by the services specified on resource Get also user, member, user-facility attributes, if workWithUserAttributes is true.getResourceRequiredAttributes
(PerunSession sess, Resource resourceToGetServicesFrom, User user) Get user attributes which are required by services defined on specified resourceboolean
isCoreAttribute
(PerunSession sess, AttributeDefinition attribute) Determine if attribute is core attribute.boolean
isCoreManagedAttribute
(PerunSession sess, AttributeDefinition attribute) Determine if attribute is core-managed attribute.boolean
isFromNamespace
(PerunSession sess, AttributeDefinition attribute, String namespace) Determine if attribute is from specified namespace.boolean
isOptAttribute
(PerunSession sess, AttributeDefinition attribute) Determine if attribute is optional (opt) attribute.void
removeAllAttributes
(PerunSession sess, Facility facility) Unset all attributes for the facility.void
removeAllAttributes
(PerunSession sess, Facility facility, boolean removeAlsoUserFacilityAttributes) Unset all attributes for the facility.void
removeAllAttributes
(PerunSession sess, Facility facility, User user) Unset all attributes for the user on the facility.void
removeAllAttributes
(PerunSession sess, Group group) Unset all attributes for the group.void
removeAllAttributes
(PerunSession sess, Host host) Unset all attributes for the hostvoid
removeAllAttributes
(PerunSession sess, Member member) Unset all attributes for the member.void
removeAllAttributes
(PerunSession sess, Member member, Group group) Unset all attributes for the member in the group.void
removeAllAttributes
(PerunSession sess, Member member, Resource resource) Unset all attributes for the member on the resource.void
removeAllAttributes
(PerunSession sess, Resource resource) Unset all attributes for the resource.void
removeAllAttributes
(PerunSession sess, Resource resource, Group group) Remove all attributes for group on resourcevoid
removeAllAttributes
(PerunSession sess, Resource resource, Group group, boolean workWithGroupAttributes) Unset all attributes for the group and resource.void
removeAllAttributes
(PerunSession sess, User user) Unset all attributes for the user.void
removeAllAttributes
(PerunSession sess, UserExtSource ues) Unset all attributes for the user external source.void
removeAllAttributes
(PerunSession sess, Vo vo) Unset all attributes for the vo.void
removeAttribute
(PerunSession sess, Facility facility, AttributeDefinition attribute) Unset particular attribute for the facility.void
removeAttribute
(PerunSession sess, Facility facility, User user, AttributeDefinition attribute) Unset particular attribute for the user on the facility.void
removeAttribute
(PerunSession sess, Group group, AttributeDefinition attribute) Unset particular attribute for the group.void
removeAttribute
(PerunSession sess, Host host, AttributeDefinition attribute) Unset particular attribute for the host.void
removeAttribute
(PerunSession sess, Member member, AttributeDefinition attribute) Unset particular attribute for the member.void
removeAttribute
(PerunSession sess, Member member, Group group, AttributeDefinition attribute) Unset particular attribute for the member in the group.void
removeAttribute
(PerunSession sess, Member member, Resource resource, AttributeDefinition attribute) Unset particular attribute for the member on the resource.void
removeAttribute
(PerunSession sess, Resource resource, AttributeDefinition attribute) Unset particular attribute for the resource.void
removeAttribute
(PerunSession sess, Resource resource, Group group, AttributeDefinition attribute) Unset particular group attribute on the resourcevoid
removeAttribute
(PerunSession sess, UserExtSource ues, AttributeDefinition attribute) Unset particular attribute for the user external source.void
removeAttribute
(PerunSession sess, User user, AttributeDefinition attribute) Unset particular attribute for the user.void
removeAttribute
(PerunSession sess, Vo vo, AttributeDefinition attribute) Unset particular attribute for the vo.void
removeAttribute
(PerunSession sess, String key, AttributeDefinition attribute) Unset particular entityless attribute with subject equals key.void
removeAttributes
(PerunSession sess, Facility facility, Resource resource, Group group, User user, Member member, List<? extends AttributeDefinition> attributes) Unset the member, user, member-group, member-resource and user-facility attributes.void
removeAttributes
(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<? extends AttributeDefinition> attributes) Unset the member, user, member-resource and user-facility attributes.void
removeAttributes
(PerunSession sess, Facility facility, User user, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Facility facility, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Group group, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Host host, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Member member, boolean workWithUserAttributes, List<? extends AttributeDefinition> attributes) Unset all non-empty attributes associated with the member and if workWithUserAttributes is true, unset all non-empty attributes associated with user, who is this member.void
removeAttributes
(PerunSession sess, Member member, Group group, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Member member, Group group, List<? extends AttributeDefinition> attributes, boolean workWithUserAttributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Member member, Resource resource, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Member member, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Resource resource, Group group, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Resource resource, Group group, List<? extends AttributeDefinition> attributes, boolean workWithGroupAttributes) Unset the group-resource attributes.void
removeAttributes
(PerunSession sess, Resource resource, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, UserExtSource ues, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, User user, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
removeAttributes
(PerunSession sess, Vo vo, List<? extends AttributeDefinition> attributes) PRIVILEGE: Remove attributes only when principal has access to write on them.void
setAttribute
(PerunSession sess, Facility facility, Attribute attribute) Store the particular attribute associated with the facility.void
setAttribute
(PerunSession sess, Facility facility, User user, Attribute attribute) Store the attribute associated with the facility and user combination.void
setAttribute
(PerunSession sess, Group group, Attribute attribute) Store the particular attribute associated with the group.void
setAttribute
(PerunSession sess, Host host, Attribute attribute) Store the attribute associated with the host.void
setAttribute
(PerunSession sess, Member member, Attribute attribute) Store the particular attribute associated with the member.void
setAttribute
(PerunSession sess, Member member, Group group, Attribute attribute) Store the particular attribute associated with the group and member combination.void
setAttribute
(PerunSession sess, Member member, Resource resource, Attribute attribute) Store the particular attribute associated with the resource and member combination.void
setAttribute
(PerunSession sess, Resource resource, Attribute attribute) Store the particular attribute associated with the resource.void
setAttribute
(PerunSession sess, Resource resource, Group group, Attribute attribute) Stores attribute associated with group resource combination.void
setAttribute
(PerunSession sess, UserExtSource ues, Attribute attribute) Store the attribute associated with the user external source.void
setAttribute
(PerunSession sess, User user, Attribute attribute) Store the attribute associated with the user.void
setAttribute
(PerunSession sess, Vo vo, Attribute attribute) Store the particular attribute associated with the vo.void
setAttribute
(PerunSession sess, String key, Attribute attribute) Stores entityless attribute (associateed witk string key).void
setAttributeActionCriticality
(PerunSession sess, AttributeDefinition attr, AttributeAction action, boolean critical, boolean global) Marks the action on attribute as critical, which may require additional authentication of user performing that action on attribute.void
setAttributePolicyCollections
(PerunSession sess, List<AttributePolicyCollection> policyCollections) Deletes old attribute policy collections and sets all new attribute policy collections.void
setAttributeRights
(PerunSession sess, List<AttributeRights> rights) Deprecated.void
setAttributes
(PerunSession sess, Facility facility, Resource resource, Group group, User user, Member member, List<Attribute> attributes) Store the member, user, member-group, member-resource and user-facility attributes.void
setAttributes
(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<Attribute> attributes) Store the member, user, member-resource and user-facility attributes.void
setAttributes
(PerunSession sess, Facility facility, User user, List<Attribute> attributes) Store the attributes associated with the facility and user combination.void
setAttributes
(PerunSession sess, Facility facility, List<Attribute> attributes) Store the attributes associated with the facility.void
setAttributes
(PerunSession sess, Group group, List<Attribute> attributes) Store the attributes associated with the group.void
setAttributes
(PerunSession sess, Host host, List<Attribute> attributes) Store the attributes associated with the host.void
setAttributes
(PerunSession sess, Member member, Group group, List<Attribute> attributes) Store the attributes associated with the member and group combination.void
setAttributes
(PerunSession sess, Member member, Group group, List<Attribute> attributes, boolean workWithUserAttributes) Store the attributes associated with the member and group combination.void
setAttributes
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes) Store the attributes associated with the resource and member combination.void
setAttributes
(PerunSession sess, Member member, Resource resource, List<Attribute> attributes, boolean workWithUserAttributes) Store the attributes associated with the resource and member combination.void
setAttributes
(PerunSession sess, Member member, List<Attribute> attributes) Store the attributes associated with the resource.void
setAttributes
(PerunSession sess, Member member, List<Attribute> attributes, boolean workWithUserAttributes) Store the attributes associated with member and user (which we get from this member) if workWithUserAttributes is true.void
setAttributes
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes) Store the attributes associated with the group on resource.void
setAttributes
(PerunSession sess, Resource resource, Group group, List<Attribute> attributes, boolean workWithGroupAttributes) Store the attributes associated with group and resource if workWithUserAttributes is true then also from group itself.void
setAttributes
(PerunSession sess, Resource resource, List<Attribute> attributes) Store the attributes associated with the resource.void
setAttributes
(PerunSession sess, UserExtSource ues, List<Attribute> attributes) Store the attributes associated with the user external source.void
setAttributes
(PerunSession sess, User user, List<Attribute> attributes) Store the attributes associated with the user.void
setAttributes
(PerunSession sess, Vo vo, List<Attribute> attributes) Store the attributes associated with the vo.void
setAttributesManagerBl
(AttributesManagerBl attributesManagerBl) Sets the attributesManagerBl for this instance.void
setPerunBl
(PerunBl perunBl) Sets the perunBl for this instance.updateAttributeDefinition
(PerunSession perunSession, AttributeDefinition attributeDefinition) Updates AttributeDefinition.
-
Constructor Details
-
AttributesManagerEntry
Constructor. -
AttributesManagerEntry
public AttributesManagerEntry()
-
-
Method Details
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Facility facility, Attribute attribute) throws PrivilegeException, FacilityNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this facility attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- facility for which you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exists in underlying data sourceWrongAttributeAssignmentException
- if attribute isn't facility attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semanticsAttributeNotExistsException
- if given attribute does not exist
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Vo vo, Attribute attribute) throws PrivilegeException, VoNotExistsException, WrongAttributeAssignmentException, AttributeNotExistsException, WrongReferenceAttributeValueException Description copied from interface:AttributesManager
Check if value of this vo attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionvo
- vo for which you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenVoNotExistsException
- if the vo doesn't exists in underlying data sourceWrongAttributeAssignmentException
- if attribute isn't vo attributeAttributeNotExistsException
- if given attribute does not existWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semantics
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Resource resource, Attribute attribute) throws PrivilegeException, ResourceNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this resource attribute has valid semantics.- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource for which you want to check validity of attributeattribute
- attribute to checkPRIVILEGE: Check attribute only when principal has access to write on it.
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in underlying data sourceWrongAttributeAssignmentException
- if attribute isn't resource attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semanticsAttributeNotExistsException
- if given attribute does not exist
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Member member, Resource resource, Attribute attribute) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Check if value of this member-resource attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- member for which (and for specified resource) you want to check validity of attributeresource
- resource for which (and for specified member) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in underlying data sourceMemberNotExistsException
- if specified member does not existWrongAttributeAssignmentException
- if attribute isn't member-resource attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semanticsAttributeNotExistsException
- if given attribute does not existMemberResourceMismatchException
- if member and resource are not in the same VO
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Member member, Group group, Attribute attribute) throws PrivilegeException, GroupNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, AttributeNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
Check if value of this member-group attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- member for which (and for specified group) you want to check validity of attributegroup
- group for which (and for specified member) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenGroupNotExistsException
- if specified group does not existMemberNotExistsException
- if specified member does not existWrongAttributeAssignmentException
- if attribute isn't member-resource attributeAttributeNotExistsException
- if given attribute does not existMemberGroupMismatchException
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Member member, Attribute attribute) throws PrivilegeException, MemberNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this member attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- member for which (and for specified resource) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenMemberNotExistsException
- if specified member does not existWrongAttributeAssignmentException
- if attribute isn't member-resource attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semanticsAttributeNotExistsException
- if given attribute does not exist
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Facility facility, User user, Attribute attribute) throws PrivilegeException, FacilityNotExistsException, UserNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this user-facility attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- facility for which (and for specified user) you want to check validity of attributeuser
- user for which (and for specified facility) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exists in underlying data sourceUserNotExistsException
- if the user doesn't exists in underlying data sourceWrongAttributeAssignmentException
- if attribute isn't user-facility attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semanticsAttributeNotExistsException
- if given attribute does not exist
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, User user, Attribute attribute) throws PrivilegeException, UserNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this user attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionuser
- user for which (and for specified facility) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenUserNotExistsException
- if the user doesn't exists in underlying data sourceWrongAttributeAssignmentException
- if attribute isn't user-facility attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semanticsAttributeNotExistsException
- if given attribute does not exist
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Host host, Attribute attribute) throws PrivilegeException, WrongAttributeAssignmentException, AttributeNotExistsException, HostNotExistsException Description copied from interface:AttributesManager
Checks if value of this host attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionhost
- host for which attribute validity is checked- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeAssignmentException
- if the attribute isn't host attributeAttributeNotExistsException
- if given attribute doesn't existHostNotExistsException
- if specified host doesn't exist
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Group group, Attribute attribute) throws PrivilegeException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException, GroupNotExistsException Description copied from interface:AttributesManager
Checks if value of this group attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessiongroup
- group for which attribute validity is checked- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeAssignmentException
- if the attribute isn't group attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semanticsAttributeNotExistsException
- if given attribute doesn't existGroupNotExistsException
- if specified group doesn't exist
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, Resource resource, Group group, Attribute attribute) throws PrivilegeException, AttributeNotExistsException, GroupNotExistsException, ResourceNotExistsException, GroupResourceMismatchException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException Description copied from interface:AttributesManager
Checks if value of this group-resource attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource which attr you want checkgroup
- group which attr you want to checkattribute
- attribute to be checked- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if given attribute doesn't existGroupNotExistsException
- if the group doesn't exist in underlying data sourceResourceNotExistsException
- if the resource doesn't exist in underlying data sourceGroupResourceMismatchException
- if group and resource are not in the same VOWrongAttributeAssignmentException
- if the attribute isn't group-resource attributeWrongReferenceAttributeValueException
- if the attribute value has wrong/illegal semantics
-
checkAttributeSemantics
public void checkAttributeSemantics(PerunSession sess, UserExtSource ues, Attribute attribute) throws PrivilegeException, WrongAttributeAssignmentException, AttributeNotExistsException, UserExtSourceNotExistsException Description copied from interface:AttributesManager
Checks if value of this user external source attribute has valid semantics.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSemantics
in interfaceAttributesManager
- Parameters:
sess
- perun sessionues
- user external source for which attribute validity is checked- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeAssignmentException
- if the attribute isn't UserExtSource attributeAttributeNotExistsException
- if given attribute doesn't existUserExtSourceNotExistsException
- if specified user external source doesn't exist
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Facility facility, Attribute attribute) throws PrivilegeException, FacilityNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this facility attribute has valid syntax.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- facility for which you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exist in underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't facility attributeAttributeNotExistsException
- if the attribute does not exist in underlying data source
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Vo vo, Attribute attribute) throws PrivilegeException, VoNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this vo attribute has valid syntax.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionvo
- vo for which you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenVoNotExistsException
- if the vo doesn't exist in underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't vo attributeAttributeNotExistsException
- if the attribute does not exist in underlying data source
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Resource resource, Attribute attribute) throws PrivilegeException, ResourceNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this resource attribute has valid syntax.- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource for which you want to check validity of attributeattribute
- attribute to checkPRIVILEGE: Check attribute only when principal has access to write on it.
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exist in underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't resource attributeAttributeNotExistsException
- if the attribute does not exist in underlying data source
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Member member, Resource resource, Attribute attribute) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Check if value of this member-resource attribute has valid syntax.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- member for which (and for specified resource) you want to check validity of attributeresource
- resource for which (and for specified member) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exist in underlying data sourceMemberNotExistsException
- if the member doesn't exist in the underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't member-resource attributeAttributeNotExistsException
- if the attribute does not exist in underlying data sourceMemberResourceMismatchException
- if member and resource are not in the same VO
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Member member, Group group, Attribute attribute) throws PrivilegeException, GroupNotExistsException, MemberNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
Check if value of this member-group attribute has valid syntax.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- member for which (and for specified group) you want to check validity of attributegroup
- group for which (and for specified member) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenGroupNotExistsException
- if the group doesn't exist in the underlying data sourceMemberNotExistsException
- if the member doesn't exist in the underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't member-group attributeAttributeNotExistsException
- if the attribute does not exist in underlying data sourceMemberGroupMismatchException
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Member member, Attribute attribute) throws PrivilegeException, MemberNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this member attribute has valid syntax.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- member for which (and for specified resource) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenMemberNotExistsException
- if the member doesn't exist in the underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't member attributeAttributeNotExistsException
- if the attribute does not exist in underlying data source
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Facility facility, User user, Attribute attribute) throws PrivilegeException, FacilityNotExistsException, UserNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this user-facility attribute has valid syntax.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- facility for which (and for specified user) you want to check validity of attributeuser
- user for which (and for specified facility) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exist in underlying data sourceUserNotExistsException
- if the user doesn't exist in underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't user-facility attributeAttributeNotExistsException
- if the attribute does not exist in underlying data source
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, User user, Attribute attribute) throws PrivilegeException, UserNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
Check if value of this user attribute has valid syntax.PRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionuser
- user for which (and for specified facility) you want to check validity of attributeattribute
- attribute to check- Throws:
PrivilegeException
- if privileges are not givenUserNotExistsException
- if the user doesn't exist in underlying data sourceWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if attribute isn't user attributeAttributeNotExistsException
- if the attribute does not exist in underlying data source
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Host host, Attribute attribute) throws PrivilegeException, WrongAttributeAssignmentException, AttributeNotExistsException, HostNotExistsException, WrongAttributeValueException Description copied from interface:AttributesManager
Checks if value of this host attribute has valid syntaxPRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionhost
- host for which attribute validity is checked- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeAssignmentException
- if the attribute isn't host attributeAttributeNotExistsException
- if given attribute doesn't existHostNotExistsException
- if specified host doesn't existWrongAttributeValueException
- if the attribute value has wrong/illegal syntax
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Group group, Attribute attribute) throws PrivilegeException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, GroupNotExistsException Description copied from interface:AttributesManager
Checks if value of this group attribute has valid syntaxPRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessiongroup
- group for which attribute validity is checked- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxWrongAttributeAssignmentException
- if the attribute isn't group attributeAttributeNotExistsException
- if given attribute doesn't existGroupNotExistsException
- if specified group doesn't exist
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, Resource resource, Group group, Attribute attribute) throws PrivilegeException, AttributeNotExistsException, WrongAttributeValueException, GroupNotExistsException, ResourceNotExistsException, GroupResourceMismatchException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Checks if value of this group-resource attribute has valid syntaxPRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource which attr you want checkgroup
- group which attr you want to checkattribute
- attribute to be checked- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if given attribute doesn't existWrongAttributeValueException
- if the attribute value has wrong/illegal syntaxGroupNotExistsException
- if the group doesn't exist in underlying data sourceResourceNotExistsException
- if the resource doesn't exist in underlying data sourceGroupResourceMismatchException
- if group and resource are not in the same VOWrongAttributeAssignmentException
- if the attribute isn't group-resource attribute
-
checkAttributeSyntax
public void checkAttributeSyntax(PerunSession sess, UserExtSource ues, Attribute attribute) throws PrivilegeException, WrongAttributeAssignmentException, AttributeNotExistsException, UserExtSourceNotExistsException, WrongAttributeValueException Description copied from interface:AttributesManager
Checks if value of this user external source attribute has valid syntaxPRIVILEGE: Check attribute only when principal has access to write on it.
- Specified by:
checkAttributeSyntax
in interfaceAttributesManager
- Parameters:
sess
- perun sessionues
- user external source for which attribute validity is checked- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeAssignmentException
- if the attribute isn't UserExtSource attributeAttributeNotExistsException
- if given attribute doesn't existUserExtSourceNotExistsException
- if specified user external source doesn't existWrongAttributeValueException
- if the attribute value has wrong/illegal syntax
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Facility facility, List<Attribute> attributes) throws PrivilegeException, FacilityNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
- Throws:
WrongReferenceAttributeValueException
- if any of attributes values has wrong/illegal semanticsPrivilegeException
FacilityNotExistsException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Vo vo, List<Attribute> attributes) throws PrivilegeException, VoNotExistsException, WrongAttributeAssignmentException, AttributeNotExistsException, WrongReferenceAttributeValueException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
- Throws:
WrongReferenceAttributeValueException
- if any of attributes values has wrong/illegal semanticsPrivilegeException
VoNotExistsException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Resource resource, List<Attribute> attributes) throws PrivilegeException, ResourceNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
- Throws:
WrongReferenceAttributeValueException
- if any of attributes values has wrong/illegal semanticsPrivilegeException
ResourceNotExistsException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Member member, Resource resource, List<Attribute> attributes) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Member member, Resource resource, List<Attribute> attributes, boolean workWithUserAttributes) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
workWithUserAttributes
- method can process also user and user-facility attributes (user is automatically get from member a facility is get from resource) !!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!- Throws:
PrivilegeException
ResourceNotExistsException
MemberNotExistsException
WrongAttributeAssignmentException
WrongReferenceAttributeValueException
AttributeNotExistsException
MemberResourceMismatchException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Member member, Group group, List<Attribute> attributes) throws PrivilegeException, MemberNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<Attribute> attributes) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, FacilityNotExistsException, UserNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Check if value of attributes has valid semantics. Attributes can be from namespace: member, user, member-resource and user-facility.PRIVILEGE: Check attributes only when principal has access to write on them.
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
- Throws:
PrivilegeException
ResourceNotExistsException
MemberNotExistsException
FacilityNotExistsException
UserNotExistsException
WrongAttributeAssignmentException
WrongReferenceAttributeValueException
AttributeNotExistsException
MemberResourceMismatchException
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Member member, List<Attribute> attributes) throws PrivilegeException, MemberNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on themBatch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
- Throws:
PrivilegeException
MemberNotExistsException
WrongAttributeAssignmentException
WrongReferenceAttributeValueException
AttributeNotExistsException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Facility facility, User user, List<Attribute> attributes) throws PrivilegeException, FacilityNotExistsException, UserNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on themBatch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
- Throws:
PrivilegeException
FacilityNotExistsException
UserNotExistsException
WrongAttributeAssignmentException
WrongReferenceAttributeValueException
AttributeNotExistsException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, User user, List<Attribute> attributes) throws PrivilegeException, UserNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
- Throws:
PrivilegeException
UserNotExistsException
WrongAttributeAssignmentException
WrongReferenceAttributeValueException
AttributeNotExistsException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Host host, List<Attribute> attributes) throws PrivilegeException, AttributeNotExistsException, HostNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.batch version of checkAttributeSemantics
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Resource resource, Group group, List<Attribute> attributes) throws PrivilegeException, AttributeNotExistsException, ResourceNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, GroupResourceMismatchException, WrongReferenceAttributeValueException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, UserExtSource ues, List<Attribute> attributes) throws PrivilegeException, AttributeNotExistsException, UserExtSourceNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.batch version of checkAttributeSemantics
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Member member, Group group, List<Attribute> attributes, boolean workWithUserAttributes) throws PrivilegeException, MemberNotExistsException, WrongAttributeAssignmentException, WrongReferenceAttributeValueException, AttributeNotExistsException, GroupNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSemantics
- Specified by:
checkAttributesSemantics
in interfaceAttributesManager
workWithUserAttributes
- method can process also user and member attributes (user is automatically get from member) !!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!- Throws:
PrivilegeException
MemberNotExistsException
WrongAttributeAssignmentException
WrongReferenceAttributeValueException
AttributeNotExistsException
GroupNotExistsException
MemberGroupMismatchException
- See Also:
-
checkAttributesSemantics
public void checkAttributesSemantics(PerunSession sess, Resource resource, Group group, List<Attribute> attributes, boolean workWithGroupAttribute) throws PrivilegeException, AttributeNotExistsException, ResourceNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, GroupResourceMismatchException, WrongReferenceAttributeValueException -
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Facility facility, List<Attribute> attributes) throws PrivilegeException, FacilityNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
- Throws:
WrongAttributeValueException
- if any of attributes values has wrong/illegal syntaxPrivilegeException
FacilityNotExistsException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Vo vo, List<Attribute> attributes) throws PrivilegeException, VoNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
- Throws:
WrongAttributeValueException
- if any of attributes values has wrong/illegal syntaxPrivilegeException
VoNotExistsException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Resource resource, List<Attribute> attributes) throws PrivilegeException, ResourceNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
- Throws:
WrongAttributeValueException
- if any of attributes values has wrong/illegal syntaxPrivilegeException
ResourceNotExistsException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Member member, Resource resource, List<Attribute> attributes) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Member member, Resource resource, List<Attribute> attributes, boolean workWithUserAttributes) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
workWithUserAttributes
- method can process also user and user-facility attributes (user is automatically get from member a facility is get from resource) !!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!- Throws:
PrivilegeException
ResourceNotExistsException
MemberNotExistsException
WrongAttributeValueException
WrongAttributeAssignmentException
AttributeNotExistsException
MemberResourceMismatchException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Member member, Group group, List<Attribute> attributes) throws PrivilegeException, MemberNotExistsException, GroupNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Member member, Group group, List<Attribute> attributes, boolean workWithUserAttributes) throws PrivilegeException, MemberNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, GroupNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
workWithUserAttributes
- method can process also user and member attributes (user is automatically get from member) !!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!- Throws:
PrivilegeException
MemberNotExistsException
WrongAttributeValueException
WrongAttributeAssignmentException
AttributeNotExistsException
GroupNotExistsException
MemberGroupMismatchException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<Attribute> attributes) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, FacilityNotExistsException, UserNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Check if value of attributes has valid syntax. Attributes can be from namespace: member, user, member-resource and user-facility.PRIVILEGE: Check attributes only when principal has access to write on them.
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
- Throws:
PrivilegeException
ResourceNotExistsException
MemberNotExistsException
FacilityNotExistsException
UserNotExistsException
WrongAttributeValueException
WrongAttributeAssignmentException
AttributeNotExistsException
MemberResourceMismatchException
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Member member, List<Attribute> attributes) throws PrivilegeException, MemberNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on themBatch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
- Throws:
PrivilegeException
MemberNotExistsException
WrongAttributeValueException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Facility facility, User user, List<Attribute> attributes) throws PrivilegeException, FacilityNotExistsException, UserNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on themBatch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
- Throws:
PrivilegeException
FacilityNotExistsException
UserNotExistsException
WrongAttributeValueException
WrongAttributeAssignmentException
AttributeNotExistsException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, User user, List<Attribute> attributes) throws PrivilegeException, UserNotExistsException, WrongAttributeValueException, WrongAttributeAssignmentException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Host host, List<Attribute> attributes) throws PrivilegeException, AttributeNotExistsException, HostNotExistsException, WrongAttributeAssignmentException, WrongAttributeValueException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.batch version of checkAttributeSyntax
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Resource resource, Group group, List<Attribute> attributes) throws PrivilegeException, AttributeNotExistsException, ResourceNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, WrongAttributeValueException, GroupResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.Batch version of checkAttributeSyntax
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, UserExtSource ues, List<Attribute> attributes) throws PrivilegeException, AttributeNotExistsException, UserExtSourceNotExistsException, WrongAttributeAssignmentException, WrongAttributeValueException Description copied from interface:AttributesManager
PRIVILEGE: Check attributes only when principal has access to write on them.batch version of checkAttributeSyntax
- Specified by:
checkAttributesSyntax
in interfaceAttributesManager
- Throws:
PrivilegeException
AttributeNotExistsException
UserExtSourceNotExistsException
WrongAttributeAssignmentException
WrongAttributeValueException
- See Also:
-
checkAttributesSyntax
public void checkAttributesSyntax(PerunSession sess, Resource resource, Group group, List<Attribute> attributes, boolean workWithGroupAttribute) throws PrivilegeException, AttributeNotExistsException, ResourceNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, WrongAttributeValueException, GroupResourceMismatchException -
checkNamespace
public void checkNamespace(PerunSession sess, AttributeDefinition attribute, String namespace) throws WrongAttributeAssignmentException Description copied from interface:AttributesManager
Determine if attribute is from specified namespace.PRIVILEGE: No access needed.
- Specified by:
checkNamespace
in interfaceAttributesManager
- Throws:
WrongAttributeAssignmentException
- if the attribute isn't from specified namespace
-
checkNamespace
public void checkNamespace(PerunSession sess, List<? extends AttributeDefinition> attributes, String namespace) throws WrongAttributeAssignmentException Description copied from interface:AttributesManager
Determine if attributes are from specified namespace.PRIVILEGE: No access needed.
- Specified by:
checkNamespace
in interfaceAttributesManager
- Throws:
WrongAttributeAssignmentException
- if any of the attribute isn't from specified namespace
-
convertAttributeToNonunique
public void convertAttributeToNonunique(PerunSession session, int attrId) throws PrivilegeException, AttributeNotExistsException, AttributeNotMarkedUniqueException Description copied from interface:AttributesManager
Converts attribute to non-unique.Unmarks unique flag from attribute definition, and deletes all values from a special table with unique constraint that ensures that all values remain unique.
- Specified by:
convertAttributeToNonunique
in interfaceAttributesManager
- Parameters:
session
- perun sessionattrId
- attribute id- Throws:
PrivilegeException
- insufficient permissionsAttributeNotExistsException
- when the attribute definition for attrId doesn't existAttributeNotMarkedUniqueException
- when the attribute definition is not unique
-
convertAttributeToUnique
public void convertAttributeToUnique(PerunSession session, int attrId) throws PrivilegeException, AttributeNotExistsException, AttributeAlreadyMarkedUniqueException Description copied from interface:AttributesManager
Converts attribute to unique. Marks the attribute definition as unique, and copies all values to a special table with unique constraint that ensures that all values remain unique. Values of type ArrayList and LinkedHashMap are splitted into multiple values, thus each of the subvalues must be unique.Entityless attributes cannot be converted to unique, only attributes attached to PerunBeans or pairs of PerunBeans.
- Specified by:
convertAttributeToUnique
in interfaceAttributesManager
- Parameters:
session
- perun sessionattrId
- attribute id- Throws:
PrivilegeException
AttributeNotExistsException
AttributeAlreadyMarkedUniqueException
-
createAttribute
public AttributeDefinition createAttribute(PerunSession sess, AttributeDefinition attribute) throws PrivilegeException, AttributeDefinitionExistsException Description copied from interface:AttributesManager
Creates an attribute, the attribute is stored into the appropriate DB table according to the namespacePRIVILEGE: Only PerunAdmin can create new attribute.
- Specified by:
createAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionattribute
- attribute to create- Returns:
- attribute with set id
- Throws:
PrivilegeException
- if privileges are not givenAttributeDefinitionExistsException
- if attribute already exists
-
deleteAttribute
public void deleteAttribute(PerunSession sess, AttributeDefinition attribute) throws PrivilegeException, AttributeNotExistsException, RelationExistsException Description copied from interface:AttributesManager
Deletes the attribute.PRIVILEGE: Only PerunAdmin can delete existing attribute.
- Specified by:
deleteAttribute
in interfaceAttributesManager
- Throws:
PrivilegeException
- if privileges are not givenRelationExistsException
- if attribute definition has any relation to some application form item or to some service as a required attributeAttributeNotExistsException
-
deleteAttribute
public void deleteAttribute(PerunSession sess, AttributeDefinition attributeDefinition, boolean force) throws PrivilegeException, AttributeNotExistsException Description copied from interface:AttributesManager
Deletes the attribute.PRIVILEGE: Only PerunAdmin can delete existing attribute.
- Specified by:
deleteAttribute
in interfaceAttributesManager
attributeDefinition
- attribute to deleteforce
- delete also all existing relation. If this parameter is true the RelationExistsException is never thrown.- Throws:
PrivilegeException
AttributeNotExistsException
-
doTheMagic
public void doTheMagic(PerunSession sess, Member member) throws PrivilegeException, WrongAttributeValueException, WrongReferenceAttributeValueException, MemberNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Only for PerunAdmin.Same as doTheMagic(sess, member, false);
- Specified by:
doTheMagic
in interfaceAttributesManager
- Throws:
PrivilegeException
WrongAttributeValueException
WrongReferenceAttributeValueException
MemberNotExistsException
-
doTheMagic
public void doTheMagic(PerunSession sess, Member member, boolean trueMagic) throws PrivilegeException, WrongAttributeValueException, WrongReferenceAttributeValueException, MemberNotExistsException Description copied from interface:AttributesManager
This function takes all member-related attributes (member, user, member-resource, user-facility) and tries to fill them and set them. If trueMagic is set, this method can remove invalid attribute value (value which didn't pass checkAttributeSemantics test) and try to fill and set another. In this case, WrongReferenceAttributeValueException, WrongAttributeValueException are thrown if same attribute can't be set correctly.PRIVILEGE: Only for PerunAdmin.
- Specified by:
doTheMagic
in interfaceAttributesManager
- Throws:
PrivilegeException
WrongAttributeValueException
WrongReferenceAttributeValueException
MemberNotExistsException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Resource resource, Attribute attribute) throws PrivilegeException, ResourceNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
This method tries to fill a value of the resource attribute. Value may be copied from some facility attribute.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource, attribute of which you want to fillattribute
- attribute to fill. If attributes already have set value, this value won't be overwritten. This means the attribute value must be empty otherwise this method won't fill it.- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in underlying data sourceWrongAttributeAssignmentException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Member member, Resource resource, Attribute attribute) throws PrivilegeException, ResourceNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, MemberResourceMismatchException Description copied from interface:AttributesManager
This method tries to fill value of the member-resource attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- member which attribute you want to fillresource
- resource which attribute you want to fillattribute
- attribute to fill. If attribute already have set value, this value won't be overwritten. This means the attribute value must be empty otherwise this method won't fill it.- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in underlying data sourceMemberNotExistsException
- if member doesn't exists in underlying data source or he doesn't have access to this resourceWrongAttributeAssignmentException
MemberResourceMismatchException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Member member, Group group, Attribute attribute) throws PrivilegeException, MemberNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, MemberGroupMismatchException Description copied from interface:AttributesManager
This method tries to fill value of the member-group attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- attribute of this member (and resource) you want to fillgroup
- attribute of this group you want to fillattribute
- attribute to fill. If attributes already have set value, this value won't be overwritten. This means the attribute value must be empty otherwise this method won't fill it.- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenMemberNotExistsException
- if member doesn't exists in underlying data source or he doesn't have access to this resourceGroupNotExistsException
- if group doesn't existsWrongAttributeAssignmentException
MemberGroupMismatchException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Member member, Attribute attribute) throws PrivilegeException, MemberNotExistsException, AttributeNotExistsException Description copied from interface:AttributesManager
This method tries to fill value of the member attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- attribute of this member (and resource) and you want to fillattribute
- attribute to fill. If attributes already have set value, this value won't be overwritten. This means the attribute value must be empty otherwise this method won't fill it.- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenMemberNotExistsException
- if member doesn't exists in underlying data source or he doesn't have access to this resourceAttributeNotExistsException
- if the attribute doesn't exists in underlying data source
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Facility facility, User user, Attribute attribute) throws PrivilegeException, FacilityNotExistsException, UserNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
This method tries to fill value of the user-facility attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- attribute of this facility (and user) and you want to filluser
- attribute of this user (and facility) and you want to fillattribute
- attribute to fill. If attributes already have set value, this value won't be overwritten. This means the attribute value must be empty otherwise this method won't fill it.- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exists in underlying data sourceUserNotExistsException
- if user doesn't exists in underlying data source or he doesn't have access to this facilityAttributeNotExistsException
- if the attribute doesn't exists in underlying data sourceWrongAttributeAssignmentException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, User user, Attribute attribute) throws PrivilegeException, UserNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
This method tries to fill value of the user attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionuser
- attribute of this user (and facility) and you want to fillattribute
- attribute to fill. If attributes already have set value, this value won't be overwritten. This means the attribute value must be empty otherwise this method won't fill it.- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenUserNotExistsException
- if user doesn't exists in underlying data source or he doesn't have access to this facilityAttributeNotExistsException
- if the attribute doesn't exists in underlying data sourceWrongAttributeAssignmentException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Resource resource, Group group, Attribute attribute) throws PrivilegeException, ResourceNotExistsException, GroupNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, GroupResourceMismatchException Description copied from interface:AttributesManager
This method tries to fill group-resource attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource which attr you want to fillgroup
- group which attr you want to fillattribute
- attribute to be filled- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeAssignmentException
- if attribute isn't group-resource attributeResourceNotExistsException
GroupNotExistsException
AttributeNotExistsException
GroupResourceMismatchException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Host host, Attribute attribute) throws PrivilegeException, HostNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
This method tries to fill host attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionhost
- host for which you want have attribute filledattribute
- attr which you want to fill- Returns:
- attribute which MAY have filled value
- Throws:
PrivilegeException
- if privileges are not givenWrongAttributeAssignmentException
- if attribute isn't group-resource attributeHostNotExistsException
AttributeNotExistsException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, Group group, Attribute attribute) throws PrivilegeException, GroupNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
This method tries to fill group attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
group
- group which attribute you want to fillattribute
- attribute which you want to fill- Returns:
- attribute which may have filled value
- Throws:
PrivilegeException
GroupNotExistsException
AttributeNotExistsException
WrongAttributeAssignmentException
-
fillAttribute
public Attribute fillAttribute(PerunSession sess, UserExtSource ues, Attribute attribute) throws PrivilegeException, UserExtSourceNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
This method tries to fill value of the user external source attribute. This value is automatically generated, but not all attributes can be filled this way.PRIVILEGE: Fill attribute only when principal has access to write on it.
- Specified by:
fillAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionues
- user external source which will be filled with attributeattribute
- attribute to fill. If attributes already have set value, this value won't be overwritten. This means the attribute value must be empty otherwise this method won't fill it.- Returns:
- attribute which may have filled value
- Throws:
PrivilegeException
- if privileges are not givenUserExtSourceNotExistsException
- if user external source doesn't exists in underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in underlying data sourceWrongAttributeAssignmentException
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Resource resource, List<Attribute> attributes) throws ResourceNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute. This method skips all attributes with not-null value.
- Specified by:
fillAttributes
in interfaceAttributesManager
- Throws:
ResourceNotExistsException
WrongAttributeAssignmentException
- See Also:
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Member member, Resource resource, List<Attribute> attributes) throws ResourceNotExistsException, MemberNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, MemberResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute. This method skips all attributes with not-null value.
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Member member, Resource resource, List<Attribute> attributes, boolean workWithUserAttributes) throws ResourceNotExistsException, MemberNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, MemberResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.- Specified by:
fillAttributes
in interfaceAttributesManager
workWithUserAttributes
- method can process also user and user-facility attributes (user is automatically get from member a facility is get from resource) !!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!- Throws:
ResourceNotExistsException
MemberNotExistsException
AttributeNotExistsException
WrongAttributeAssignmentException
MemberResourceMismatchException
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Member member, Group group, List<Attribute> attributes) throws MemberNotExistsException, GroupNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, MemberGroupMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute. This method skips all attributes with not-null value.
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Member member, Group group, List<Attribute> attributes, boolean workWithUserAttributes) throws MemberNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, GroupNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.- Specified by:
fillAttributes
in interfaceAttributesManager
workWithUserAttributes
- method can process also user and member attributes (user is automatically get from member) !!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!- Throws:
MemberNotExistsException
AttributeNotExistsException
WrongAttributeAssignmentException
GroupNotExistsException
MemberGroupMismatchException
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Facility facility, Resource resource, User user, Member member, List<Attribute> attributes) throws ResourceNotExistsException, MemberNotExistsException, FacilityNotExistsException, UserNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, MemberResourceMismatchException Description copied from interface:AttributesManager
This method tries to fill value of the user, member, member-resource and user-facility attributes. This value is automatically generated, but not all attributes can be filled this way. This method skips all attributes with not-null value.PRIVILEGE: Fill attributes only when principal has access to write on them.
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Member member, List<Attribute> attributes) throws MemberNotExistsException, AttributeNotExistsException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute. This method skips all attributes with not-null value.
- Specified by:
fillAttributes
in interfaceAttributesManager
- Throws:
MemberNotExistsException
AttributeNotExistsException
- See Also:
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Facility facility, User user, List<Attribute> attributes) throws FacilityNotExistsException, UserNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute. This method skips all attributes with not-null value.
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, User user, List<Attribute> attributes) throws UserNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute. This method skips all attributes with not-null value.
- Specified by:
fillAttributes
in interfaceAttributesManager
- Throws:
UserNotExistsException
AttributeNotExistsException
WrongAttributeAssignmentException
- See Also:
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Resource resource, Group group, List<Attribute> attributes) throws ResourceNotExistsException, GroupNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, GroupResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.batch version of fillAttribute, this method skips attributes with non-null value
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Host host, List<Attribute> attributes) throws HostNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute
- Specified by:
fillAttributes
in interfaceAttributesManager
- Throws:
HostNotExistsException
AttributeNotExistsException
WrongAttributeAssignmentException
- See Also:
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Group group, List<Attribute> attributes) throws GroupNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute
- Specified by:
fillAttributes
in interfaceAttributesManager
- Throws:
GroupNotExistsException
AttributeNotExistsException
WrongAttributeAssignmentException
- See Also:
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, UserExtSource ues, List<Attribute> attributes) throws UserExtSourceNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
PRIVILEGE: Fill attributes only when principal has access to write on them.Batch version of fillAttribute.
- Specified by:
fillAttributes
in interfaceAttributesManager
- Throws:
UserExtSourceNotExistsException
AttributeNotExistsException
WrongAttributeAssignmentException
- See Also:
-
fillAttributes
public List<Attribute> fillAttributes(PerunSession sess, Resource resource, Group group, List<Attribute> attributes, boolean workWithGroupAttributes) throws ResourceNotExistsException, GroupNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException, GroupResourceMismatchException -
getAllAttributesStartWithNameWithoutNullValue
public List<Attribute> getAllAttributesStartWithNameWithoutNullValue(PerunSession sess, Group group, String startPartOfName) throws GroupNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the group starts with name startPartOfName. Get only nonvirtual attributes with notNull value.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAllAttributesStartWithNameWithoutNullValue
in interfaceAttributesManager
- Parameters:
sess
- perun sessiongroup
- to get the attributes fromstartPartOfName
- attribute name start with this part- Returns:
- list of attributes which name start with startPartOfName
- Throws:
GroupNotExistsException
- if the group doesn't exist
-
getAllAttributesStartWithNameWithoutNullValue
public List<Attribute> getAllAttributesStartWithNameWithoutNullValue(PerunSession sess, Resource resource, String startPartOfName) throws ResourceNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the resource starts with name startPartOfName. Get only nonvirtual attributes with notNull value.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAllAttributesStartWithNameWithoutNullValue
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- to get the attributes fromstartPartOfName
- attribute name start with this part- Returns:
- list of attributes which name start with startPartOfName
- Throws:
ResourceNotExistsException
- if the resource doesn't exist
-
getAllNamespaces
Description copied from interface:AttributesManager
Returns list of all possible namespaces.- Specified by:
getAllNamespaces
in interfaceAttributesManager
- Parameters:
sess
- session- Returns:
- list of namespaces
- Throws:
PrivilegeException
- insufficient permissions
-
getAttribute
public Attribute getAttribute(PerunSession sess, Facility facility, String attributeName) throws PrivilegeException, FacilityNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the facility.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute is not facility attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, Vo vo, String attributeName) throws PrivilegeException, VoNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the vo.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionvo
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenVoNotExistsException
- if the vo doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute is not vo attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, Group group, String attributeName) throws PrivilegeException, GroupNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the group.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessiongroup
- group get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenGroupNotExistsException
- if the group doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute is not group attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, Resource resource, String attributeName) throws PrivilegeException, ResourceNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the resource.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute is not resource attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, Member member, Resource resource, String attributeName) throws PrivilegeException, ResourceNotExistsException, AttributeNotExistsException, MemberNotExistsException, MemberResourceMismatchException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the member on this resource.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get attribute fromresource
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceMemberNotExistsException
- if the member doesn't exists in the underlying data sourceMemberResourceMismatchException
- if member and resource are not in the same VOWrongAttributeAssignmentException
- if attribute is not member_resource attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, Member member, Group group, String attributeName) throws PrivilegeException, GroupNotExistsException, AttributeNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get particular attribute for the member in this group.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get attribute fromgroup
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenGroupNotExistsException
- if the resource doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceMemberNotExistsException
- if the member doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute is not member_group attributeMemberGroupMismatchException
-
getAttribute
public Attribute getAttribute(PerunSession sess, Member member, String attributeName) throws PrivilegeException, AttributeNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the member.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceMemberNotExistsException
- if the member doesn't exists in the underlying data sourceWrongAttributeAssignmentException
WrongAttributeAssignmentException
-
getAttribute
public Attribute getAttribute(PerunSession sess, Facility facility, User user, String attributeName) throws PrivilegeException, FacilityNotExistsException, AttributeNotExistsException, UserNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the user on this facility.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- to get attribute fromuser
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceUserNotExistsException
- if the user doesn't exists in the underlying data sourceWrongAttributeAssignmentException
-
getAttribute
public Attribute getAttribute(PerunSession sess, User user, String attributeName) throws PrivilegeException, AttributeNotExistsException, UserNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the user.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionuser
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceUserNotExistsException
- if the user doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute is not user attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, Host host, String attributeName) throws PrivilegeException, AttributeNotExistsException, HostNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the hostPRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionhost
- to get attribute fromattributeName
- attribute name defined in host manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceHostNotExistsException
- if the host doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't host attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, Resource resource, Group group, String attributeName) throws PrivilegeException, AttributeNotExistsException, ResourceNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, GroupResourceMismatchException Description copied from interface:AttributesManager
Get particular group attribute on resourcePRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource to get attributes fromgroup
- group to get attributes forattributeName
- attribute name- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't group-resource attributeResourceNotExistsException
GroupNotExistsException
GroupResourceMismatchException
-
getAttribute
public Attribute getAttribute(PerunSession sess, String key, String attributeName) throws AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular entityless attributePRIVILEGE: Only PerunAdmin can access to entitylessAttributes.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionkey
- key to get attribute forattributeName
- attribute name- Returns:
- attribute
- Throws:
AttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't entityless attribute
-
getAttribute
public Attribute getAttribute(PerunSession sess, UserExtSource ues, String attributeName) throws PrivilegeException, AttributeNotExistsException, UserExtSourceNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the user external source.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttribute
in interfaceAttributesManager
- Parameters:
sess
- perun sessionues
- to get attribute fromattributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceUserExtSourceNotExistsException
- if the user external source doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't ues attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Facility facility, int id) throws PrivilegeException, FacilityNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the facility.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
facility
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't facility attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Vo vo, int id) throws PrivilegeException, VoNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the vo.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
vo
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenVoNotExistsException
- if the vo doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't facility attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Resource resource, int id) throws PrivilegeException, ResourceNotExistsException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the resource.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
resource
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't resource attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Member member, Resource resource, int id) throws PrivilegeException, ResourceNotExistsException, AttributeNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, MemberResourceMismatchException Description copied from interface:AttributesManager
Get particular attribute for the member on this resource.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
member
- to get attribute fromresource
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenResourceNotExistsException
- if the resource doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceMemberNotExistsException
- if the member doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't resource-member attributeMemberResourceMismatchException
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Member member, Group group, int id) throws PrivilegeException, GroupNotExistsException, AttributeNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get particular attribute for the member in this group.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get attribute fromgroup
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenGroupNotExistsException
- if the resource doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceMemberNotExistsException
- if the member doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't member-group attributeMemberGroupMismatchException
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Member member, int id) throws PrivilegeException, AttributeNotExistsException, MemberNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the member.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
member
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceMemberNotExistsException
- if the member doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't member attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Facility facility, User user, int id) throws PrivilegeException, FacilityNotExistsException, AttributeNotExistsException, UserNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the user on this facility.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
facility
- to get attribute fromuser
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenFacilityNotExistsException
- if the facility doesn't exists in the underlying data sourceAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceUserNotExistsException
- if the user doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't user-facility attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, User user, int id) throws PrivilegeException, AttributeNotExistsException, UserNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the user.PRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
user
- to get attribute fromid
- attribute id- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceUserNotExistsException
- if the user doesn't exists in the underlying data sourceWrongAttributeAssignmentException
- if attribute isn't user attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Host host, int id) throws PrivilegeException, AttributeNotExistsException, HostNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for the hostPRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceHostNotExistsException
- if the host doesn't exist in the underlying data sourceWrongAttributeAssignmentException
- if the attribute isn't host attribute
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Resource resource, Group group, int id) throws PrivilegeException, AttributeNotExistsException, ResourceNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException, GroupResourceMismatchException Description copied from interface:AttributesManager
Get particular group attribute on this resourcePRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceResourceNotExistsException
GroupNotExistsException
WrongAttributeAssignmentException
GroupResourceMismatchException
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, Group group, int id) throws PrivilegeException, AttributeNotExistsException, GroupNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for groupPRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceGroupNotExistsException
WrongAttributeAssignmentException
-
getAttributeById
public Attribute getAttributeById(PerunSession sess, UserExtSource ues, int id) throws PrivilegeException, AttributeNotExistsException, UserExtSourceNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get particular attribute for user external sourcePRIVILEGE: Principal need to have access to attribute which wants to get.
- Specified by:
getAttributeById
in interfaceAttributesManager
- Throws:
PrivilegeException
- if privileges are not givenAttributeNotExistsException
- if the attribute doesn't exists in the underlying data sourceUserExtSourceNotExistsException
WrongAttributeAssignmentException
-
getAttributeDefinition
public AttributeDefinition getAttributeDefinition(PerunSession sess, String attributeName) throws AttributeNotExistsException Description copied from interface:AttributesManager
Get attribute definition (attribute without defined value).PRIVILEGE: No access needed.
- Specified by:
getAttributeDefinition
in interfaceAttributesManager
attributeName
- attribute name defined in the particular manager- Returns:
- attribute
- Throws:
AttributeNotExistsException
- if the attribute doesn't exists in the underlying data source
-
getAttributeDefinitionById
public AttributeDefinition getAttributeDefinitionById(PerunSession sess, int id) throws AttributeNotExistsException Description copied from interface:AttributesManager
Get attribute definition (attribute without defined value).PRIVILEGE: No access needed.
- Specified by:
getAttributeDefinitionById
in interfaceAttributesManager
id
- attribute id- Returns:
- attribute
- Throws:
AttributeNotExistsException
- if the attribute doesn't exists in the underlying data source
-
getAttributePolicyCollections
public List<AttributePolicyCollection> getAttributePolicyCollections(PerunSession sess, int attributeId) throws PrivilegeException, AttributeNotExistsException Description copied from interface:AttributesManager
Gets attribute policy collections for an attribute definition with given id.- Specified by:
getAttributePolicyCollections
in interfaceAttributesManager
- Parameters:
sess
- perun sessionattributeId
- id of the attribute definition- Returns:
- all policy collections of the attribute definition
- Throws:
AttributeNotExistsException
- when there is no attribute definition with such idPrivilegeException
-
getAttributeRights
@Deprecated public List<AttributeRights> getAttributeRights(PerunSession sess, int attributeId) throws PrivilegeException, AttributeNotExistsException Deprecated.Description copied from interface:AttributesManager
Gets attribute rights of an attribute with id given as a parameter. If the attribute has no rights for a role, it returns empty list. That means the returned list has always 4 items for each of the roles VOADMIN, FACILITYADMIN, GROUPADMIN, SELF. Info: not return rights for role VoObserver (could be same like read rights for VoAdmin)- Specified by:
getAttributeRights
in interfaceAttributesManager
- Parameters:
sess
- perun sessionattributeId
- id of the attribute- Returns:
- all rights of the attribute
- Throws:
PrivilegeException
AttributeNotExistsException
-
getAttributeRules
public AttributeRules getAttributeRules(PerunSession sess, int attributeId) throws PrivilegeException, AttributeNotExistsException Description copied from interface:AttributesManager
Gets attribute rules containing policy collections and critical actions for an attribute definition with given id- Specified by:
getAttributeRules
in interfaceAttributesManager
- Parameters:
sess
- perun sessionattributeId
- id of the attribute definition- Returns:
- attribute rules of the attribute definition
- Throws:
AttributeNotExistsException
- when there is no attribute definition with such idPrivilegeException
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Facility facility) throws FacilityNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the facility. PRIVILEGE: Get only those attributes the principal has access to.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- facility to get the attributes from- Returns:
- list of attributes
- Throws:
FacilityNotExistsException
- if the facility doesn't exists in underlying data source
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Facility facility, List<String> attrNames) throws FacilityNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the facility which have name in list attrNames (empty too). Virtual attribute too.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
FacilityNotExistsException
- if the facility not exists in Perun
-
getAttributes
Description copied from interface:AttributesManager
Get all non-empty attributes associated with the vo. PRIVILEGE: Get only those attributes the principal has access to.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionvo
- vo to get the attributes from- Returns:
- list of attributes
- Throws:
VoNotExistsException
- if the vo doesn't exists in underlying data source
-
getAttributes
Description copied from interface:AttributesManager
Get all non-empty attributes associated with the group. PRIVILEGE: Get only those attributes the principal has access to.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessiongroup
- group to get the attributes from- Returns:
- list of attributes
- Throws:
GroupNotExistsException
- if the group doesn't exists in underlying data source
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Resource resource) throws ResourceNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the resource. PRIVILEGE: Get only those attributes the principal has access to.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource to get the attributes from- Returns:
- list of attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data source
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, Resource resource) throws MemberResourceMismatchException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the member on the resource. PRIVILEGE: Get only those attributes the principal has access to.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromresource
- to get the attributes from- Returns:
- list of attributes
- Throws:
MemberResourceMismatchException
- if member and resource are not in the same VO
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, Resource resource, boolean workWithUserAttributes) throws ResourceNotExistsException, MemberNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Gets all non-empty attributes associated with the member on the resource and if workWithUserAttributes is true, gets also all non-empty user, user-facility and member attributes. PRIVILEGE: Get only those attributes the principal has access to.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromresource
- to get the attributes fromworkWithUserAttributes
- if true returns also user-facility, user and member attributes (user is automatically get from member and facility is get from resource)- Returns:
- list of attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resourceMemberResourceMismatchException
- if member and resource are not in the same VO!!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, Resource resource, List<String> attrNames, boolean workWithUserAttributes) throws ResourceNotExistsException, MemberNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Gets selected non-empty attributes associated with the member and the resource. It returns member and member-resource attributes and also user and user-facility attributes if workWithUserAttributes is true. Attributes are selected by list of attr_names. Empty list means all attributes.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromresource
- to get the attributes fromattrNames
- list of attributes to getworkWithUserAttributes
- if true returns also user and user-facility attributes (user is automatically get from member a facility is get from resource)- Returns:
- list of selected attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resourceMemberResourceMismatchException
- if member and resource are not in the same VO
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, Group group) throws GroupNotExistsException, MemberNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the member in the group. PRIVILEGE: Get only those attributes the principal has access to.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromgroup
- group to get the attributes from- Returns:
- list of attributes
- Throws:
GroupNotExistsException
- if the group doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resourceMemberGroupMismatchException
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, Group group, List<String> attrNames) throws GroupNotExistsException, MemberNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get all attributes (empty and virtual too)associated with the member in the group which have name in list attrNames.- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromgroup
- group to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
GroupNotExistsException
- if the group doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resourceMemberGroupMismatchException
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, Group group, List<String> attrNames, boolean workWithUserAttributes) throws GroupNotExistsException, MemberNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get all attributes associated with the member in the group which have name in list attrNames (empty too). If workWithUserAttribute is true, return also all user attributes in list of attrNames (with virtual attributes too).- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromgroup
- group to get the attributes fromattrNames
- list of attributes' namesworkWithUserAttributes
- if true returns also user and member attributes (user is automatically get from member)- Returns:
- list of attributes
- Throws:
GroupNotExistsException
- if the group doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resourceMemberGroupMismatchException
-
getAttributes
Description copied from interface:AttributesManager
Get all entityless attributes with subject equaled String keyPRIVILEGE: Only PerunAdmin can get Entityless attributes.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionkey
- string of subject of entityless attributes- Returns:
- list of attributes
- Throws:
PrivilegeException
- if privileges are not given
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Facility facility, Resource resource, User user, Member member) throws ResourceNotExistsException, MemberNotExistsException, FacilityNotExistsException, UserNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Get all non-empty member, user, member-resource and user-facility attributes.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Throws:
ResourceNotExistsException
MemberNotExistsException
FacilityNotExistsException
UserNotExistsException
MemberResourceMismatchException
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member) throws MemberNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the member.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes from- Returns:
- list of attributes
- Throws:
MemberNotExistsException
- if the member doesn't have access to this resource
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Resource resource, Group group, Member member, List<String> attrNames) throws ResourceNotExistsException, GroupNotExistsException, MemberNotExistsException, GroupResourceMismatchException, MemberResourceMismatchException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get all attributes by the list of attrNames if they are in one of these namespaces: - member - group - member-group - resource - member-resource - group-resource - user (get from member object) - facility (get from resource object) - user-facilityReturn all attributes even if they are empty or virtual.
PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't existGroupNotExistsException
- if the group doesn't existMemberNotExistsException
- if the member doesn't existGroupResourceMismatchException
- if group and resource are not from the same voMemberResourceMismatchException
- if member and resource are not from the same voMemberGroupMismatchException
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Resource resource, Group group, boolean workWithGroupAttributes) throws ResourceNotExistsException, GroupNotExistsException, GroupResourceMismatchException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the group and resource. Virtual attribute too.PRIVILEGE: Get only those attributes the principal has access to.
If workWithGroupAttributes is true, return also all group attributes in list of attrNames (with virtual attributes too).
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- to get the attributes fromgroup
- to get the attributes fromworkWithGroupAttributes
- if group attributes need to be return too- Returns:
- list of attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't existGroupNotExistsException
- if the group doesn't existGroupResourceMismatchException
- if group and resource are not from the same vo
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Resource resource, Group group, List<String> attrNames, boolean workWithGroupAttributes) throws ResourceNotExistsException, GroupNotExistsException, GroupResourceMismatchException Description copied from interface:AttributesManager
Get all attributes associated with the group and the resource which have their name in list attrNames (empty too). Virtual attribute too.PRIVILEGE: Get only those attributes the principal has access to.
If workWithGroupAttributes is true, return also all group attributes in list of attrNames (with virtual attributes too).
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- to get the attributes fromgroup
- to get the attributes fromattrNames
- list of attributes' namesworkWithGroupAttributes
- if group attributes need to be return too- Returns:
- list of attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't existGroupNotExistsException
- if the group doesn't existGroupResourceMismatchException
- if group and resource are not from the same vo
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, List<String> attrNames) throws MemberNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the member which have name in list attrNames (empty too). Virtual attribute too.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
MemberNotExistsException
- if the member doesn't have access to this resource
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Group group, List<String> attrNames) throws GroupNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the group which have name in list attrNames (empty too). Virtual attribute too.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessiongroup
- to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
GroupNotExistsException
- if the group doesn't have access to this resource
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Resource resource, List<String> attrNames) throws ResourceNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the resource which have name in list attrNames (empty too). Virtual attribute too.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
ResourceNotExistsException
- if the resource not exists in Perun
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, List<String> attrNames, boolean workWithUserAttributes) throws MemberNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the member which have name in list attrNames (empty too) Virtual attributes too.If workWithUserAttribute is true, return also all user attributes in list of attrNames (with virtual attributes too).
PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromattrNames
- list of attributes' namesworkWithUserAttributes
- if user attributes need to be returned too- Returns:
- list of member (and also if needed user) attributes
- Throws:
MemberNotExistsException
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Vo vo, List<String> attrNames) throws VoNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the vo which have name in list attrNames (empty too).PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionvo
- to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
VoNotExistsException
- if the vo doesn't have access to this resource
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, User user, List<String> attrNames) throws UserNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the user which have name in list attrNames (empty too).PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionuser
- to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
UserNotExistsException
- if the user doesn't exists
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, UserExtSource ues, List<String> attrNames) throws UserExtSourceNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the userExtSource which have name in list attrNames (empty too).PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionues
- to get the attributes fromattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
UserExtSourceNotExistsException
- if the UserExtSource doesn't have access to this resource
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Facility facility, User user) throws FacilityNotExistsException, UserNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the user on the facility.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- to get the attributes fromuser
- to get the attributes from- Returns:
- list of attributes
- Throws:
FacilityNotExistsException
- if the facility doesn't exists in underlying data sourceUserNotExistsException
- if the user doesn't have access to this facility
-
getAttributes
Description copied from interface:AttributesManager
Get all non-empty attributes associated with the user.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionuser
- to get the attributes from- Returns:
- list of attributes
- Throws:
UserNotExistsException
- if the user doesn't have access to this facility
-
getAttributes
Description copied from interface:AttributesManager
Get all non-empty attributes associated with the hostPRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionhost
- host to get attributes from- Returns:
- list of attributes
- Throws:
HostNotExistsException
- if the host doesn't exist in underlying data source
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Host host, List<String> attrNames) throws HostNotExistsException Description copied from interface:AttributesManager
Get all attributes associated with the host which have name in list attrNames (empty too). Empty list attrNames will return no attributes.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionhost
- host to get attributes forattrNames
- list of attributes' names- Returns:
- list of attributes
- Throws:
HostNotExistsException
- if the host doesn't exist in underlying data source
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Resource resource, Group group) throws ResourceNotExistsException, GroupNotExistsException, GroupResourceMismatchException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the group on resourcePRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Returns:
- list of group_resource attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't exist in underlying data sourceGroupNotExistsException
- if the group doesn't exist in the underlying data sourceGroupResourceMismatchException
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, Member member, boolean workWithUserAttributes) throws MemberNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the member and if workWithUserAttributes is true, get all non-empty attributes associated with user, who is this member.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- to get the attributes fromworkWithUserAttributes
- if true returns also user attributes- Returns:
- list of attributes
- Throws:
MemberNotExistsException
- if the member doesn't have access to this resource
-
getAttributes
public List<Attribute> getAttributes(PerunSession sess, UserExtSource ues) throws UserExtSourceNotExistsException Description copied from interface:AttributesManager
Get all non-empty attributes associated with the UserExtSource.PRIVILEGE: Get only those attributes the principal has access to.
- Specified by:
getAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionues
- to get the attributes from- Returns:
- list of attributes
- Throws:
UserExtSourceNotExistsException
- if the user external source doesn't exists
-
getAttributesByAttributeDefinition
public List<Attribute> getAttributesByAttributeDefinition(PerunSession sess, AttributeDefinition attributeDefinition) throws AttributeNotExistsException, WrongAttributeAssignmentException, PrivilegeException Description copied from interface:AttributesManager
Returns all attributes with not-null value which fits the attributeDefinition. Can't proscess core or virtual attributes.PRIVILEGE: Only PerunAdmin has access to get Attributes by AttributeDefinition
- Specified by:
getAttributesByAttributeDefinition
in interfaceAttributesManager
- Throws:
AttributeNotExistsException
WrongAttributeAssignmentException
PrivilegeException
-
getAttributesDefinition
public List<AttributeDefinition> getAttributesDefinition(PerunSession sess, List<String> listOfAttributesNames) throws AttributeNotExistsException Description copied from interface:AttributesManager
From listOfAttributesNames get list of attributeDefinitionsPRIVILEGE: No access needed.
- Specified by:
getAttributesDefinition
in interfaceAttributesManager
- Returns:
- list of AttributeDefinitions
- Throws:
AttributeNotExistsException
-
getAttributesDefinition
Description copied from interface:AttributesManager
Get all attributes definition (attribute without defined value).PRIVILEGE: No access needed.
- Specified by:
getAttributesDefinition
in interfaceAttributesManager
- Returns:
- List of attributes definitions
-
getAttributesDefinitionByNamespace
public List<AttributeDefinition> getAttributesDefinitionByNamespace(PerunSession sess, String namespace) Description copied from interface:AttributesManager
Get attributes definition (attribute without defined value) with specified namespace.PRIVILEGE: No access needed.
- Specified by:
getAttributesDefinitionByNamespace
in interfaceAttributesManager
namespace
- get only attributes with this namespace- Returns:
- List of attributes
-
getAttributesDefinitionWithRights
public List<AttributeDefinition> getAttributesDefinitionWithRights(PerunSession sess, List<PerunBean> entities) Description copied from interface:AttributesManager
Get all (for entities) attributeDefinitions which user has right to READ them and fill attribute writable (if user has also right to WRITE them). For entities means that return only those attributeDefinition which are in namespace of entities or possible combination of entities. For Example: If entities are "member, user, resource" then return only AD in namespaces "member, user, resource and resource-member"- Specified by:
getAttributesDefinitionWithRights
in interfaceAttributesManager
entities
- list of perunBeans (member, user...)- Returns:
- list of AttributeDefinitions with rights (writable will be filled correctly by user in session)
-
getAttributesManagerBl
Gets the attributesManagerBl for this instance.- Returns:
- The getAttributesManagerBl().
-
getEntitylessAttributes
public List<Attribute> getEntitylessAttributes(PerunSession sess, String attrName) throws PrivilegeException Description copied from interface:AttributesManager
Get all entityless attributes with attributeNamePRIVILEGE: Only PerunAdmin has access to entityless attributes.
- Specified by:
getEntitylessAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionattrName
- attribute name- Returns:
- attribute
- Throws:
PrivilegeException
- if privileges are not given
-
getEntitylessAttributesWithKeys
public Map<String,Attribute> getEntitylessAttributesWithKeys(PerunSession sess, String attrName) throws PrivilegeException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get entityless attributes mapped by their keys.- Specified by:
getEntitylessAttributesWithKeys
in interfaceAttributesManager
- Parameters:
sess
- sessionattrName
- attribute name- Returns:
- Map of entityless attributes mapped by their keys
- Throws:
PrivilegeException
- insufficient permissionsAttributeNotExistsException
- when the attribute definition for attrName doesn't existWrongAttributeAssignmentException
- when passed non-entityless attribute
-
getEntitylessAttributesWithKeys
public Map<String,Attribute> getEntitylessAttributesWithKeys(PerunSession sess, String attrName, List<String> keys) throws PrivilegeException, AttributeNotExistsException, WrongAttributeAssignmentException Description copied from interface:AttributesManager
Get entityless attributes mapped by their keys. Returns only attributes for specified keys.- Specified by:
getEntitylessAttributesWithKeys
in interfaceAttributesManager
- Parameters:
sess
- sessionattrName
- attribute name- Returns:
- Map of entityless attributes mapped by their keys
- Throws:
PrivilegeException
- insufficient permissionsAttributeNotExistsException
- when the attribute definition for attrName doesn't exist, or when there is no such attribute for one of the specified keysWrongAttributeAssignmentException
- when passed non-entityless attribute
-
getEntitylessKeys
public List<String> getEntitylessKeys(PerunSession sess, AttributeDefinition attributeDefinition) throws PrivilegeException Description copied from interface:AttributesManager
Returns list of Keys which fits the attributeDefinition.PRIVILEGE: Only PerunAdmin has access to entityless keys.
- Specified by:
getEntitylessKeys
in interfaceAttributesManager
- Throws:
PrivilegeException
- if privileges are not given
-
getFriendlyNameFromAttributeName
Description copied from interface:AttributesManager
Gets the friendly name from the attribute name.PRIVILEGE: No access needed.
- Specified by:
getFriendlyNameFromAttributeName
in interfaceAttributesManager
- Returns:
- the friendly name from the attribute name
-
getIdpAttributeDefinitions
Description copied from interface:AttributesManager
Returns list of definitions of IdP attributes that are filled to fedInfo- Specified by:
getIdpAttributeDefinitions
in interfaceAttributesManager
- Parameters:
sess
- session- Returns:
- list of attribute definitions
-
getLogins
Description copied from interface:AttributesManager
Get all attributes with user's logins.PRIVILEGE: Get only those logins principal has access to.
- Specified by:
getLogins
in interfaceAttributesManager
- Returns:
- list of attributes with login
- Throws:
UserNotExistsException
-
getModulesDependenciesGraph
public GraphDTO getModulesDependenciesGraph(PerunSession session, GraphTextFormat format) throws PrivilegeException Description copied from interface:AttributesManager
Generates graph describing attribute modules dependencies. Text output format can be specified byGraphTextFormat
format.- Specified by:
getModulesDependenciesGraph
in interfaceAttributesManager
- Parameters:
session
- sessionformat
- text output format- Returns:
- body of text file containing description of modules dependencies.
- Throws:
PrivilegeException
- insufficient permissions
-
getModulesDependenciesGraph
public GraphDTO getModulesDependenciesGraph(PerunSession session, GraphTextFormat format, String attributeName) throws PrivilegeException, AttributeNotExistsException Description copied from interface:AttributesManager
Generates graph describing dependencies for given AttributeDefinition. Text output format can be specified byGraphTextFormat
format.- Specified by:
getModulesDependenciesGraph
in interfaceAttributesManager
- Parameters:
session
- sessionformat
- text output formatattributeName
- attribute definition which dependencies will be used- Returns:
- body of text file containing description of modules dependencies.
- Throws:
PrivilegeException
- insufficient permissionsAttributeNotExistsException
-
getNamespaceFromAttributeName
Description copied from interface:AttributesManager
Gets the namespace from the attribute name.PRIVILEGE: No access needed.
- Specified by:
getNamespaceFromAttributeName
in interfaceAttributesManager
- Returns:
- the namespace from the attribute name
-
getPerunBl
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Facility facility) throws FacilityNotExistsException Description copied from interface:AttributesManager
Get facility attributes which are required by all services which are related to this facility.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- you get attributes for this facility- Returns:
- list of facility attributes which are required by services
- Throws:
FacilityNotExistsException
- if the facility wasn't created from this resource
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Resource resource) throws ResourceNotExistsException Description copied from interface:AttributesManager
Get resource attributes which are required by services which is relatod to this resource.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource for which you want to get the attributes- Returns:
- list of resource attributes which are required by services which are assigned to resource.
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data source
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Member member, Resource resource) throws ResourceNotExistsException, MemberNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Get member-resource attributes which are required by services which are relater to this member-resource.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- you get attributes for this member and the resourceresource
- you get attributes for this resource and the member- Returns:
- list of member-resource attributes which are required by services which are assigned to resource.
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resourceMemberResourceMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Member member, Resource resource, boolean workWithUserAttributes) throws ResourceNotExistsException, MemberNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
If workWithUserAttribute is false => Get member-resource attributes which are required by services which are relater to this member-resource. If workWithUserAttributes is true => Get member-resource, user-facility, user and member attributes. (user is get from member and facility from resource)PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- you get attributes for this member and the resourceresource
- you get attributes for this resource and the memberworkWithUserAttributes
- method can process also user, user-facility and member attributes (user is automatically get from member a facility is get from resource)- Returns:
- list of member-resource attributes or if workWithUserAttributes is true return list of member-resource, user, member and user-facility attributes
- Throws:
ResourceNotExistsException
MemberNotExistsException
MemberResourceMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Facility facility, User user) throws FacilityNotExistsException, UserNotExistsException Description copied from interface:AttributesManager
Get user-facility attributes which are required by services which are related to this user-facility.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionfacility
- facility from which the services are takenuser
- you get attributes for this user- Returns:
- list of user-facility attributes which are required by services which are assigned to facility.
- Throws:
FacilityNotExistsException
UserNotExistsException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Member member, boolean workWithUserAttributes) throws MemberNotExistsException Description copied from interface:AttributesManager
Get member attributes which are required by services which are relater to this member.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- you get attributes for this memberworkWithUserAttributes
- method can process also user and user-facility attributes (user is automatically get from member a facility is get from resource)- Returns:
- list of member and user attributes which are required by services which are related to this member
- Throws:
MemberNotExistsException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Member member, Group group, boolean workWithUserAttributes) throws MemberNotExistsException, GroupNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get member, member-group attributes which are required by services which are relater to this member. If workWithUserAttributes = true, then user attributes are returned too.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionmember
- you get attributes for this membergroup
- you get attributes for this groupworkWithUserAttributes
- if TRUE, return also user attributes- Returns:
- list of member, member-group and optionally user attributes which are required by services which are related to this member
- Throws:
MemberNotExistsException
GroupNotExistsException
MemberGroupMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, User user) throws UserNotExistsException Description copied from interface:AttributesManager
Get user attributes which are required by services which are relater to this user.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun session- Returns:
- list of user's attributes which are required by services which are related to this user
- Throws:
UserNotExistsException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Facility facility) throws FacilityNotExistsException, ServiceNotExistsException Description copied from interface:AttributesManager
Get facility attributes which are required by the service.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this servis you'll getfacility
- you get attributes for this facility- Returns:
- list of facility attributes which are required by the service
- Throws:
FacilityNotExistsException
- if the facility wasn't created from this resourceServiceNotExistsException
- if the service doesn't exists in underlying data source
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Vo vo) throws VoNotExistsException, ServiceNotExistsException Description copied from interface:AttributesManager
Get vo attributes which are required by the service.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this service you'll getvo
- you get attributes for this vo- Returns:
- list of vo attributes which are required by the service
- Throws:
VoNotExistsException
- if the vo wasn't created from this resourceServiceNotExistsException
- if the service doesn't exists in underlying data source
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, List<Service> services, Facility facility) throws FacilityNotExistsException, ServiceNotExistsException Description copied from interface:AttributesManager
Get facility attributes which are required by the services.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservices
- attributes required by this services you'll getfacility
- you get attributes for this facility- Returns:
- list of facility attributes which are required by the service
- Throws:
FacilityNotExistsException
- if the facility wasn't created from this resourceServiceNotExistsException
- if the service doesn't exists in underlying data source
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Resource resource) throws ResourceNotExistsException, ServiceNotExistsException Description copied from interface:AttributesManager
Get resource attributes which are required by the service.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attributes required by this service you'll getresource
- resource for which you want to get the attributes- Returns:
- list of resource attributes which are required by the service
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data sourceServiceNotExistsException
- if the service doesn't exists in underlying data source
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, List<Service> services, Resource resource) throws ResourceNotExistsException, ServiceNotExistsException Description copied from interface:AttributesManager
Get resource attributes which are required by the services.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservices
- attributes required by this services you'll getresource
- you get attributes for this resource- Returns:
- list of facility attributes which are required by the service
- Throws:
ResourceNotExistsException
- if the resource doesn't existsServiceNotExistsException
- if the service doesn't exists in underlying data source
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Member member, Resource resource) throws ResourceNotExistsException, ServiceNotExistsException, MemberNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Get member-resource attributes which are required by the service.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attributes required by this services you'll getmember
- you get attributes for this member and the resourceresource
- you get attributes for this resource and the member- Returns:
- list of attributes which are required by the service.
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data sourceServiceNotExistsException
- if the service doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't exists in underlying data sourceMemberResourceMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Member member, Resource resource, boolean workWithUserAttributes) throws ResourceNotExistsException, ServiceNotExistsException, MemberNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Get only those required attributes principal has access to.!!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Throws:
ResourceNotExistsException
ServiceNotExistsException
MemberNotExistsException
MemberResourceMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Resource resource, Group group, Member member, boolean workWithUserAttributes) throws ResourceNotExistsException, ServiceNotExistsException, MemberNotExistsException, GroupNotExistsException, GroupResourceMismatchException, MemberResourceMismatchException Description copied from interface:AttributesManager
Get member, member-resource and member-group attributes required by the specified service. if workWithUserAttributes == TRUE return also user and user-facility attributesPRIVILEGE: Get only those required attributes principal has access to.
!!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!
Group and group-resource attributes are not supported in this context !!
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- you'll get attributes required by this serviceresource
- you get attributes for this resource and the member and groupgroup
- you get attributes for this group and resource and membermember
- you get attributes for this member and the resource and groupworkWithUserAttributes
- if TRUE return also user and user-facility attributes- Returns:
- list of attributes which are required by the service.
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data sourceServiceNotExistsException
- if the service doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't exists in underlying data sourceGroupNotExistsException
- if the group doesn't exists in underlying data sourceGroupResourceMismatchException
MemberResourceMismatchException
-
getRequiredAttributes
public HashMap<Member,List<Attribute>> getRequiredAttributes(PerunSession sess, Service service, Resource resource, List<Member> members, boolean workWithUserAttributes) throws ServiceNotExistsException, ResourceNotExistsException, MemberNotExistsException, MemberResourceMismatchException Description copied from interface:AttributesManager
Get member-resource, member, user-facility and user attributes which are required by service for each member in list of members. If workWithUserAttributes is false return only member-resource attributes.- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this serviceresource
- you get attributes for this resourcemembers
- you get attributes for this list of membersworkWithUserAttributes
- if true method can process also user, user-facility and member attributes- Returns:
- map of member objects and his list of attributes
- Throws:
ServiceNotExistsException
ResourceNotExistsException
MemberNotExistsException
MemberResourceMismatchException
-
getRequiredAttributes
public HashMap<Member,List<Attribute>> getRequiredAttributes(PerunSession sess, Service service, Resource resource, List<Member> members) throws ResourceNotExistsException, ServiceNotExistsException, MemberNotExistsException Description copied from interface:AttributesManager
Get member-resource attributes which are required by service for each member in list of members.- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this serviceresource
- you get attributes for this resource and the membersmembers
- you get attributes for this list of members and the resource- Returns:
- map of memberID and his list of attributes
- Throws:
ResourceNotExistsException
- if the resource doesn't exists in underlying data sourceServiceNotExistsException
- if the service doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resource
-
getRequiredAttributes
public HashMap<Member,List<Attribute>> getRequiredAttributes(PerunSession sess, Resource resource, Service service, List<Member> members) throws ServiceNotExistsException, ResourceNotExistsException, MemberNotExistsException Description copied from interface:AttributesManager
Get member attributes which are required by service for each member in list of members.- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionresource
- resource only to get allowed membersservice
- attribute required by this servicemembers
- you get attributes for this list of members- Returns:
- map of memberID and his list of attributes
- Throws:
ServiceNotExistsException
- if the service doesn't exists in underlying data sourceResourceNotExistsException
- if the resource doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't have access to this resource
-
getRequiredAttributes
public HashMap<User,List<Attribute>> getRequiredAttributes(PerunSession sess, Service service, Facility facility, List<User> users) throws ServiceNotExistsException, FacilityNotExistsException, UserNotExistsException Description copied from interface:AttributesManager
Get user-facility attributes which are required by the service for each user in list of users.- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this servicefacility
- you get attributes for this facility and userusers
- you get attributes for this user and facility- Returns:
- map of user and his list of attributes
- Throws:
ServiceNotExistsException
- if the service doesn't exists in underlying data sourceFacilityNotExistsException
- if the facility wasn't created from this resourceUserNotExistsException
- if the host doesn't exists in the underlying data source
-
getRequiredAttributes
public HashMap<User,List<Attribute>> getRequiredAttributes(PerunSession sess, Service service, List<User> users) throws ServiceNotExistsException, UserNotExistsException Description copied from interface:AttributesManager
Get user attributes which are required by the service for each user in list of users.- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this serviceusers
- you get attributes for this user and facility- Returns:
- map of user and his list of attributes
- Throws:
ServiceNotExistsException
- if the service doesn't exists in underlying data sourceUserNotExistsException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Member member, Group group) throws ServiceNotExistsException, MemberNotExistsException, GroupNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
Get member-group attributes which are required by the service.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this service you'll getmember
- you get attributes for this member and the resourcegroup
- you get attributes for this group in which member is associated- Returns:
- list of attributes which are required by the service.
- Throws:
ServiceNotExistsException
- if the service doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't exists in underlying data sourceGroupNotExistsException
MemberGroupMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Member member, Group group, boolean workWithUserAttributes) throws ServiceNotExistsException, MemberNotExistsException, GroupNotExistsException, MemberGroupMismatchException Description copied from interface:AttributesManager
PRIVILEGE: Get only those required attributes principal has access to.!!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Throws:
ServiceNotExistsException
MemberNotExistsException
GroupNotExistsException
MemberGroupMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Member member) throws ServiceNotExistsException, MemberNotExistsException Description copied from interface:AttributesManager
Get member attributes which are required by the service.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- attribute required by this servis you'll getmember
- you get attributes for this member and the resource- Returns:
- list of attributes which are required by the service.
- Throws:
ServiceNotExistsException
- if the service doesn't exists in underlying data sourceMemberNotExistsException
- if the member doesn't exists in underlying data source
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Resource resource, Group group, boolean workWithGroupAttributes) throws ServiceNotExistsException, ResourceNotExistsException, GroupNotExistsException, GroupResourceMismatchException Description copied from interface:AttributesManager
Get group-resource attributes required for the service. !!WARNING THIS IS VERY TIME-CONSUMING METHOD. DON'T USE IT IN BATCH!!PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Parameters:
sess
- perun sessionservice
- you will get attributes required by this serviceworkWithGroupAttributes
- get also group attributes (which is required by the service) for this group- Throws:
ServiceNotExistsException
- if the service doesn't exists in underlying data sourceResourceNotExistsException
GroupNotExistsException
GroupResourceMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Resource resource, Group group) throws ServiceNotExistsException, ResourceNotExistsException, GroupNotExistsException, GroupResourceMismatchException Description copied from interface:AttributesManager
Get group-resource attributes required for the service.PRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Throws:
ServiceNotExistsException
ResourceNotExistsException
GroupNotExistsException
GroupResourceMismatchException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Host host) throws ServiceNotExistsException, HostNotExistsException Description copied from interface:AttributesManager
Get host required attributes for the servicePRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Throws:
ServiceNotExistsException
HostNotExistsException
-
getRequiredAttributes
public List<Attribute> getRequiredAttributes(PerunSession sess, Service service, Group group) throws ServiceNotExistsException, GroupNotExistsException Description copied from interface:AttributesManager
Get group required attributes for the servicePRIVILEGE: Get only those required attributes principal has access to.
- Specified by:
getRequiredAttributes
in interfaceAttributesManager
- Throws:
ServiceNotExistsException
GroupNotExistsException
-
getRequiredAttributesDefinition
public List<AttributeDefinition> getRequiredAttributesDefinition(PerunSession sess, Service service) throws ServiceNotExistsException Description copied from interface:AttributesManager
Get all attributes which are required by service. Required attribues are requisite for Service to run.PRIVILEGE: No access needed.
- Specified by:
getRequiredAttributesDefinition
in interfaceAttributesManager
- Parameters:
sess
- sessservice
- service from which the attributes will be listed- Returns:
- All attributes which are required by service.
- Throws:
ServiceNotExistsException
- if the service doesn't exists in underlying data source
-