KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > jonas_ws > wsgen > generator > WsClientGenerator


1 /**
2  * JOnAS: Java(TM) Open Application Server
3  * Copyright (C) 2003-2004 Bull S.A.
4  * Contact: jonas-team@objectweb.org
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
19  * USA
20  *
21  * --------------------------------------------------------------------------
22  * $Id: WsClientGenerator.java,v 1.3 2004/10/11 13:16:14 benoitf Exp $
23  * --------------------------------------------------------------------------
24  */

25
26 package org.objectweb.jonas_ws.wsgen.generator;
27
28 import org.objectweb.jonas_lib.genbase.GenBaseException;
29 import org.objectweb.jonas_lib.genbase.archive.Archive;
30 import org.objectweb.jonas_lib.genbase.generator.Config;
31
32 import org.objectweb.jonas_ws.deployment.api.ServiceRefDesc;
33 import org.objectweb.jonas_ws.wsgen.ddmodifier.WsClientDDModifier;
34
35 /**
36  * Generate sources and/or config for WebServices clients.
37  *
38  * @author Guillaume Sauthier
39  */

40 public abstract class WsClientGenerator extends Generator {
41
42     /** service-ref describing client dependency on a webservice */
43     private ServiceRefDesc ref;
44
45     /** jonas-service-ref modifier */
46     private WsClientDDModifier modifier;
47
48     /** archive */
49     private Archive archive;
50
51     /**
52      * Creates a new WsClientGenerator.
53      *
54      * @param config Generator Configuration
55      * @param serviceRef client dependency on a webservice
56      * @param ddm jonas-service-ref modifier
57      * @param arch modified archive
58      *
59      * @throws GenBaseException When instanciation fails
60      */

61     public WsClientGenerator(Config config, ServiceRefDesc serviceRef, WsClientDDModifier ddm, Archive arch)
62             throws GenBaseException {
63         super(config);
64         ref = serviceRef;
65         modifier = ddm;
66         archive = arch;
67     }
68     /**
69      * @return the archive.
70      */

71     public Archive getArchive() {
72         return archive;
73     }
74     /**
75      * @return the modifier.
76      */

77     public WsClientDDModifier getModifier() {
78         return modifier;
79     }
80     /**
81      * @return the ref.
82      */

83     public ServiceRefDesc getRef() {
84         return ref;
85     }
86 }
Popular Tags