Package org.oasisOpen.docs.wsn.x2004.x06.wsnWSBaseNotification12Draft01

Examples of org.oasisOpen.docs.wsn.x2004.x06.wsnWSBaseNotification12Draft01.SubscribeResponseDocument$Factory


        instance.setTimeInMillis(instance.getTimeInMillis() + 20000);
        subscribe.setInitialTerminationTime( instance );
        org.xmlsoap.schemas.ws.x2003.x03.addressing.EndpointReferenceType consumerRef = subscribe.addNewConsumerReference();
        org.xmlsoap.schemas.ws.x2003.x03.addressing.AttributedURI address = consumerRef.addNewAddress();
        address.setStringValue( consumerURL );
        TopicExpressionType topicExpr = subscribe.addNewTopicExpression();
        topicExpr.setDialect( TopicsConstants.TOPIC_EXPR_DIALECT_SIMPLE );
        XmlBeanUtils.setValueAsQName( topicExpr, topic );
        XmlObject response = sendRequest( requestDoc, "http://xyz.com/action/Subscribe" );
        if ( ! ( response instanceof SubscribeResponseDocument.SubscribeResponse ) )
        {
            throw new FaultException( response.toString() );
View Full Code Here


        instance.setTimeInMillis(instance.getTimeInMillis() + 2000000);
        subscribe.setInitialTerminationTime(instance);
        org.xmlsoap.schemas.ws.x2003.x03.addressing.EndpointReferenceType consumerRef = subscribe.addNewConsumerReference();
        org.xmlsoap.schemas.ws.x2003.x03.addressing.AttributedURI address = consumerRef.addNewAddress();
        address.setStringValue(createEpr(consumerURL).getAddress());
        TopicExpressionType topicExpr = subscribe.addNewTopicExpression();
        topicExpr.setDialect(TopicsConstants.TOPIC_EXPR_DIALECT_SIMPLE);
        XmlBeanUtils.setValueAsQName(topicExpr, topic);
        XmlObject response = sendRequest(requestDoc, "http://xyz.com/action/Subscribe", createEpr(serviceEPRURL));
        if (!(response instanceof SubscribeResponseDocument.SubscribeResponse))
        {
            return false;
View Full Code Here

         TopicExpressionDocument topicExprDoc = TopicExpressionDocument.Factory.newInstance(  );
         topicExprDoc.addNewTopicExpression(  );
         prop.add( topicExprDoc );
      }

      TopicExpressionType topicExpr        = (TopicExpressionType) prop.get( 0 );
      TopicsTypeWriter    topicsTypeWriter = TopicsTypeWriter.newInstance( TopicsConstants.NSURI_WSTOP_SCHEMA );
      TopicExpressionType newTopicExpr     =
         (TopicExpressionType) topicsTypeWriter.toXmlObject( m_subscription.getTopicExpression(  ),
                                                             SubscriptionManagerPortType.PROP_QNAME_TOPIC_EXPRESSION );
      topicExpr.set( newTopicExpr );
      return prop;
   }
View Full Code Here

    * @throws CallbackFailedException DOCUMENT_ME
    */
   public void updateProperty( Object[] propElems )
   throws CallbackFailedException
   {
      TopicExpressionType topicExpr        = (TopicExpressionType) propElems[0];
      TopicsTypeReader    topicsTypeReader = TopicsTypeReader.newInstance( TopicsConstants.NSURI_WSTOP_SCHEMA );
      try
      {
         m_subscription.setTopicExpression( topicsTypeReader.toTopicExpression( topicExpr ) );
      }
View Full Code Here

        instance.setTimeInMillis(instance.getTimeInMillis() + 2000000);
        subscribe.setInitialTerminationTime(instance);
        org.xmlsoap.schemas.ws.x2003.x03.addressing.EndpointReferenceType consumerRef = subscribe.addNewConsumerReference();
        org.xmlsoap.schemas.ws.x2003.x03.addressing.AttributedURI address = consumerRef.addNewAddress();
        address.setStringValue(createEpr(consumerURL).getAddress());
        TopicExpressionType topicExpr = subscribe.addNewTopicExpression();
        topicExpr.setDialect(TopicsConstants.TOPIC_EXPR_DIALECT_SIMPLE.toString());
        XmlBeanUtils.setValueAsQName(topicExpr, topic);
        XmlObject response = sendRequest(requestDoc, "http://xyz.com/action/Subscribe", createEpr(serviceEPRURL));
        if (!(response instanceof SubscribeResponseDocument.SubscribeResponse))
        {
            return false;
View Full Code Here

      NotificationMessageHolderType notifMsgHolder = notify.addNewNotificationMessage(  );
      notifMsgHolder.setMessage( msgXBean );
      EndpointReference         producerEPR       = m_producerResource.getEndpointReference(  );
      XmlBeansEndpointReference xBeansProducerEPR = ( (XmlBeansEndpointReference) producerEPR );
      notifMsgHolder.setProducerReference( (EndpointReferenceType) xBeansProducerEPR.getXmlObject( org.apache.ws.addressing.v2003_03.AddressingConstants.NSURI_ADDRESSING_SCHEMA ) );
      TopicExpressionType topicExprType =
         (TopicExpressionType) TopicsTypeWriter.newInstance( TopicsConstants.NSURI_WSTOP_SCHEMA ).toXmlObject( topicExpr,
                                                                                                               NotificationProducerPortType.PROP_QNAME_TOPIC );
      notifMsgHolder.setTopic( topicExprType );
      return notifyDoc;
   }
View Full Code Here

    * @throws IllegalStateException DOCUMENT_ME
    */
   public TopicExpression toTopicExpression( XmlObject xBean )
   throws InvalidTopicExpressionException
   {
      TopicExpressionType topicExprType = toTopicExpressionType( xBean );
      if ( !topicExprType.isSetDialect(  ) )
      {
         throw new IllegalStateException( "The Dialect attribute is required by the WS-BaseNotification TopicExpressionType." );
      }

      String          dialect   = topicExprType.getDialect(  );
      TopicExpression topicExpr;
      if ( dialect.equals( TopicsConstants.TOPIC_EXPR_DIALECT_SIMPLE ) )
      {
         topicExpr = new SimpleTopicExpression( XmlBeanUtils.getValueAsQName( topicExprType ) );
      }
View Full Code Here

      TopicExpressionDocument topicExprDoc = TopicExpressionDocument.Factory.newInstance(  );
      topicExprDoc.setTopicExpression( (TopicExpressionType) ( (XmlBeansTopicExpression) m_topicExpression )
                                       .getXmlObject(  ) );
      prop.add( topicExprDoc );
      prop = m_propSet.get( SubscriptionManagerPortType.PROP_QNAME_USE_NOTIFY );
      UseNotifyDocument useNotifyDoc = UseNotifyDocument.Factory.newInstance(  );
      useNotifyDoc.setUseNotify( m_useNotify );
      prop.add( useNotifyDoc );
      if ( m_precondition != null )
      {
         prop = m_propSet.get( SubscriptionManagerPortType.PROP_QNAME_PRECONDITION );
         PreconditionDocument preconditionDoc = PreconditionDocument.Factory.newInstance(  );
View Full Code Here

        prop = m_propSet.get(SubscriptionManagerPortType.PROP_QNAME_TOPIC_EXPRESSION);
        TopicExpressionDocument topicExprDoc = TopicExpressionDocument.Factory.newInstance();
        topicExprDoc.setTopicExpression((TopicExpressionType) ((XmlBeansTopicExpression) m_topicExpression).getXmlObject());
        prop.add(topicExprDoc);
        prop = m_propSet.get(SubscriptionManagerPortType.PROP_QNAME_USE_NOTIFY);
        UseNotifyDocument useNotifyDoc = UseNotifyDocument.Factory.newInstance();
        useNotifyDoc.setUseNotify(m_useNotify);
        prop.add(useNotifyDoc);
        if (m_precondition != null) {
            prop = m_propSet.get(SubscriptionManagerPortType.PROP_QNAME_PRECONDITION);
            PreconditionDocument preconditionDoc = PreconditionDocument.Factory.newInstance();
            preconditionDoc.setPrecondition((QueryExpressionType) ((XmlBeansQueryExpression) m_precondition).getXmlObject());
View Full Code Here

         throw new IllegalArgumentException( "Unsupported property: " + propName );
      }

      if ( prop.isEmpty(  ) )
      {
         UseNotifyDocument useNotifyDoc = UseNotifyDocument.Factory.newInstance(  );
         useNotifyDoc.setUseNotify( true );
         prop.add( useNotifyDoc );
      }

      XmlBoolean useNotify = (XmlBoolean) prop.get( 0 );
      useNotify.setBooleanValue( m_subscription.getUseNotify(  ) );
View Full Code Here

TOP

Related Classes of org.oasisOpen.docs.wsn.x2004.x06.wsnWSBaseNotification12Draft01.SubscribeResponseDocument$Factory

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.