- if xml.tagName is set, this is our tagName, no question there.
- if the we are not in an association : tagName is the name of the class/field (starting with lower case)
- if we are in an association :
- if xml.associationTagName is set, this is our tagName
- else tagName is the name of the association in singular if xml.listStyle is set to WRAPPED, as given is xml.listStyle is set to FLAT.
Other candidate helper methods
Following helper methods should be included in utility pack somewhere:
- isInnerAssociation( Model objectModel, ModelField field )
- isManyAssociation( Model objectModel, ModelField field )
- isWrappedAssociation( Model objectModel, ModelField field )
- isFlatAssociation( Model objectModel, ModelField field )
- isNonRecursiveAssociation( Model objectModel, ModelClass modelClass, ModelAssociation association )
All of these methods are provided in path http://jira.codehaus.org/browse/MODELLO-56 (initially for use in Xdoc Plugin)