Package org.apache.ws.notification.base.v2004_06.impl

Source Code of org.apache.ws.notification.base.v2004_06.impl.SubscriptionService

/*=============================================================================*
*  Copyright 2004 The Apache Software Foundation
*
*  Licensed under the Apache License, Version 2.0 (the "License");
*  you may not use this file except in compliance with the License.
*  You may obtain a copy of the License at
*
*      http://www.apache.org/licenses/LICENSE-2.0
*
*  Unless required by applicable law or agreed to in writing, software
*  distributed under the License is distributed on an "AS IS" BASIS,
*  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*  See the License for the specific language governing permissions and
*  limitations under the License.
*=============================================================================*/
package org.apache.ws.notification.base.v2004_06.impl;

import org.apache.ws.notification.base.v2004_06.porttype.SubscriptionManagerPortType;
import org.apache.ws.notification.base.v2004_06.porttype.impl.SubscriptionManagerPortTypeImpl;
import org.apache.ws.resource.ResourceContext;
import org.apache.ws.resource.handler.ServiceSoapMethodNameMap;
import org.apache.ws.resource.handler.SoapMethodNameMap;
import org.apache.ws.resource.handler.WsrfService;
import org.oasisOpen.docs.wsn.x2004.x06.wsnWSBaseNotification12Draft01.PauseSubscriptionDocument;
import org.oasisOpen.docs.wsn.x2004.x06.wsnWSBaseNotification12Draft01.PauseSubscriptionResponseDocument;
import org.oasisOpen.docs.wsn.x2004.x06.wsnWSBaseNotification12Draft01.ResumeSubscriptionDocument;
import org.oasisOpen.docs.wsn.x2004.x06.wsnWSBaseNotification12Draft01.ResumeSubscriptionResponseDocument;
import javax.xml.namespace.QName;

/**
* The builtin SubscriptionManager service.
*/
public class SubscriptionService
   implements WsrfService,
              SubscriptionManagerPortType,
              org.apache.ws.resource.lifetime.v2004_06.porttype.ScheduledResourceTerminationPortType,
              org.apache.ws.resource.properties.v2004_06.porttype.GetResourcePropertyPortType,
              org.apache.ws.resource.lifetime.v2004_06.porttype.ImmediateResourceTerminationPortType
{
   /** DOCUMENT_ME */
   public static final String TARGET_NSURI      =
      "http://ws.apache.org/notification/base/service/SubscriptionManager";

   /** DOCUMENT_ME */
   public static final String TARGET_NSPREFIX   = "SubscriptionManager";
   private ResourceContext    m_resourceContext;

   /**
    * DOCUMENT_ME
    */
   private ServiceSoapMethodNameMap m_methodNameMap;

   /**
    * DOCUMENT_ME
    */
   private boolean m_isInitialized;

   /**
    * Creates a new {@link SubscriptionService } object.
    *
    * @param resourceContext DOCUMENT_ME
    */
   public SubscriptionService( ResourceContext resourceContext )
   {
      m_resourceContext = resourceContext;
      init(  );
   }

   /**
    * DOCUMENT_ME
    *
    * @param request DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public org.xmlsoap.schemas.ws.x2004.x09.mex.MetadataDocument getMetadata( org.xmlsoap.schemas.ws.x2004.x09.mex.GetMetadataDocument request )
   {
      return new org.apache.ws.resource.metadataexchange.v2004_09.porttype.impl.MetadataExchangePortTypeImpl( getResourceContext(  ) )
             .getMetadata( request );
   }

   /**
    * DOCUMENT_ME
    *
    * @param requestQname DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public String getMethodName( QName requestQname )
   {
      return m_methodNameMap.getMethodName( requestQname );
   }

   /**
    * DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public final SoapMethodNameMap getMethodNameMap(  )
   {
      return m_methodNameMap;
   }

   /**
    * DOCUMENT_ME
    *
    * @param requestDoc DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetMultipleResourcePropertiesResponseDocument getMultipleResourceProperties( org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetMultipleResourcePropertiesDocument requestDoc )
   {
      return new org.apache.ws.resource.properties.v2004_06.porttype.impl.GetMultipleResourcePropertiesPortTypeImpl( getResourceContext(  ) )
             .getMultipleResourceProperties( requestDoc );
   }

   /**
    * DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public ResourceContext getResourceContext(  )
   {
      return m_resourceContext;
   }

   /**
    * DOCUMENT_ME
    *
    * @param requestDoc DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesResponseDocument setResourceProperties( org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.SetResourcePropertiesDocument requestDoc )
   {
      return new org.apache.ws.resource.properties.v2004_06.porttype.impl.SetResourcePropertiesPortTypeImpl( getResourceContext(  ) )
             .setResourceProperties( requestDoc );
   }

   /**
    * DOCUMENT_ME
    *
    * @param requestDoc DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetResourcePropertyResponseDocument getResourceProperty( org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceProperties12Draft01.GetResourcePropertyDocument requestDoc )
   {
      return new org.apache.ws.resource.properties.v2004_06.porttype.impl.GetResourcePropertyPortTypeImpl( getResourceContext(  ) )
             .getResourceProperty( requestDoc );
   }

   /**
    * DOCUMENT_ME
    *
    * @param requestDoc DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceLifetime12Draft01.SetTerminationTimeResponseDocument setTerminationTime( org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceLifetime12Draft01.SetTerminationTimeDocument requestDoc )
   {
      return new org.apache.ws.resource.lifetime.v2004_06.porttype.impl.ScheduledResourceTerminationPortTypeImpl( getResourceContext(  ) )
             .setTerminationTime( requestDoc );
   }

   /**
    * DOCUMENT_ME
    *
    * @param requestDoc DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceLifetime12Draft01.DestroyResponseDocument destroy( org.oasisOpen.docs.wsrf.x2004.x06.wsrfWSResourceLifetime12Draft01.DestroyDocument requestDoc )
   {
      return new org.apache.ws.resource.lifetime.v2004_06.porttype.impl.ImmediateResourceTerminationPortTypeImpl( getResourceContext(  ) )
             .destroy( requestDoc );
   }

   /**
    * DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   public org.xmlsoap.schemas.ws.x2004.x09.mex.AnyXmlType get(  )
   {
      return new org.apache.ws.resource.metadataexchange.v2004_09.porttype.impl.MetadataExchangePortTypeImpl( getResourceContext(  ) )
             .get(  );
   }

   /**
    * DOCUMENT_ME
    */
   public synchronized void init(  )
   {
      if ( !m_isInitialized )
      {
         m_methodNameMap    = new ServiceSoapMethodNameMap( getResourceContext(  ) );
         m_isInitialized    = true;
      }
   }

   /**
    * @param requestDoc
    *
    * @return
    */
   public PauseSubscriptionResponseDocument pauseSubscription( PauseSubscriptionDocument requestDoc )
   {
      return new SubscriptionManagerPortTypeImpl( getResourceContext(  ) ).pauseSubscription( requestDoc );
   }

   /**
    * @param requestDoc
    *
    * @return
    */
   public ResumeSubscriptionResponseDocument resumeSubscription( ResumeSubscriptionDocument requestDoc )
   {
      return new SubscriptionManagerPortTypeImpl( getResourceContext(  ) ).resumeSubscription( requestDoc );
   }

   /**
    * DOCUMENT_ME
    *
    * @return DOCUMENT_ME
    */
   protected final boolean isInitialized(  )
   {
      return m_isInitialized;
   }
}
TOP

Related Classes of org.apache.ws.notification.base.v2004_06.impl.SubscriptionService

TOP
Copyright © 2018 www.massapi.com. 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.