net.noco.dtogen
Class Scanner

java.lang.Object
  extended bynet.noco.dtogen.Scanner

public class Scanner
extends java.lang.Object

This class is responsible with the extraction of interesting info out of the sources.

Version:
$Revision: 1.59 $
Author:
the_mindstorm(at)evolva(dot)ro

Field Summary
private static ILog L
           
 
Constructor Summary
Scanner()
           
 
Method Summary
private  java.util.List extractBeanProperties(com.thoughtworks.qdox.model.JavaClass clazz)
          Returns an array of BeanProperties which use in their accessor dto.gen.property.
private  java.util.List extractClassTags(com.thoughtworks.qdox.model.JavaClass clazz)
          Extract class level tags dto.gen.class and validate if parameter class is used.
private  java.util.List extractPKBeanProperties(com.thoughtworks.qdox.model.JavaClass clazz)
          Extract BeanProperties that are declared as PK using tag dto.gen.pk.
 void scan(ModelRepository repository, com.thoughtworks.qdox.model.JavaClass sourceClass)
          Extract all necessary information from the given java class and registers it in the ModelRepository.
private  boolean validateBeanTag(com.thoughtworks.qdox.model.BeanProperty bp, java.lang.String tagName, java.lang.String[] required)
           
private  boolean validateParameters(java.util.List classTags, java.util.List pks, java.util.List bps)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

L

private static final ILog L
Constructor Detail

Scanner

public Scanner()
Method Detail

scan

public void scan(ModelRepository repository,
                 com.thoughtworks.qdox.model.JavaClass sourceClass)
Extract all necessary information from the given java class and registers it in the ModelRepository.

Parameters:
repository - repository to be used for registering info
sourceClass - java source class

validateParameters

private boolean validateParameters(java.util.List classTags,
                                   java.util.List pks,
                                   java.util.List bps)

extractPKBeanProperties

private java.util.List extractPKBeanProperties(com.thoughtworks.qdox.model.JavaClass clazz)
Extract BeanProperties that are declared as PK using tag dto.gen.pk.

Returns:
a list of BeanProperty (List)

validateBeanTag

private boolean validateBeanTag(com.thoughtworks.qdox.model.BeanProperty bp,
                                java.lang.String tagName,
                                java.lang.String[] required)

extractBeanProperties

private java.util.List extractBeanProperties(com.thoughtworks.qdox.model.JavaClass clazz)
Returns an array of BeanProperties which use in their accessor dto.gen.property.

Returns:
a list of BeanProperty (List)

extractClassTags

private java.util.List extractClassTags(com.thoughtworks.qdox.model.JavaClass clazz)
Extract class level tags dto.gen.class and validate if parameter class is used.

Returns:
a list containing DocletTags


Copyright © 2004 Alexandru Popescu (a.k.a. the_mindstorm). All Rights Reserved.