Package schema2template.example.odf
Class SourceCodeBaseClass
- java.lang.Object
-
- schema2template.example.odf.SourceCodeBaseClass
-
- All Implemented Interfaces:
Comparable<SourceCodeBaseClass>
,QNamed
public class SourceCodeBaseClass extends Object implements Comparable<SourceCodeBaseClass>, QNamed
Encapsulates the name of the java base classConvention: Unique key is the name of the baseclass. So name is used for compareTo(o), equals(o) and hashCode().
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
SourceCodeBaseClass(OdfModel odfmodel, String basename, SortedSet<PuzzlePiece> subelements)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(SourceCodeBaseClass o)
boolean
equals(Object o)
PuzzlePieceSet
getBaseAttributes()
Returns the attribute Definitions which are shared by all subclasses of this JavaBaseClassPuzzlePieceSet
getElements()
Returns the element Definitions which are subclassing this JavaBaseClassString
getLocalName()
Get only localnameString
getNamespace()
Get only namespaceString
getQName()
Get the QName (i.e.int
hashCode()
boolean
isStylable()
Determines whether all subclasses of this JavaBaseClass are stylable or not stylable.String
toString()
-
-
-
Constructor Detail
-
SourceCodeBaseClass
protected SourceCodeBaseClass(OdfModel odfmodel, String basename, SortedSet<PuzzlePiece> subelements)
-
-
Method Detail
-
compareTo
public int compareTo(SourceCodeBaseClass o)
- Specified by:
compareTo
in interfaceComparable<SourceCodeBaseClass>
-
getLocalName
public String getLocalName()
Description copied from interface:QNamed
Get only localname- Specified by:
getLocalName
in interfaceQNamed
- Returns:
- localname
-
getQName
public String getQName()
Description copied from interface:QNamed
Get the QName (i.e. namespace:localname )
-
getNamespace
public String getNamespace()
Description copied from interface:QNamed
Get only namespace- Specified by:
getNamespace
in interfaceQNamed
- Returns:
- namespace
-
getElements
public PuzzlePieceSet getElements()
Returns the element Definitions which are subclassing this JavaBaseClass- Returns:
- subclasses
-
getBaseAttributes
public PuzzlePieceSet getBaseAttributes()
Returns the attribute Definitions which are shared by all subclasses of this JavaBaseClass- Returns:
- attributes
-
isStylable
public boolean isStylable()
Determines whether all subclasses of this JavaBaseClass are stylable or not stylable.- Returns:
- whether all subclasses are stylable (true) or none (false).
- Throws:
RuntimeException
- if some subclasses are stylable and some are not
-
-