User: ara_e_w 
  Date: 02/02/18 11:01:14

  Modified:    src/xjavadoc XJavaDoc.java
  Log:
  - correct versin of XJavaDoc
  - removed Util.blabla (no use for our case, it lists all .java classes, xjavadoc 
will be used by xdoclet and it already uses dirscanner)
  
  Revision  Changes    Path
  1.10      +553 -505  xjavadoc/src/xjavadoc/XJavaDoc.java
  
  Index: XJavaDoc.java
  ===================================================================
  RCS file: /cvsroot/xdoclet/xjavadoc/src/xjavadoc/XJavaDoc.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -w -r1.9 -r1.10
  --- XJavaDoc.java     18 Feb 2002 01:33:05 -0000      1.9
  +++ XJavaDoc.java     18 Feb 2002 19:01:13 -0000      1.10
  @@ -80,15 +80,15 @@
        /**
         * @todo-javadoc Describe the field
         */
  -     private final File _dir;
  +     private File _dir;
        /**
         * @todo-javadoc Describe the field
         */
  -     private final String[] _files;
  +     private String[] _files;
        /**
         * @todo-javadoc Describe the field
         */
  -     private final String _docletClass;
  +     private String _docletClass;
   
        /**
         * @todo-javadoc Describe the field
  @@ -96,6 +96,11 @@
        public final static List PRIMITIVES = 
Collections.unmodifiableList(Arrays.asList(new String[]
                        {"void", "byte", "short", "int", "long", "char", "float", 
"double", "boolean"}
                        ));
  +
  +     /**
  +      * @todo-javadoc Describe the field
  +      */
  +     private final static XJavaDoc instance = new XJavaDoc();
        /**
         * Get static reference to Log4J Logger
         */
  @@ -108,29 +113,62 @@
   
   
        /**
  -      * Constructor
  +      * Sets the Dir attribute of the XJavaDoc object
  +      *
  +      * @param dir The new Dir value
  +      */
  +     public void setDir(File dir) {
  +             this._dir = dir;
  +     }
  +
  +
  +     /**
  +      * Sets the DocletClass attribute of the XJavaDoc object
  +      *
  +      * @param docletClass The new DocletClass value
  +      */
  +     public void setDocletClass(String docletClass) {
  +             this._docletClass = docletClass;
  +     }
  +
  +
  +     /**
  +      * Sets the Files attribute of the XJavaDoc object
  +      *
  +      * @param files The new Files value
  +      */
  +     public void setFiles(String[] files) {
  +             this._files = files;
  +     }
  +
  +
  +     /**
  +      * Gets the Dir attribute of the XJavaDoc object
         *
  -      * @param dir rootdir
  -      * @param files files to parse (relative names)
  -      * @param docletClass doclet to invoke after parsing
  +      * @return The Dir value
         */
  -     public XJavaDoc(File dir, String[] files, String docletClass) {
  -             _dir = dir;
  -             _files = files;
  -             _docletClass = docletClass;
  +     public File getDir() {
  +             return _dir;
        }
   
   
        /**
  -      * Constructor
  +      * Gets the DocletClass attribute of the XJavaDoc object
         *
  -      * @param dir source dir to search for .java files
  -      * @param docletClass doclet to invoke after parsing
  +      * @return The DocletClass value
         */
  -     public XJavaDoc(File dir, String docletClass) {
  -             _dir = dir;
  -             _docletClass = docletClass;
  -             _files = Util.getJavaFiles(dir);
  +     public String getDocletClass() {
  +             return _docletClass;
  +     }
  +
  +
  +     /**
  +      * Gets the Files attribute of the XJavaDoc object
  +      *
  +      * @return The Files value
  +      */
  +     public String[] getFiles() {
  +             return _files;
        }
   
   
  @@ -184,7 +222,7 @@
                UnknownClass result = (UnknownClass)_unknownClasses.get(qualifiedName);
                if (result == null) {
                        // Couldn't find the UnknownClass class in the cache. 
Instantiate it.
  -                     result = new UnknownClass(this, qualifiedName);
  +                     result = new UnknownClass(qualifiedName);
                        _unknownClasses.put(qualifiedName, result);
                }
                return result;
  @@ -283,7 +321,7 @@
                        JavaParser javaParser = new JavaParser(in);
                        ASTCompilationUnit compilationUnit = 
javaParser.CompilationUnit();
   
  -                     sourceClass = new SourceClass(this, compilationUnit, 
qualifiedName);
  +                     sourceClass = new SourceClass(compilationUnit, qualifiedName);
                        _sourceClasses.put(qualifiedName, sourceClass);
   
                        _log.debug("Analyzing " + sourceClass.qualifiedName());
  @@ -324,7 +362,7 @@
   //                           JavaParser.ReInit(in);
   //                           ASTCompilationUnit compilationUnit = 
JavaParser.CompilationUnit();
   
  -                             SourceClass sourceClass = new SourceClass(this, 
compilationUnit, qualifiedName);
  +                             SourceClass sourceClass = new 
SourceClass(compilationUnit, qualifiedName);
                                _sourceClasses.put(qualifiedName, sourceClass);
   
                                _log.debug("Analyzing " + sourceClass.qualifiedName());
  @@ -445,7 +483,7 @@
                if (result == null) {
                        // Couldn't find the binary class in the cache. Try to 
instantiate it.
                        Class clazz = Class.forName(qualifiedName);
  -                     result = new BinaryClass(this, clazz);
  +                     result = new BinaryClass(clazz);
                        _binaryClasses.put(qualifiedName, result);
                        // resolve signatures. Might reveal new classes
                        result.methods();
  @@ -475,6 +513,16 @@
   
   
        /**
  +      * Gets the Instance attribute of the XJavaDoc class
  +      *
  +      * @return The Instance value
  +      */
  +     public static XJavaDoc getInstance() {
  +             return instance;
  +     }
  +
  +
  +     /**
         * Gets the Primitive attribute of the XJavaDoc class
         *
         * @param name Describe what the parameter does
  
  
  

_______________________________________________
Xdoclet-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-devel

Reply via email to