KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > axis > wsdl > toJava > Emitter


1 /*
2  * The Apache Software License, Version 1.1
3  *
4  *
5  * Copyright (c) 2001-2003 The Apache Software Foundation. All rights
6  * reserved.
7  *
8  * Redistribution and use in source and binary forms, with or without
9  * modification, are permitted provided that the following conditions
10  * are met:
11  *
12  * 1. Redistributions of source code must retain the above copyright
13  * notice, this list of conditions and the following disclaimer.
14  *
15  * 2. Redistributions in binary form must reproduce the above copyright
16  * notice, this list of conditions and the following disclaimer in
17  * the documentation and/or other materials provided with the
18  * distribution.
19  *
20  * 3. The end-user documentation included with the redistribution,
21  * if any, must include the following acknowledgment:
22  * "This product includes software developed by the
23  * Apache Software Foundation (http://www.apache.org/)."
24  * Alternately, this acknowledgment may appear in the software itself,
25  * if and wherever such third-party acknowledgments normally appear.
26  *
27  * 4. The names "Axis" and "Apache Software Foundation" must
28  * not be used to endorse or promote products derived from this
29  * software without prior written permission. For written
30  * permission, please contact apache@apache.org.
31  *
32  * 5. Products derived from this software may not be called "Apache",
33  * nor may "Apache" appear in their name, without prior written
34  * permission of the Apache Software Foundation.
35  *
36  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
37  * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
38  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
39  * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
40  * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
41  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
42  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
43  * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
44  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
45  * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
46  * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
47  * SUCH DAMAGE.
48  * ====================================================================
49  *
50  * This software consists of voluntary contributions made by many
51  * individuals on behalf of the Apache Software Foundation. For more
52  * information on the Apache Software Foundation, please see
53  * <http://www.apache.org/>.
54  */

55 package org.jboss.axis.wsdl.toJava;
56
57 import org.jboss.axis.encoding.DefaultSOAPEncodingTypeMappingImpl;
58 import org.jboss.axis.encoding.DefaultTypeMappingImpl;
59 import org.jboss.axis.encoding.TypeMapping;
60 import org.jboss.axis.enums.Scope;
61 import org.jboss.axis.i18n.Messages;
62 import org.jboss.axis.utils.ClassUtils;
63 import org.jboss.axis.utils.JavaUtils;
64 import org.jboss.axis.wsdl.gen.GeneratorFactory;
65 import org.jboss.axis.wsdl.gen.Parser;
66 import org.jboss.axis.wsdl.symbolTable.BaseTypeMapping;
67 import org.jboss.axis.wsdl.symbolTable.SymTabEntry;
68 import org.jboss.axis.wsdl.symbolTable.SymbolTable;
69 import org.w3c.dom.Document JavaDoc;
70 import org.xml.sax.SAXException JavaDoc;
71
72 import javax.wsdl.WSDLException;
73 import javax.xml.namespace.QName JavaDoc;
74 import javax.xml.parsers.ParserConfigurationException JavaDoc;
75 import java.io.FileInputStream JavaDoc;
76 import java.io.IOException JavaDoc;
77 import java.lang.reflect.Constructor JavaDoc;
78 import java.util.Enumeration JavaDoc;
79 import java.util.HashMap JavaDoc;
80 import java.util.Iterator JavaDoc;
81 import java.util.List JavaDoc;
82 import java.util.Properties JavaDoc;
83 import java.util.Vector JavaDoc;
84
85 /**
86  * This class produces java files for stubs, skeletons, and types from a
87  * WSDL document.
88  *
89  * @author Russell Butek (butek@us.ibm.com)
90  * @author Tom Jordahl (tjordahl@macromedia.com)
91  * @author Rich Scheuerle (scheu@us.ibm.com)
92  * @author Steve Graham (sggraham@us.ibm.com)
93  */

94 public class Emitter extends Parser
95 {
96
97    public static final String JavaDoc DEFAULT_NSTOPKG_FILE = "NStoPkg.properties";
98
99    protected HashMap JavaDoc namespaceMap = new HashMap JavaDoc();
100    protected String JavaDoc typeMappingVersion = "1.1";
101    protected BaseTypeMapping baseTypeMapping = null;
102    protected Namespaces namespaces = null;
103    protected String JavaDoc NStoPkgFilename = null;
104
105    private boolean bEmitServer = false;
106    private boolean bDeploySkeleton = false;
107    private boolean bEmitTestCase = false;
108    private boolean bGenerateAll = false;
109    private boolean bHelperGeneration = false;
110    private String JavaDoc packageName = null;
111    private Scope scope = null;
112    private GeneratedFileInfo fileInfo = new GeneratedFileInfo();
113    private HashMap JavaDoc delayedNamespacesMap = new HashMap JavaDoc();
114    private String JavaDoc outputDir = null;
115
116    /**
117     * Default constructor.
118     */

119    public Emitter()
120    {
121       setFactory(new JavaGeneratorFactory(this));
122    } // ctor
123

124    ///////////////////////////////////////////////////
125
//
126
// Command line switches
127
//
128

129    /**
130     * Turn on/off server skeleton creation
131     *
132     * @param value
133     */

134    public void setServerSide(boolean value)
135    {
136       this.bEmitServer = value;
137    } // setServerSide
138

139    /**
140     * Indicate if we should be emitting server side code and deploy/undeploy
141     */

142    public boolean isServerSide()
143    {
144       return bEmitServer;
145    } // isServerSide
146

147    /**
148     * Turn on/off server skeleton deploy
149     *
150     * @param value
151     */

152    public void setSkeletonWanted(boolean value)
153    {
154       bDeploySkeleton = value;
155    } // setSkeletonWanted
156

157    /**
158     * Indicate if we should be deploying skeleton or implementation
159     */

160    public boolean isSkeletonWanted()
161    {
162       return bDeploySkeleton;
163    } // isSkeletonWanted
164

165    /**
166     * Turn on/off Helper class generation
167     *
168     * @param value
169     */

170    public void setHelperWanted(boolean value)
171    {
172       bHelperGeneration = value;
173    } // setHelperWanted
174

175    /**
176     * Indicate if we should be generating Helper classes
177     */

178    public boolean isHelperWanted()
179    {
180       return bHelperGeneration;
181    } // isHelperWanted
182

183    /**
184     * Turn on/off test case creation
185     *
186     * @param value
187     */

188    public void setTestCaseWanted(boolean value)
189    {
190       this.bEmitTestCase = value;
191    } // setTestCaseWanted
192

193    public boolean isTestCaseWanted()
194    {
195       return bEmitTestCase;
196    } // isTestCaseWanted
197

198    /**
199     * By default, code is generated only for referenced elements.
200     * Call bGenerateAll(true) and WSDL2Java will generate code for all
201     * elements in the scope regardless of whether they are
202     * referenced. Scope means: by default, all WSDL files; if
203     * generateImports(false), then only the immediate WSDL file.
204     */

205    public void setAllWanted(boolean all)
206    {
207       bGenerateAll = all;
208    } // setAllWanted
209

210    public boolean isAllWanted()
211    {
212       return bGenerateAll;
213    } // isAllWanted
214

215    public Namespaces getNamespaces()
216    {
217       return namespaces;
218    } // getNamespaces
219

220    /**
221     * Set the output directory to use in emitted source files
222     */

223    public void setOutputDir(String JavaDoc outputDir)
224    {
225       this.outputDir = outputDir;
226    }
227
228    /**
229     * Get the output directory to use for emitted source files
230     */

231    public String JavaDoc getOutputDir()
232    {
233       return outputDir;
234    }
235
236    /**
237     * Get global package name to use instead of mapping namespaces
238     */

239    public String JavaDoc getPackageName()
240    {
241       return packageName;
242    }
243
244    /**
245     * Set a global package name to use instead of mapping namespaces
246     */

247    public void setPackageName(String JavaDoc packageName)
248    {
249       this.packageName = packageName;
250    }
251
252    /**
253     * Set the scope for the deploy.xml file.
254     *
255     * @param scope One of 'null',
256     * Scope.APPLICATION, Scope.REQUEST, Scope.SESSION.
257     * Anything else is equivalent to 'null' null and no explicit
258     * scope tag will appear in deploy.xml.
259     */

260    public void setScope(Scope scope)
261    {
262       this.scope = scope;
263    } // setScope
264

265    /**
266     * Get the scope for the deploy.xml file.
267     */

268    public Scope getScope()
269    {
270       return scope;
271    } // getScope
272

273    /**
274     * Set the NStoPkg mappings filename.
275     */

276    public void setNStoPkg(String JavaDoc NStoPkgFilename)
277    {
278       if (NStoPkgFilename != null)
279       {
280          this.NStoPkgFilename = NStoPkgFilename;
281       }
282    } // setNStoPkg
283

284
285    /**
286     * Set a map of namespace -> Java package names
287     */

288    public void setNamespaceMap(HashMap JavaDoc map)
289    {
290       delayedNamespacesMap = map;
291    }
292
293    /**
294     * Get the map of namespace -> Java package names
295     */

296    public HashMap JavaDoc getNamespaceMap()
297    {
298       return delayedNamespacesMap;
299    }
300
301    /**
302     * Sets the <code>WriterFactory Class</code> to use
303     *
304     * @param factory the name of the factory <code>Class</code>
305     */

306    public void setFactory(String JavaDoc factory)
307    {
308       try
309       {
310          Class JavaDoc clazz = ClassUtils.forName(factory);
311          GeneratorFactory genFac = null;
312          try
313          {
314             Constructor JavaDoc ctor =
315                     clazz.getConstructor(new Class JavaDoc[]{getClass()});
316             genFac = (GeneratorFactory)
317                     ctor.newInstance(new Object JavaDoc[]{this});
318          }
319          catch (NoSuchMethodException JavaDoc ex)
320          {
321             genFac = (GeneratorFactory)clazz.newInstance();
322          }
323          setFactory(genFac);
324       }
325       catch (Exception JavaDoc ex)
326       {
327          ex.printStackTrace();
328       }
329    } // setFactory
330

331    //
332
// Command line switches
333
//
334
///////////////////////////////////////////////////
335

336    /**
337     * Returns an object which contains of information on all generated files
338     * including the class name, filename and a type string.
339     *
340     * @return An org.jboss.axis.wsdl.toJava.GeneratedFileInfo object
341     * @see org.jboss.axis.wsdl.toJava.GeneratedFileInfo
342     */

343    public GeneratedFileInfo getGeneratedFileInfo()
344    {
345       return fileInfo;
346    }
347
348    /**
349     * This method returns a list of all generated class names.
350     */

351    public List JavaDoc getGeneratedClassNames()
352    {
353       return fileInfo.getClassNames();
354    }
355
356    /**
357     * This method returns a list of all generated file names.
358     */

359    public List JavaDoc getGeneratedFileNames()
360    {
361       return fileInfo.getFileNames();
362    }
363
364    /**
365     * Get the Package name for the specified namespace
366     */

367    public String JavaDoc getPackage(String JavaDoc namespace)
368    {
369       return namespaces.getCreate(namespace);
370    }
371
372    /**
373     * Get the Package name for the specified QName
374     */

375    public String JavaDoc getPackage(QName JavaDoc qName)
376    {
377       return getPackage(qName.getNamespaceURI());
378    }
379
380    /**
381     * Convert the specified QName into a full Java Name.
382     */

383    public String JavaDoc getJavaName(QName JavaDoc qName)
384    {
385
386       // If this is one of our special 'collection' qnames.
387
// get the element type and append []
388
if (qName.getLocalPart().indexOf("[") > 0)
389       {
390          String JavaDoc localPart = qName.getLocalPart().substring(0, qName.getLocalPart().indexOf("["));
391          QName JavaDoc eQName = new QName JavaDoc(qName.getNamespaceURI(), localPart);
392          return getJavaName(eQName) + "[]";
393       }
394
395       // Handle the special "java" namespace for types
396
if (qName.getNamespaceURI().equalsIgnoreCase("java"))
397       {
398          return qName.getLocalPart();
399       }
400
401       // The QName may represent a base java name, so check this first
402
String JavaDoc fullJavaName = getFactory().getBaseTypeMapping().getBaseName(qName);
403       if (fullJavaName != null)
404          return fullJavaName;
405
406       // Use the namespace uri to get the appropriate package
407
String JavaDoc pkg = getPackage(qName.getNamespaceURI());
408       if (pkg != null)
409       {
410          fullJavaName = pkg + "." + Utils.xmlNameToJavaClass(qName.getLocalPart());
411       }
412       else
413       {
414          fullJavaName = Utils.xmlNameToJavaClass(qName.getLocalPart());
415       }
416       return fullJavaName;
417    } // getJavaName
418

419
420    /**
421     * Emit appropriate Java files for a WSDL at a given URL.
422     * <p/>
423     * This method will time out after the number of milliseconds specified
424     * by our timeoutms member.
425     */

426    public void run(String JavaDoc wsdlURL) throws Exception JavaDoc
427    {
428       setup();
429       super.run(wsdlURL);
430    } // run
431

432    /**
433     * Call this method if your WSDL document has already been
434     * parsed as an XML DOM document.
435     *
436     * @param context context This is directory context for the Document.
437     * If the Document were from file "/x/y/z.wsdl" then the context
438     * could be "/x/y" (even "/x/y/z.wsdl" would work).
439     * If context is null, then the context becomes the current directory.
440     * @param doc doc This is the XML Document containing the WSDL.
441     */

442    public void run(String JavaDoc context, Document JavaDoc doc) throws
443            IOException JavaDoc, SAXException JavaDoc, WSDLException,
444            ParserConfigurationException JavaDoc
445    {
446       setup();
447       super.run(context, doc);
448    } // run
449

450    private void setup() throws IOException JavaDoc
451    {
452       if (baseTypeMapping == null)
453       {
454          setTypeMappingVersion(typeMappingVersion);
455       }
456       getFactory().setBaseTypeMapping(baseTypeMapping);
457
458       namespaces = new Namespaces(outputDir);
459
460       if (packageName != null)
461       {
462          namespaces.setDefaultPackage(packageName);
463       }
464       else
465       {
466          // First, read the namespace mapping file - configurable, by default
467
// NStoPkg.properties - if it exists, and load the namespaceMap HashMap
468
// with its data.
469
getNStoPkgFromPropsFile(namespaces);
470
471          if (delayedNamespacesMap != null)
472          {
473             namespaces.putAll(delayedNamespacesMap);
474          }
475       }
476    } // setup
477

478
479    protected void sanityCheck(SymbolTable symbolTable)
480    {
481       Iterator JavaDoc it = symbolTable.getHashMap().values().iterator();
482       while (it.hasNext())
483       {
484          Vector JavaDoc v = (Vector JavaDoc)it.next();
485          for (int i = 0; i < v.size(); ++i)
486          {
487             SymTabEntry entry = (SymTabEntry)v.elementAt(i);
488             String JavaDoc namespace = entry.getQName().getNamespaceURI();
489             String JavaDoc packageName =
490                     org.jboss.axis.wsdl.toJava.Utils.makePackageName(namespace);
491             String JavaDoc localName = entry.getQName().getLocalPart();
492             if (localName.equals(packageName) &&
493                     packageName.equals(namespaces.getCreate(namespace)))
494             {
495                packageName += "_pkg";
496                namespaces.put(namespace, packageName);
497             }
498
499          }
500       }
501    }
502
503    /**
504     * Tries to load the namespace-to-package mapping file.
505     * <ol>
506     * <li>if a file name is explicitly set using <code>setNStoPkg()</code>, tries
507     * to load the mapping from this file. If this fails, the built-in default
508     * mapping is used.
509     * <p/>
510     * <li>if no file name is set, tries to load the file <code>DEFAULT_NSTOPKG_FILE</code>
511     * as a java resource. If this fails, the built-in dfault mapping is used.
512     * </ol>
513     *
514     * @param namespaces a hashmap which is filled with the namespace-to-package mapping
515     * in this method
516     * @see #setNStoPkg(String)
517     * @see #DEFAULT_NSTOPKG_FILE
518     * @see org.jboss.axis.utils.ClassUtils#getResourceAsStream(java.lang.Class,String)
519     */

520    private void getNStoPkgFromPropsFile(HashMap JavaDoc namespaces) throws IOException JavaDoc
521    {
522
523       Properties JavaDoc mappings = new Properties JavaDoc();
524       if (NStoPkgFilename != null)
525       {
526          try
527          {
528             mappings.load(new FileInputStream JavaDoc(NStoPkgFilename));
529             if (verbose)
530             {
531                System.out.println(Messages.getMessage("nsToPkgFileLoaded00", NStoPkgFilename));
532             }
533          }
534          catch (Throwable JavaDoc t)
535          {
536             // loading the custom mapping file failed. We do not try
537
// to load the mapping from a default mapping file.
538
throw new IOException JavaDoc(Messages.getMessage("nsToPkgFileNotFound00", NStoPkgFilename));
539          }
540       }
541       else
542       {
543          try
544          {
545             mappings.load(new FileInputStream JavaDoc(DEFAULT_NSTOPKG_FILE));
546             if (verbose)
547             {
548                System.out.println(Messages.getMessage("nsToPkgFileLoaded00", DEFAULT_NSTOPKG_FILE));
549             }
550          }
551          catch (Throwable JavaDoc t)
552          {
553             try
554             {
555                mappings.load(ClassUtils.getResourceAsStream(Emitter.class, DEFAULT_NSTOPKG_FILE));
556                if (verbose)
557                {
558                   System.out.println(Messages.getMessage("nsToPkgDefaultFileLoaded00", DEFAULT_NSTOPKG_FILE));
559                }
560
561             }
562             catch (Throwable JavaDoc t1)
563             {
564                // loading the default mapping file failed.
565
// The built-in default mapping is used
566
// No message is given, since this is generally what happens
567
}
568          }
569       }
570
571       Enumeration JavaDoc keys = mappings.propertyNames();
572       while (keys.hasMoreElements())
573       {
574          String JavaDoc key = (String JavaDoc)keys.nextElement();
575          namespaces.put(key, mappings.getProperty(key));
576       }
577    } // getNStoPkgFromPropsFile
578

579    public void setTypeMappingVersion(String JavaDoc typeMappingVersion)
580    {
581       if (typeMappingVersion.equals("1.1"))
582       {
583          baseTypeMapping =
584                  new BaseTypeMapping()
585                  {
586                     final TypeMapping defaultTM = DefaultTypeMappingImpl.getSingleton();
587
588                     public String JavaDoc getBaseName(QName JavaDoc qNameIn)
589                     {
590                        javax.xml.namespace.QName JavaDoc qName =
591                                new javax.xml.namespace.QName JavaDoc(qNameIn.getNamespaceURI(),
592                                        qNameIn.getLocalPart());
593                        Class JavaDoc cls = defaultTM.getClassForQName(qName);
594                        if (cls == null)
595                           return null;
596                        else
597                           return JavaUtils.getTextClassName(cls.getName());
598                     }
599                  };
600       }
601       else
602       {
603          baseTypeMapping =
604                  new BaseTypeMapping()
605                  {
606                     final TypeMapping defaultTM = DefaultSOAPEncodingTypeMappingImpl.create();
607
608                     public String JavaDoc getBaseName(QName JavaDoc qNameIn)
609                     {
610                        javax.xml.namespace.QName JavaDoc qName =
611                                new javax.xml.namespace.QName JavaDoc(qNameIn.getNamespaceURI(),
612                                        qNameIn.getLocalPart());
613                        Class JavaDoc cls = defaultTM.getClassForQName(qName);
614                        if (cls == null)
615                           return null;
616                        else
617                           return JavaUtils.getTextClassName(cls.getName());
618                     }
619                  };
620       }
621    }
622
623    // The remainder are deprecated methods.
624

625    /**
626     * Get the GeneratorFactory.
627     *
628     * @deprecated Call getFactory instead. This doesn't return
629     * a WriterFactory, it returns a GeneratorFactory.
630     */

631    public GeneratorFactory getWriterFactory()
632    {
633       return getFactory();
634    } // getWriterFactory
635

636    /**
637     * Call this method if you have a uri for the WSDL document
638     *
639     * @param uri wsdlURI the location of the WSDL file.
640     * @deprecated Call run(uri) instead.
641     */

642    public void emit(String JavaDoc uri) throws Exception JavaDoc
643    {
644       run(uri);
645    } // emit
646

647    /**
648     * Call this method if your WSDL document has already been
649     * parsed as an XML DOM document.
650     *
651     * @param context context This is directory context for the Document.
652     * If the Document were from file "/x/y/z.wsdl" then the context could be "/x/y"
653     * (even "/x/y/z.wsdl" would work). If context is null, then the context
654     * becomes the current directory.
655     * @param doc doc This is the XML Document containing the WSDL.
656     * @deprecated Call run(context, doc) instead.
657     */

658    public void emit(String JavaDoc context, Document JavaDoc doc)
659            throws IOException JavaDoc, SAXException JavaDoc, WSDLException,
660            ParserConfigurationException JavaDoc
661    {
662       run(context, doc);
663    } // emit
664

665    /**
666     * Turn on/off server-side binding generation
667     *
668     * @param value
669     * @deprecated Use setServerSide(value)
670     */

671    public void generateServerSide(boolean value)
672    {
673       setServerSide(value);
674    }
675
676    /**
677     * Indicate if we should be emitting server side code and deploy/undeploy
678     *
679     * @deprecated Use isServerSide()
680     */

681    public boolean getGenerateServerSide()
682    {
683       return isServerSide();
684    }
685
686    /**
687     * Turn on/off server skeleton deploy
688     *
689     * @param value
690     * @deprecated Use setSkeletonWanted(value)
691     */

692    public void deploySkeleton(boolean value)
693    {
694       setSkeletonWanted(value);
695    }
696
697    /**
698     * Indicate if we should be deploying skeleton or implementation
699     *
700     * @deprecated Use isSkeletonWanted()
701     */

702    public boolean getDeploySkeleton()
703    {
704       return isSkeletonWanted();
705    }
706
707    /**
708     * Turn on/off Helper class generation
709     *
710     * @param value
711     * @deprecated Use setHelperWanted(value)
712     */

713    public void setHelperGeneration(boolean value)
714    {
715       setHelperWanted(value);
716    }
717
718    /**
719     * Indicate if we should be generating Helper classes
720     *
721     * @deprecated Use isHelperWanted()
722     */

723    public boolean getHelperGeneration()
724    {
725       return isHelperWanted();
726    }
727
728    /**
729     * Turn on/off generation of elements from imported files.
730     *
731     * @param generateImports
732     * @deprecated Use setImports(generateImports)
733     */

734    public void generateImports(boolean generateImports)
735    {
736       setImports(generateImports);
737    } // generateImports
738

739    /**
740     * Turn on/off debug messages.
741     *
742     * @param value
743     * @deprecated Use setDebug(value)
744     */

745    public void debug(boolean value)
746    {
747       setDebug(value);
748    } // debug
749

750    /**
751     * Return the status of the debug switch.
752     *
753     * @deprecated Use isDebug()
754     */

755    public boolean getDebug()
756    {
757       return isDebug();
758    } // getDebug
759

760    /**
761     * Turn on/off verbose messages
762     *
763     * @param value
764     * @deprecated Use setVerbose(value)
765     */

766    public void verbose(boolean value)
767    {
768       setVerbose(value);
769    }
770
771    /**
772     * Return the status of the verbose switch
773     *
774     * @deprecated Use isVerbose()
775     */

776    public boolean getVerbose()
777    {
778       return isVerbose();
779    }
780
781    /**
782     * Turn on/off test case creation
783     *
784     * @param value
785     * @deprecated Use setTestCaseWanted()
786     */

787    public void generateTestCase(boolean value)
788    {
789       setTestCaseWanted(value);
790    }
791
792    /**
793     * @deprecated Use setAllWanted(all)
794     */

795    public void generateAll(boolean all)
796    {
797       setAllWanted(all);
798    } // generateAll
799
}
800
Popular Tags