[prev in list] [next in list] [prev in thread] [next in thread] 

List:       turbine-torque-dev
Subject:    [jira] Created: (TORQUE-76) broken combatibility to 3.2:
From:       Ronny_Völker_(JIRA) <jira () apache ! org>
Date:       2007-01-12 16:25:27
Message-ID: 7711775.1168619127862.JavaMail.jira () brutus
[Download RAW message or body]

broken combatibility to 3.2: incompatible types error when compiling BasePeer classes
-------------------------------------------------------------------------------------

                 Key: TORQUE-76
                 URL: https://issues.apache.org/jira/browse/TORQUE-76
             Project: Torque
          Issue Type: Bug
          Components: Generator
    Affects Versions: 3.3-RC1
            Reporter: Ronny Völker
             Fix For: 3.3, 4.0


When compiling Scarab with Torque3.3rc1 lots of incompatible types error are \
returned. When compiling with Torque3.2 everything is compiled successfully.

The root cause are changes of torque/templates/trunk/src/templates/om/Peer.vm in \
r373352. In this revisions some class casts have been removed which seem to be \
required in BasePeer classes, if inheritance and interfaces are used in the schema \
mapping.

Sample compilation output:
    [javac] C:\elaxy\svn\scarab_trunk\src\java\org\tigris\scarab\om\BaseIssuePeer.java:933: \
incompatible types  [javac] found   : org.tigris.scarab.om.Module
    [javac] required: org.tigris.scarab.om.ScarabModule
    [javac]                 ScarabModule temp_obj2 = temp_obj1.getModule();
    
The buggy line using Torque3.3rc1 templates:
Issue temp_obj1 = (Issue) results.get(j);
ScarabModule temp_obj2 = temp_obj1.getModule();

The sameline using Torque3.2 templates:
Issue temp_obj1 = (Issue) results.get(j);
ScarabModule temp_obj2 = (ScarabModule)temp_obj1.getModule();

The interface of Issue.getModule() (inherited from BaseIssue):
    public Module getModule()

The related sections in the schema.xml of Scarab:
<table name="SCARAB_MODULE" idMethod="idbroker" javaName="ScarabModule" 
    baseClass="org.tigris.scarab.om.AbstractScarabModule"
    interface="Module">
...
    
<table name="SCARAB_ISSUE" idMethod="idbroker" javaName="Issue">
...
    <column name="MODULE_ID" required="true" type="INTEGER"></column>

    <foreign-key foreignTable="SCARAB_MODULE">
        <reference local="MODULE_ID" foreign="MODULE_ID"/>
    </foreign-key>
...


-- 
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: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic