* Creates a {@link ResourceType} with several attributes.
*
* @return
*/
private ResourceType createResource() {
ResourceType resourceType = new ResourceType();
AttributeType attResourceID = RequestAttributeFactory.createStringAttributeType(
"urn:oasis:names:tc:xacml:1.0:resource:resource-id", "xacml20.interop.com", "CustomerAccount");
resourceType.getAttribute().add(attResourceID);
AttributeType attOwnerID = RequestAttributeFactory.createStringAttributeType(
"urn:xacml:2.0:interop:example:resource:owner-id", "xacml20.interop.com", "123456");
resourceType.getAttribute().add(attOwnerID);
AttributeType attOwnerName = RequestAttributeFactory.createStringAttributeType(
"urn:xacml:2.0:interop:example:resource:owner-name", "xacml20.interop.com", "John Smith");
resourceType.getAttribute().add(attOwnerName);
AttributeType attAccountStatus = RequestAttributeFactory.createStringAttributeType(
"urn:xacml:2.0:interop:example:resource:account-status", "xacml20.interop.com", "Active");
resourceType.getAttribute().add(attAccountStatus);
AttributeType attCreditLine = RequestAttributeFactory.createIntegerAttributeType(
"urn:xacml:2.0:interop:example:resource:credit-line", "xacml20.interop.com", 15000);
resourceType.getAttribute().add(attCreditLine);
AttributeType attCurrentCredit = RequestAttributeFactory.createIntegerAttributeType(
"urn:xacml:2.0:interop:example:resource:current-credit", "xacml20.interop.com", 10000);
resourceType.getAttribute().add(attCurrentCredit);
AttributeType attTradeLimit = RequestAttributeFactory.createIntegerAttributeType(
"urn:xacml:2.0:interop:example:resource:trade-limit", "xacml20.interop.com", 10000);
resourceType.getAttribute().add(attTradeLimit);
return resourceType;
}