Java Code Examples for org.apache.cxf.ws.addressing.EndpointReferenceType#setMetadata()

The following examples show how to use org.apache.cxf.ws.addressing.EndpointReferenceType#setMetadata() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: WSAEndpointReferenceUtils.java    From cxf with Apache License 2.0 5 votes vote down vote up
public static MetadataType getSetMetadata(EndpointReferenceType ref) {
    MetadataType mt = ref.getMetadata();
    if (null == mt) {
        mt = WSA_OBJECT_FACTORY.createMetadataType();
        ref.setMetadata(mt);
    }
    return mt;
}
 
Example 2
Source File: WSAEndpointReferenceUtils.java    From cxf with Apache License 2.0 5 votes vote down vote up
/**
 * Create a duplicate endpoint reference sharing all atributes
 * @param ref the reference to duplicate
 * @return EndpointReferenceType - the duplicate endpoint reference
 */
public static EndpointReferenceType duplicate(EndpointReferenceType ref) {

    EndpointReferenceType reference = WSA_OBJECT_FACTORY.createEndpointReferenceType();
    reference.setMetadata(ref.getMetadata());
    reference.getAny().addAll(ref.getAny());
    reference.setAddress(ref.getAddress());
    return reference;
}
 
Example 3
Source File: WSAEndpointReferenceUtils.java    From cxf with Apache License 2.0 4 votes vote down vote up
public static EndpointReferenceType createEndpointReferenceWithMetadata() {
    EndpointReferenceType reference = WSA_OBJECT_FACTORY.createEndpointReferenceType();
    reference.setMetadata(WSA_OBJECT_FACTORY.createMetadataType());
    return reference;
}