if (type instanceof SimplePolicyType) {
value = createSimplePolicyValue(policyValue, (SimplePolicyType) type);
} else if (type instanceof CompositePolicyType) {
if (type instanceof OrderedSetPolicyType) {
OrderedSetPolicyType orderedSetType =
(OrderedSetPolicyType) type;
value = new DefaultOrderedSetPolicyValue(
orderedSetType.getMemberPolicyType(), policyValue);
} else if (type instanceof UnorderedSetPolicyType) {
UnorderedSetPolicyType unorderedSetType =
(UnorderedSetPolicyType) type;
value = new DefaultUnorderedSetPolicyValue(
unorderedSetType.getMemberPolicyType(), policyValue);