import sailpoint.object.ManagedAttribute;
Boolean entitlementCheck(){
boolean existingEnt = false;
String appName = "SAP";
String entDN = "CN=abc, OU=Pedia, DC=com";
String cn = "Java";
String displayName = null;
Filter managedAttrFilter = Filter.eq("application.name", appName);
managedAttrFilter = Filter.and(managedAttrFilter, filter.eq("value", entDN));
ManagedAttribute managedAttribute = context.getUniueObject(ManagedAttribute.class, managedAttrFilter);
if(managedAttribute != null){
displayName = managedAttribute.getDisplayName();
if(displayName.equals(cn))
existingEnt= true;
}
return existingEnt;
}
No comments:
Post a Comment