Package org.oasis_open.docs.wsn.b_2

Examples of org.oasis_open.docs.wsn.b_2.UnsubscribeResponse


    protected void unsubscribe() throws UnableToDestroySubscriptionFault {
        try {
            unregister();
        } catch (EndpointRegistrationException e) {
            UnableToDestroySubscriptionFaultType fault = new UnableToDestroySubscriptionFaultType();
            throw new UnableToDestroySubscriptionFault("Error unregistering endpoint", fault, e);
        }
    }
View Full Code Here


                    log.debug("Error closing session", inner);
                } finally {
                    jmsSession = null;
                }
            }
            UnableToGetMessagesFaultType fault = new UnableToGetMessagesFaultType();
            throw new UnableToGetMessagesFault("Unable to retrieve messages", fault, e);
        } catch (JAXBException e) {
            log.info("Error retrieving messages", e);
            UnableToGetMessagesFaultType fault = new UnableToGetMessagesFaultType();
            throw new UnableToGetMessagesFault("Unable to retrieve messages", fault, e);
        }
    }
View Full Code Here

    protected XMLGregorianCalendar validateInitialTerminationTime(String value)
        throws UnacceptableInitialTerminationTimeFault {
        XMLGregorianCalendar tt = parseTerminationTime(value);
        if (tt == null) {
            UnacceptableInitialTerminationTimeFaultType fault = new UnacceptableInitialTerminationTimeFaultType();
            throw new UnacceptableInitialTerminationTimeFault("Unable to parse initial termination time: '" + value
                    + "'", fault);
        }
        XMLGregorianCalendar ct = getCurrentTime();
        int c = tt.compare(ct);
        if (c == DatatypeConstants.LESSER || c == DatatypeConstants.EQUAL) {
            UnacceptableInitialTerminationTimeFaultType fault = new UnacceptableInitialTerminationTimeFaultType();
            fault.setMinimumTime(ct);
            throw new UnacceptableInitialTerminationTimeFault("Invalid initial termination time", fault);
        }
        return tt;
    }
View Full Code Here

            InvalidMessageContentExpressionFaultType fault = new InvalidMessageContentExpressionFaultType();
            throw new InvalidMessageContentExpressionFault("Unsupported MessageContent dialect: '"
                    + contentFilter.getDialect() + "'", fault);
        }
        if (terminationTime != null) {
            UnacceptableInitialTerminationTimeFaultType fault = new UnacceptableInitialTerminationTimeFaultType();
            throw new UnacceptableInitialTerminationTimeFault("InitialTerminationTime is not supported", fault);
        }
    }
View Full Code Here

    protected XMLGregorianCalendar validateInitialTerminationTime(String value)
        throws UnacceptableInitialTerminationTimeFault {
        XMLGregorianCalendar tt = parseTerminationTime(value);
        if (tt == null) {
            UnacceptableInitialTerminationTimeFaultType fault
                = new UnacceptableInitialTerminationTimeFaultType();
            throw new UnacceptableInitialTerminationTimeFault("Unable to parse initial termination time: '"
                + value + "'", fault);
        }
        XMLGregorianCalendar ct = getCurrentTime();
        int c = tt.compare(ct);
        if (c == DatatypeConstants.LESSER || c == DatatypeConstants.EQUAL) {
            UnacceptableInitialTerminationTimeFaultType fault
                = new UnacceptableInitialTerminationTimeFaultType();
            fault.setMinimumTime(ct);
            throw new UnacceptableInitialTerminationTimeFault("Invalid initial termination time", fault);
        }
        return tt;
    }
View Full Code Here

            InvalidMessageContentExpressionFaultType fault = new InvalidMessageContentExpressionFaultType();
            throw new InvalidMessageContentExpressionFault("Unsupported MessageContent dialect: '"
                    + contentFilter.getDialect() + "'", fault);
        }
        if (terminationTime != null) {
            UnacceptableInitialTerminationTimeFaultType fault
                = new UnacceptableInitialTerminationTimeFaultType();
            throw new UnacceptableInitialTerminationTimeFault("InitialTerminationTime is not supported",
                                                              fault);
        }
    }
View Full Code Here

    }

    protected XMLGregorianCalendar validateTerminationTime(String value) throws UnacceptableTerminationTimeFault {
        XMLGregorianCalendar tt = parseTerminationTime(value);
        if (tt == null) {
            UnacceptableTerminationTimeFaultType fault = new UnacceptableTerminationTimeFaultType();
            throw new UnacceptableTerminationTimeFault("Unable to parse termination time: '" + value + "'", fault);
        }
        XMLGregorianCalendar ct = getCurrentTime();
        int c = tt.compare(ct);
        if (c == DatatypeConstants.LESSER || c == DatatypeConstants.EQUAL) {
            UnacceptableTerminationTimeFaultType fault = new UnacceptableTerminationTimeFaultType();
            fault.setMinimumTime(ct);
            throw new UnacceptableTerminationTimeFault("Invalid termination time", fault);
        }
        return tt;
    }
View Full Code Here

        }
    }

    @Override
    protected void renew(XMLGregorianCalendar terminationTime) throws UnacceptableTerminationTimeFault {
        UnacceptableTerminationTimeFaultType fault = new UnacceptableTerminationTimeFaultType();
        throw new UnacceptableTerminationTimeFault("TerminationTime is not supported", fault);
    }
View Full Code Here

    public void resume() throws JBIException {
        request(new ResumeSubscription());
    }

    public void unsubscribe() throws JBIException {
        request(new Unsubscribe());
    }
View Full Code Here

                      targetNamespace = "http://docs.oasis-open.org/wsn/b-2",
                      partName = "UnsubscribeRequest")
            Unsubscribe unsubscribeRequest) throws ResourceUnknownFault, UnableToDestroySubscriptionFault {

        broker.unsubscribe(getAddress());
        return new UnsubscribeResponse();
    }
View Full Code Here

TOP

Related Classes of org.oasis_open.docs.wsn.b_2.UnsubscribeResponse

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.