Interface SecurityGroupInterface
-
- All Known Implementing Classes:
SecurityGroupManagement
public interface SecurityGroupInterface
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.String
createSecurityGroup(java.lang.String userId, SecurityGroupProperties properties)
Create a new security group.void
deleteSecurityGroup(java.lang.String userId, java.lang.String securityGroupGUID)
Delete a specific security group.java.util.List<SecurityGroupElement>
findSecurityGroups(java.lang.String userId, java.lang.String searchString, int startFrom, int pageSize)
Return the list of security groups that match the search string - this can be a regular expression.java.util.List<ElementStub>
getElementsGovernedBySecurityGroup(java.lang.String userId, java.lang.String securityGroupGUID, int startFrom, int pageSize)
Return the elements that are governed by the supplied security group.SecurityGroupElement
getSecurityGroupByGUID(java.lang.String userId, java.lang.String securityGroupGUID)
Retrieve the userIdentity metadata element with the supplied unique identifier.java.util.List<SecurityGroupElement>
getSecurityGroupsForDistinguishedName(java.lang.String userId, java.lang.String distinguishedName, int startFrom, int pageSize)
Return the list of security groups associated with a unique distinguishedName.void
updateSecurityGroup(java.lang.String userId, java.lang.String securityGroupGUID, boolean isMergeUpdate, SecurityGroupProperties properties)
Update an existing security group.
-
-
-
Method Detail
-
createSecurityGroup
java.lang.String createSecurityGroup(java.lang.String userId, SecurityGroupProperties properties) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Create a new security group. The type of the definition is located in the properties.- Parameters:
userId
- calling userproperties
- properties of the definition- Returns:
- unique identifier of the definition
- Throws:
InvalidParameterException
- typeName, documentIdentifier or userId is null; documentIdentifier is not unique; typeName is not validPropertyServerException
- problem accessing the metadata serviceUserNotAuthorizedException
- security access problem
-
updateSecurityGroup
void updateSecurityGroup(java.lang.String userId, java.lang.String securityGroupGUID, boolean isMergeUpdate, SecurityGroupProperties properties) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Update an existing security group.- Parameters:
userId
- calling usersecurityGroupGUID
- unique identifier of the definition to updateisMergeUpdate
- are unspecified properties unchanged (true) or removed?properties
- properties to update- Throws:
InvalidParameterException
- guid, documentIdentifier or userId is null; documentIdentifier is not unique; guid is not knownPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
deleteSecurityGroup
void deleteSecurityGroup(java.lang.String userId, java.lang.String securityGroupGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Delete a specific security group.- Parameters:
userId
- calling usersecurityGroupGUID
- unique identifier of the definition to remove- Throws:
InvalidParameterException
- guid is null or not knownPropertyServerException
- problem accessing property serverUserNotAuthorizedException
- security access problem
-
getSecurityGroupsForDistinguishedName
java.util.List<SecurityGroupElement> getSecurityGroupsForDistinguishedName(java.lang.String userId, java.lang.String distinguishedName, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the list of security groups associated with a unique distinguishedName. In an ideal world, there should be only one.- Parameters:
userId
- calling userdistinguishedName
- unique name of the security groupstartFrom
- where to start from in the list of definitionspageSize
- max number of results to return in one call- Returns:
- list of security groups
- Throws:
InvalidParameterException
- one of the parameters is invalidUserNotAuthorizedException
- the caller is not authorized to issue the requestPropertyServerException
- the metadata service has problems
-
getElementsGovernedBySecurityGroup
java.util.List<ElementStub> getElementsGovernedBySecurityGroup(java.lang.String userId, java.lang.String securityGroupGUID, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the elements that are governed by the supplied security group.- Parameters:
userId
- calling usersecurityGroupGUID
- unique name of the security groupstartFrom
- where to start from in the list of definitionspageSize
- max number of results to return in one call- Returns:
- list of headers for the associated elements
- Throws:
InvalidParameterException
- one of the parameters is invalidUserNotAuthorizedException
- the caller is not authorized to issue the requestPropertyServerException
- the metadata service has problems
-
findSecurityGroups
java.util.List<SecurityGroupElement> findSecurityGroups(java.lang.String userId, java.lang.String searchString, int startFrom, int pageSize) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Return the list of security groups that match the search string - this can be a regular expression.- Parameters:
userId
- calling usersearchString
- value to search forstartFrom
- where to start from in the list of definition resultspageSize
- max number of results to return in one call- Returns:
- list of security groups
- Throws:
InvalidParameterException
- one of the parameters is invalidUserNotAuthorizedException
- the caller is not authorized to issue the requestPropertyServerException
- the metadata service has problems
-
getSecurityGroupByGUID
SecurityGroupElement getSecurityGroupByGUID(java.lang.String userId, java.lang.String securityGroupGUID) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
Retrieve the userIdentity metadata element with the supplied unique identifier.- Parameters:
userId
- calling usersecurityGroupGUID
- unique identifier of the requested metadata element- Returns:
- matching metadata element
- Throws:
InvalidParameterException
- one of the parameters is invalidUserNotAuthorizedException
- the user is not authorized to issue this requestPropertyServerException
- there is a problem reported in the open metadata server(s)
-
-