Previous Topic: Configuring a Time Delay for Cleanup of Connections Marked as "Closed Pending" (30839, 30838)

Next Topic: UpdateAttributes Agent Call Recalculates Active Response Values (30912, 30213)

Using the getAgentTypeAttr Function to Obtain the Agent Type Name (30909, 30336)

The Agent Type Attribute Name can be obtained if the Agent Type Attribute OID is known by using the newly added getAgentTypeAttr() function in the Java Policy API.

The sample code for this would be:

SmResponseAttr responseAttr = (SmResponseAttr) responseAttrs.get(i);
String agentTypeAttrOid = responseAttr.getAgentTypeAttr();
System.out.println( "Agent Type Attribute OID = " +  agentTypeAttrOid);
SmAgentTypeAttr agentattr = new SmAgentTypeAttr();
result = policyApi.getAgentTypeAttr(agentTypeAttrOid.getOidString(),
agentattr);
System.out.println( "Agent Type Attribute Name = " +  agentattr.getName());