Source code: org/oasisOpen/docs/wsrf/x2005/x01/wsrfInterop20Draft03Wsdl/AbstractPrinterFactoryService.java
1 /*=============================================================================*
2 * Copyright 2004 The Apache Software Foundation
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *=============================================================================*/
16 package org.oasisOpen.docs.wsrf.x2005.x01.wsrfInterop20Draft03Wsdl;
17
18 import org.apache.ws.resource.ResourceContext;
19 import org.apache.ws.resource.handler.ServiceSoapMethodNameMap;
20 import org.apache.ws.resource.handler.SoapMethodNameMap;
21 import javax.xml.namespace.QName;
22
23 /**
24 * This class should be generated on every "generation" against the WSDL.
25 * This will ensure it is always up-to-date with the WSDL.
26 *
27 * NOTE: This class is generated and is NOT meant to be modified.
28 */
29 public abstract class AbstractPrinterFactoryService
30 implements org.apache.ws.resource.handler.WsrfService
31 {
32 /** DOCUMENT_ME */
33 public static final String TARGET_NSURI =
34 "http://docs.oasis-open.org/wsrf/2005/01/wsrf-Interop-2.0-draft-03.wsdl";
35
36 /** DOCUMENT_ME */
37 public static final String TARGET_NSPREFIX = "wsrf-Interop-2.0-draft-03.wsdl";
38
39 /**
40 * DOCUMENT_ME
41 */
42 private ServiceSoapMethodNameMap m_methodNameMap;
43
44 /**
45 * DOCUMENT_ME
46 */
47 private boolean m_isInitialized;
48
49 /**
50 * DOCUMENT_ME
51 *
52 * @param requestQname DOCUMENT_ME
53 *
54 * @return DOCUMENT_ME
55 */
56 public String getMethodName( QName requestQname )
57 {
58 if ( !m_isInitialized )
59 {
60 init( );
61 }
62
63 return m_methodNameMap.getMethodName( requestQname );
64 }
65
66 /**
67 * DOCUMENT_ME
68 *
69 * @return DOCUMENT_ME
70 */
71 public abstract ResourceContext getResourceContext( );
72
73 /**
74 * DOCUMENT_ME
75 *
76 * @return DOCUMENT_ME
77 */
78 public final SoapMethodNameMap getMethodNameMap( )
79 {
80 return m_methodNameMap;
81 }
82
83 /**
84 * DOCUMENT_ME
85 */
86 public void init( )
87 {
88 m_methodNameMap = new ServiceSoapMethodNameMap( getResourceContext( ) );
89 m_methodNameMap.addMapping( javax.xml.namespace.QName.valueOf( "{http://docs.oasis-open.org/wsrf/2005/01/wsrf-Interop-2.0-draft-03.xsd}CreatePrinterRequest" ),
90 "CreatePrinter" );
91 m_isInitialized = true;
92 }
93
94 /**
95 * DOCUMENT_ME
96 *
97 * @return DOCUMENT_ME
98 */
99 protected final boolean isInitialized( )
100 {
101 return m_isInitialized;
102 }
103 }