ch.sahits.model.java
Class GeneratedJavaClass

java.lang.Object
  extended by ch.sahits.model.GeneratedClass
      extended by ch.sahits.model.java.GeneratedJavaClass
All Implemented Interfaces:
IGeneratedObject, IGeneratorClass, IGeneratorClass2, IGeneratedJavaClass2, java.lang.Cloneable
Direct Known Subclasses:
GeneratedJavaDBClass

public class GeneratedJavaClass
extends GeneratedClass
implements IGeneratedJavaClass2

This class is the Java specific extension of GeneratedClass. The data class model is extended with Java language specific attributes.

Since:
0.9.3
Author:
Andi Hotz

Constructor Summary
GeneratedJavaClass(java.lang.String name)
          Constructor initializing the class name
GeneratedJavaClass(java.lang.String _packageName, java.lang.String className)
           
 
Method Summary
 void addSuperClass(java.lang.Class superclass)
          Set the superclass as the first element in the superclasses list
 boolean equals(java.lang.Object obj)
           
 java.lang.String getGeneratorClassPath()
           
 java.lang.String getInputFilePath()
           
 java.lang.Class[] getInterfaces()
          Convenient method to retrieve an array of all interfaces
 java.lang.String getJetTemplatePath()
           
 IJavaProject getJProject()
           
 java.lang.String getPackageName()
          Get the package name if it exists
 java.lang.String getReferenceImplementationPath()
           
 java.lang.String getSrcPath()
           
 EVisibility getVisibility()
           
 int hashCode()
           
 java.util.List<java.lang.Class> interfaces()
           
 boolean isAbstract()
           
 boolean isAstTemplateUse()
          correspondence with CHECKBOX AST generation
 boolean isFinal()
           
 boolean isGeneratorClassPathInPlugin()
           
 boolean isGeneratorUse()
          correspondence with RADIO Button generator
 boolean isJetFileUse()
          correspondence with RADIO Button jetemplate
 boolean isJetTemplateInPlugin()
           
 boolean isJetTemplateUse()
          correspondence with CHECKBOX jetemplate
 boolean isPackageDefault()
          Check if the visibility is package default
 boolean isPrivate()
          Check if the visibility is private
 boolean isProtected()
          Check if the visibility is protected
 boolean isPublic()
          Check if the visibility is public
 boolean isSympleType(java.lang.Class c)
          Check if the class is of a simple type, ie a primitive type or a type from package 'java.lang
 void setAbstract(boolean __abstract)
           
 void setAstTemplateUse(boolean _astTemplateUse)
          correspondence with CHECKBOX AST generation
 void setFinal(boolean __final)
           
 void setGeneratorClassPath(java.lang.String _generatorClassPath)
           
 void setGeneratorClassPathInPlugin(boolean _generatorClassPathInPlugin)
           
 void setGeneratorUse(boolean _generatorUse)
          correspondence with RADIO Button generator
 void setInputFilePath(java.lang.String _inputFilePath)
           
 void setJetFileUse(boolean _jetFileUse)
          correspondence with RADIO Button jetemplate
 void setJetTemplateInPlugin(boolean _jetTemplateInPlugin)
           
 void setJetTemplatePath(java.lang.String _jetTemplatePath)
           
 void setJetTemplateUse(boolean _jetTemplateUse)
          correspondence with CHECKBOX jetemplate
 void setJProject(IJavaProject project)
           
 void setPackageName(java.lang.String _packageName)
           
 void setReferenceImplementationPath(java.lang.String _referenceImplementationPath)
           
 void setSrcPath(java.lang.String _srcPath)
           
 void setVisibility(EVisibility _visibility)
           
 
Methods inherited from class ch.sahits.model.GeneratedClass
getClassName, hasSuperClass, setClassName, superclasses
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface ch.sahits.model.java.IGeneratedJavaClass2
getClassName
 
Methods inherited from interface ch.sahits.model.IGeneratorClass
setClassName
 
Methods inherited from interface ch.sahits.model.IGeneratorClass2
hasSuperClass, superclasses
 

Constructor Detail

GeneratedJavaClass

public GeneratedJavaClass(java.lang.String _packageName,
                          java.lang.String className)
Parameters:
_packageName - Name of the package
className - Name of the class

GeneratedJavaClass

public GeneratedJavaClass(java.lang.String name)
Constructor initializing the class name

Parameters:
name -
Method Detail

interfaces

public java.util.List<java.lang.Class> interfaces()
Specified by:
interfaces in interface IGeneratedJavaClass2
Returns:
the interfaces

getInterfaces

public java.lang.Class[] getInterfaces()
Convenient method to retrieve an array of all interfaces

Specified by:
getInterfaces in interface IGeneratedJavaClass2
Returns:
Array with all interfaces

getVisibility

public EVisibility getVisibility()
Specified by:
getVisibility in interface IGeneratedJavaClass2
Returns:
the visibility

setVisibility

public void setVisibility(EVisibility _visibility)
Parameters:
_visibility - the visibility to set

isFinal

public boolean isFinal()
Specified by:
isFinal in interface IGeneratedJavaClass2
Returns:
the _final

setFinal

public void setFinal(boolean __final)
Parameters:
__final - the _final to set

isAbstract

public boolean isAbstract()
Specified by:
isAbstract in interface IGeneratedJavaClass2
Returns:
the _abstract

setAbstract

public void setAbstract(boolean __abstract)
Parameters:
__abstract - the _abstract to set

isPublic

public boolean isPublic()
Check if the visibility is public

Specified by:
isPublic in interface IGeneratedJavaClass2
Returns:
true if the visibility is public

isPrivate

public boolean isPrivate()
Check if the visibility is private

Specified by:
isPrivate in interface IGeneratedJavaClass2
Returns:
true if the visibility is private

isPackageDefault

public boolean isPackageDefault()
Check if the visibility is package default

Specified by:
isPackageDefault in interface IGeneratedJavaClass2
Returns:
true if the visibility is package default

isProtected

public boolean isProtected()
Check if the visibility is protected

Specified by:
isProtected in interface IGeneratedJavaClass2
Returns:
true if the visibility is protected

getJProject

public IJavaProject getJProject()
Specified by:
getJProject in interface IGeneratedJavaClass2
Returns:
the jProject

setJProject

public void setJProject(IJavaProject project)
Parameters:
project - the jProject to set

getSrcPath

public java.lang.String getSrcPath()
Specified by:
getSrcPath in interface IGeneratedJavaClass2
Returns:
the srcPath

setSrcPath

public void setSrcPath(java.lang.String _srcPath)
Parameters:
_srcPath - the srcPath to set

getPackageName

public java.lang.String getPackageName()
Get the package name if it exists

Specified by:
getPackageName in interface IGeneratedJavaClass2
Returns:
the packageName name of the package or empty string

setPackageName

public void setPackageName(java.lang.String _packageName)
Parameters:
_packageName - the packageName to set

isJetFileUse

public boolean isJetFileUse()
correspondence with RADIO Button jetemplate

Specified by:
isJetFileUse in interface IGeneratedJavaClass2
Returns:
the jetFileUse

setJetFileUse

public void setJetFileUse(boolean _jetFileUse)
correspondence with RADIO Button jetemplate

Parameters:
_jetFileUse - the jetFileUse to set

isGeneratorUse

public boolean isGeneratorUse()
correspondence with RADIO Button generator

Specified by:
isGeneratorUse in interface IGeneratedJavaClass2
Returns:
the generatorUse

setGeneratorUse

public void setGeneratorUse(boolean _generatorUse)
correspondence with RADIO Button generator

Parameters:
_generatorUse - the generatorUse to set

isJetTemplateUse

public boolean isJetTemplateUse()
correspondence with CHECKBOX jetemplate

Specified by:
isJetTemplateUse in interface IGeneratedJavaClass2
Returns:
the jetTemplateUse

setJetTemplateUse

public void setJetTemplateUse(boolean _jetTemplateUse)
correspondence with CHECKBOX jetemplate

Parameters:
_jetTemplateUse - the jetTemplateUse to set

isAstTemplateUse

public boolean isAstTemplateUse()
correspondence with CHECKBOX AST generation

Specified by:
isAstTemplateUse in interface IGeneratedJavaClass2
Returns:
the astTemplateUse

setAstTemplateUse

public void setAstTemplateUse(boolean _astTemplateUse)
correspondence with CHECKBOX AST generation

Parameters:
_astTemplateUse - the astTemplateUse to set

getInputFilePath

public java.lang.String getInputFilePath()
Specified by:
getInputFilePath in interface IGeneratedJavaClass2
Returns:
the inputFilePath

setInputFilePath

public void setInputFilePath(java.lang.String _inputFilePath)
Parameters:
_inputFilePath - the inputFilePath to set

getJetTemplatePath

public java.lang.String getJetTemplatePath()
Specified by:
getJetTemplatePath in interface IGeneratedJavaClass2
Returns:
the jetTemplatePath

setJetTemplatePath

public void setJetTemplatePath(java.lang.String _jetTemplatePath)
Parameters:
_jetTemplatePath - the jetTemplatePath to set

isJetTemplateInPlugin

public boolean isJetTemplateInPlugin()
Specified by:
isJetTemplateInPlugin in interface IGeneratedJavaClass2
Returns:
the jetTemplateInPlugin

setJetTemplateInPlugin

public void setJetTemplateInPlugin(boolean _jetTemplateInPlugin)
Parameters:
_jetTemplateInPlugin - the jetTemplateInPlugin to set

getGeneratorClassPath

public java.lang.String getGeneratorClassPath()
Specified by:
getGeneratorClassPath in interface IGeneratedJavaClass2
Returns:
the generatorClassPath

setGeneratorClassPath

public void setGeneratorClassPath(java.lang.String _generatorClassPath)
Parameters:
_generatorClassPath - the generatorClassPath to set

isGeneratorClassPathInPlugin

public boolean isGeneratorClassPathInPlugin()
Specified by:
isGeneratorClassPathInPlugin in interface IGeneratedJavaClass2
Returns:
the generatorClassPathInPlugin

setGeneratorClassPathInPlugin

public void setGeneratorClassPathInPlugin(boolean _generatorClassPathInPlugin)
Parameters:
_generatorClassPathInPlugin - the generatorClassPathInPlugin to set

getReferenceImplementationPath

public java.lang.String getReferenceImplementationPath()
Specified by:
getReferenceImplementationPath in interface IGeneratedJavaClass2
Returns:
the referenceImplementationPath

setReferenceImplementationPath

public void setReferenceImplementationPath(java.lang.String _referenceImplementationPath)
Parameters:
_referenceImplementationPath - the referenceImplementationPath to set

isSympleType

public boolean isSympleType(java.lang.Class c)
Check if the class is of a simple type, ie a primitive type or a type from package 'java.lang.*'

Specified by:
isSympleType in interface IGeneratedJavaClass2
Parameters:
c - Class to be checked
Returns:
true if the class is a simple type

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object
See Also:
Object.hashCode()

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object
See Also:
Object.equals(java.lang.Object)

addSuperClass

public void addSuperClass(java.lang.Class superclass)
Set the superclass as the first element in the superclasses list

Specified by:
addSuperClass in interface IGeneratorClass
Overrides:
addSuperClass in class GeneratedClass
Parameters:
superclass - the superClass to set
See Also:
GeneratedClass.addSuperClass(java.lang.Class)