this.endpointReferenceElement = elem;
break;
}
}
} else {
throw new WSTrustException(WSTrustException.INVALID_REQUEST,
WSTrustException.DESC_EXPECTED_CHILD_ELEM,
new Object[]{
TrustConstants.WSA_PREFIX, TrustConstants.ADDRESS_LN,
TrustConstants.WSA_PREFIX, TrustConstants.ENDPOINT_REFERENCE_LN});
}
}
} else {
//If the Passed elemt is not a wsa:EndpointReference element
throw new WSTrustException(WSTrustException.INVALID_REQUEST,
WSTrustException.DESC_EXPECTED_CHILD_ELEM,
new Object[]{
TrustConstants.WSA_PREFIX, TrustConstants.ENDPOINT_REFERENCE_LN,
TOKEN.getPrefix(), TOKEN.getLocalPart()});
}