Package org.xmlsoap.schemas.ws._2004._08.addressing

Examples of org.xmlsoap.schemas.ws._2004._08.addressing.EndpointReferenceType


            @WebParam(name = "SubscriptionPolicy", targetNamespace = "http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.xsd")
            Object subscriptionPolicy,
            @WebParam(name = "InitialTerminationTime", targetNamespace = "http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.xsd")
            XMLGregorianCalendar terminationTime) throws ResourceUnknownFault, SubscribeCreationFailedFault {
      EndpointReferenceType ref = new EndpointReferenceType();
      ServiceNameType sn = new ServiceNameType();
      sn.setPortName("myPort");
      ref.setServiceName(sn);
      return ref;
    }
View Full Code Here


    protected ServiceEndpoint findSubscriberEndpoint(ActiveMQSubscription subscribe) {
        EndpointReferenceType consumerReference = subscribe.getConsumerReference();
        if (consumerReference == null) {
            throw new NotificationException("No consumerReference specified for subscription: " + subscribe);
        }
        ServiceNameType serviceNameType = consumerReference.getServiceName();
        if (serviceNameType == null) {
            log.warn("No service name available for subscription: " + subscribe);
        }
        else {
            QName serviceName = serviceNameType.getValue();
            ServiceEndpoint[] endpoints = context.getEndpointsForService(serviceName);
            if (endpoints != null && endpoints.length > 0) {
                // lets just return the first
                return endpoints[0];
            }
View Full Code Here

    public void testCreateAndTerminateSequence() throws Exception {
        CreateSequenceType createArguments = new CreateSequenceType();

        EndpointReferenceType reference = new EndpointReferenceType();
        reference.setAddress(new AttributedURI());
        reference.getAddress().setValue("http://localhost/test/" + getClass().getName() + "/" + getName());
        createArguments.setAcksTo(reference);

        if (specifyExpires) {
            Expires expires = new Expires();
View Full Code Here

    protected boolean specifyExpires = false;

    public void testCreateAndTerminateSequence() throws Exception {
        CreateSequenceType createArguments = new CreateSequenceType();

        EndpointReferenceType reference = new EndpointReferenceType();
        reference.setAddress(new AttributedURI());
        reference.getAddress().setValue("http://localhost/test/" + getClass().getName() + "/" + getName());
        createArguments.setAcksTo(reference);

        if (specifyExpires) {
            Expires expires = new Expires();
            createArguments.setExpires(expires);
View Full Code Here

        if (specifyExpires) {
            Expires expires = new Expires();
            createArguments.setExpires(expires);
        }

        CreateSequenceResponseType response = sequenceManager.createSequence(createArguments);
        Identifier identifier = response.getIdentifier();
        String value = identifier.getValue();
        assertNotNull("Should have an identifier", value);
       
        System.out.println("Created identifier: " + value);
        System.out.println("Accept: " + response.getAccept());
       
        TerminateSequenceType terminateArgs = new TerminateSequenceType();
        terminateArgs.setIdentifier(identifier);
        sequenceManager.terminateSequence(terminateArgs);
    }
View Full Code Here

        if (createSequence.getExpires() != null) {
            s.expires = convertToLocalTime(createSequence.getExpires());
        }
        sequenceStore.create(s);

        CreateSequenceResponseType response = new CreateSequenceResponseType();
        response.setIdentifier(s.getIdentifier());
        if (s.expires != 0) {
            response.setExpires(convertToDuration(s.expires));
        }
        return response;
    }
View Full Code Here

public class SequenceManagerTest extends TestCase {
    protected SequenceAbsractPortType sequenceManager;
    protected boolean specifyExpires = false;

    public void testCreateAndTerminateSequence() throws Exception {
        CreateSequenceType createArguments = new CreateSequenceType();

        EndpointReferenceType reference = new EndpointReferenceType();
        reference.setAddress(new AttributedURI());
        reference.getAddress().setValue("http://localhost/test/" + getClass().getName() + "/" + getName());
        createArguments.setAcksTo(reference);

        if (specifyExpires) {
            Expires expires = new Expires();
            createArguments.setExpires(expires);
        }

        CreateSequenceResponseType response = sequenceManager.createSequence(createArguments);
        Identifier identifier = response.getIdentifier();
        String value = identifier.getValue();
View Full Code Here

        reference.setAddress(new AttributedURI());
        reference.getAddress().setValue("http://localhost/test/" + getClass().getName() + "/" + getName());
        createArguments.setAcksTo(reference);

        if (specifyExpires) {
            Expires expires = new Expires();
            createArguments.setExpires(expires);
        }

        CreateSequenceResponseType response = sequenceManager.createSequence(createArguments);
        Identifier identifier = response.getIdentifier();
View Full Code Here

            Expires expires = new Expires();
            createArguments.setExpires(expires);
        }

        CreateSequenceResponseType response = sequenceManager.createSequence(createArguments);
        Identifier identifier = response.getIdentifier();
        String value = identifier.getValue();
        assertNotNull("Should have an identifier", value);
       
        System.out.println("Created identifier: " + value);
        System.out.println("Accept: " + response.getAccept());
       
View Full Code Here

    private final IdGenerator idGenerator = new IdGenerator();
    private final ConcurrentHashMap sequences = new ConcurrentHashMap();
   
    public void create(Sequence s) {
        String id = idGenerator.generateId();
        Identifier identifier = new Identifier();
        identifier.setValue(id);
        s.setIdentifier(identifier);
        sequences.put(id,s);
    }
View Full Code Here

TOP

Related Classes of org.xmlsoap.schemas.ws._2004._08.addressing.EndpointReferenceType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.