Class QdoxParanamerGenerator

  • All Implemented Interfaces:
    ParanamerGenerator

    public class QdoxParanamerGenerator
    extends java.lang.Object
    implements ParanamerGenerator
    Qdox-based implementation of ParanamerGenerator which parses Java source files to processSourcePath parameter names lists.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private static java.lang.String COMMA  
      private static java.lang.String NEWLINE  
      private static java.lang.String SPACE  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private java.lang.CharSequence addConstructor​(com.thoughtworks.qdox.model.JavaConstructor constructor)  
      private java.lang.String addConstructors​(java.util.List<com.thoughtworks.qdox.model.JavaConstructor> methods)  
      private java.lang.CharSequence addMethod​(com.thoughtworks.qdox.model.JavaMethod method)  
      private java.lang.String addMethods​(java.util.List<com.thoughtworks.qdox.model.JavaMethod> methods)  
      private java.lang.CharSequence format​(java.lang.String name, java.util.List<com.thoughtworks.qdox.model.JavaParameter> parameters, boolean isConstructor)  
      private java.lang.CharSequence formatLine​(java.lang.String methodName, java.lang.String paramTypes, java.lang.String paramNames)  
      private java.util.List<com.thoughtworks.qdox.model.JavaClass> getClassesSortedByName​(java.lang.String sourcePath)  
      private java.lang.String getParameterNames​(java.util.List<com.thoughtworks.qdox.model.JavaParameter> parameters)  
      private java.lang.String getParameterTypes​(java.util.List<com.thoughtworks.qdox.model.JavaParameter> parameters)  
      Enhancer makeEnhancer()  
      void processClasses​(java.util.Collection<com.thoughtworks.qdox.model.JavaClass> classes, java.lang.String outputPath)  
      void processSourcePath​(java.lang.String sourcePath, java.lang.String outputPath)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • QdoxParanamerGenerator

        public QdoxParanamerGenerator()
    • Method Detail

      • processSourcePath

        public void processSourcePath​(java.lang.String sourcePath,
                                      java.lang.String outputPath)
                               throws java.io.IOException
        Specified by:
        processSourcePath in interface ParanamerGenerator
        Throws:
        java.io.IOException
      • getClassesSortedByName

        private java.util.List<com.thoughtworks.qdox.model.JavaClass> getClassesSortedByName​(java.lang.String sourcePath)
      • processClasses

        public void processClasses​(java.util.Collection<com.thoughtworks.qdox.model.JavaClass> classes,
                                   java.lang.String outputPath)
                            throws java.io.IOException
        Throws:
        java.io.IOException
      • makeEnhancer

        public Enhancer makeEnhancer()
      • addConstructors

        private java.lang.String addConstructors​(java.util.List<com.thoughtworks.qdox.model.JavaConstructor> methods)
      • addMethods

        private java.lang.String addMethods​(java.util.List<com.thoughtworks.qdox.model.JavaMethod> methods)
      • addConstructor

        private java.lang.CharSequence addConstructor​(com.thoughtworks.qdox.model.JavaConstructor constructor)
      • addMethod

        private java.lang.CharSequence addMethod​(com.thoughtworks.qdox.model.JavaMethod method)
      • format

        private java.lang.CharSequence format​(java.lang.String name,
                                              java.util.List<com.thoughtworks.qdox.model.JavaParameter> parameters,
                                              boolean isConstructor)
      • formatLine

        private java.lang.CharSequence formatLine​(java.lang.String methodName,
                                                  java.lang.String paramTypes,
                                                  java.lang.String paramNames)
      • getParameterNames

        private java.lang.String getParameterNames​(java.util.List<com.thoughtworks.qdox.model.JavaParameter> parameters)
      • getParameterTypes

        private java.lang.String getParameterTypes​(java.util.List<com.thoughtworks.qdox.model.JavaParameter> parameters)