Package org.apache.ws.notification.base

Examples of org.apache.ws.notification.base.Subscription


      }

      // TODO: SubscriptionHome class is specific to WSN 2004/06 - should be replaced by a WSN-version-neutral SubscriptionHome interface
      SubscriptionHome subscriptionHome =
         (SubscriptionHome) SubscriptionManager.getInstance(  ).getSubscriptionManagerHome( m_producerResource );
      Subscription     subscription = null;
      try
      {
         subscription =
            subscriptionHome.create( m_producerResource.getEndpointReference(  ),
                                     consumerEPR,
                                     topicExpr );
         subscription.setTerminationTime( initialTerminationTime );
         subscription.setUseNotify( ( useNotify == null ) || useNotify.booleanValue(  ) );
         subscription.setSelector( selector );
         subscription.setPrecondition( precondition );
         subscription.setPolicy( policy );
         SubscriptionManager.getInstance(  ).addSubscription( subscription, topics );
      }
      catch ( Exception e )
      {
         LOG.error( "Subscribe failed due to internal error: " + e );
         if ( LOG.isDebugEnabled(  ) )
         {
            e.printStackTrace(  );
         }

         throw new SubscribeCreationFailedException( e );
      }

      return subscription.getEndpointReference(  );
   }
View Full Code Here

TOP

Related Classes of org.apache.ws.notification.base.Subscription

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.