[
https://issues.apache.org/jira/browse/TUSCANY-1050?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12465166
]
Frank Budinsky commented on TUSCANY-1050:
-----------------------------------------
Hi David,
There is one problem with your patch. Tab characters have a special purpose in
template (.javajet) files. A <tab> represents "1 level of indentation" in the
generated output, and must be used (instead of spaces) on lines that represent
output text. For example, your patch includes the following:
- changeContext =
basicUnset<%=genFeature.getAccessorName()%>(changeContext);
+ changeContext =
basicUnset<%=genFeature.getAccessorName()%>(changeContext);
Notice that the line used to be
<tab><tab><tab>changeContext = ...
which indicated it was to be indented 3 levels. If tabs are 4 spaces, that will
be 12 spaces of indentation.
You changed it to:
<space><space><space><space><tab>changeContext =
which indicates 4 spaces + 1 level of indentations. That's 8 spaces total if
tabs are 4 spaces.
To produce properly indented output code, you need to be sure to use tab
characters properly in the template. If you browse through the entire template
file, you'll see that tabs are used on every output line.
> For some schemas, the code generated will not compile (notication and
> settable problems)
> ----------------------------------------------------------------------------------------
>
> Key: TUSCANY-1050
> URL: https://issues.apache.org/jira/browse/TUSCANY-1050
> Project: Tuscany
> Issue Type: Bug
> Components: Java SDO Tools
> Affects Versions: Java-M3, Java-Mx
> Environment: n/a
> Reporter: David T. Adcox
> Attachments: TUSCANY1050.patch, TUSCANY1050.xsd
>
>
> Using the attached, test schema, the code generated with xsd2JavaGenerator
> will not compile. There still seems to be some EMF code being pulled into
> the generated class files.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]