Hi,
Thank you very much for your response I have been away for a few days so apologies for the late reply.

Jürgen Hoffmann wrote:
Hi Tom,

just a few days ago I had a similar error. Look at the thread "too generic 
object..." from last week.
It was a problem with the schema. All that follows is speculative but might 
help:

In the schema where you define the DataGroup there might be several namespace 
references in the <xs: schema> Tag.
One of them looks like xmlns:opengis="http://opengis.net/swe";
The "opengis" String will be different I just choose it here.

I am currently working with the schema file commonProperties.xsd, it has references to "DataGroup" as follows;

<xs:element name="Limits" substitutionGroup="swe:_DataGroup">
<xs:element name="PhysicalProperties" substitutionGroup="swe:_DataGroup">
<xs:element name="MeasurementCapabilities" substitutionGroup="swe:_DataGroup">

commonProperties.xsd starts with:
<xs:schema targetNamespace="http://www.opengis.net/sensorML"; xmlns:xs="http://www.w3.org/2001/XMLSchema"; xmlns:swe="http://www.opengis.net/swe"; xmlns:sml="http://www.opengis.net/sensorML"; xmlns:ism="urn:us:gov:ic:ism:v2" elementFormDefault="qualified" attributeFormDefault="unqualified">


commonProperties.xsd uses paramaters.xsd:

Loading schema file commonProperties.xsd
Loading referenced file sweImports.xsd
Loading referenced file file:/C:/PROGRA~1/UCB/cygwin/home/Tom%20Kobialka/SensorML_Schema/sweCommon/1.0.30/parameters.xsd

"DataGroup" is defined in the schema parameters.xsd as follows:
<xs:element name="_DataGroup" type="swe:_GroupBaseType" abstract="true"/>
<xs:element name="_DataArray" type="swe:_ArrayBaseType" abstract="true"/>

This schema starts with:
<xs:schema targetNamespace="http://www.opengis.net/swe"; xmlns:xlink="http://www.w3.org/1999/xlink"; xmlns:xs="http://www.w3.org/2001/XMLSchema"; xmlns:swe="http://www.opengis.net/swe"; elementFormDefault="qualified" attributeFormDefault="unqualified">

I run scomp with the following flags:

scomp -dl -out commonProperties.jar commonProperties.xsd
And now comes the trick: Please check the definition of the DataGroup in the 
schema.
There should be something like type="gbt:GroupBaseType"
As you can see from the above this already seems to occur. Have I missed something? I appreciate your help.

Cheers

Tom

Cheers,

Jürgen


-----Ursprüngliche Nachricht-----
Von: [email protected]
Gesendet: 12.04.06 09:01:05
An: [email protected]
Betreff: scomp error


Hi,

I'm experiencing difficulty in getting some schema's, provided to my by a third party, processed in scomp. My error is appended to the end of this email. My question is, is this a problem with the schema's or with scomp?

Cheers
Tom

$ scomp -dl -out commonProperties.jar commonProperties.xsd
Time to build schema type system: 2.188 seconds
Time to generate code: 5.218 seconds
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\DataGroupDocument2.java:34: addNewDataGroup() in net.opengis.swe.DataGroupDocument2 clashes with addNewDataGroup() in net.opengis.swe.DataGroupDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataGroupDocument2.DataGroup
required: net.opengis.swe.GroupBaseType
    net.opengis.swe.DataGroupDocument2.DataGroup addNewDataGroup();
                                                 ^
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\DataGroupDocument2.java:24: getDataGroup() in net.opengis.swe.DataGroupDocument2 clashes with getDataGroup() in net.opengis.swe.DataGroupDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataGroupDocument2.DataGroup
required: net.opengis.swe.GroupBaseType
    net.opengis.swe.DataGroupDocument2.DataGroup getDataGroup();
                                                 ^
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\impl\DataGroupDocument2Impl.java:66: addNewDataGroup() in net.opengis.swe.impl.DataGroupDocument2Impl cannot implement addNewDataGroup() in net.opengis.swe.DataGroupDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataGroupDocument2.DataGroup
required: net.opengis.swe.GroupBaseType
    public net.opengis.swe.DataGroupDocument2.DataGroup addNewDataGroup()
                                                        ^
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\impl\DataGroupDocument2Impl.java:30: getDataGroup() in net.opengis.swe.impl.DataGroupDocument2Impl cannot implement getDataGroup() in net.opengis.swe.DataGroupDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataGroupDocument2.DataGroup
required: net.opengis.swe.GroupBaseType
    public net.opengis.swe.DataGroupDocument2.DataGroup getDataGroup()
                                                        ^
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\DataArrayDocument2.java:34: addNewDataArray1() in net.opengis.swe.DataArrayDocument2 clashes with addNewDataArray1() in net.opengis.swe.DataArrayDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataArrayDocument2.DataArray
required: net.opengis.swe.ArrayBaseType
    net.opengis.swe.DataArrayDocument2.DataArray addNewDataArray1();
                                                 ^
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\DataArrayDocument2.java:24: getDataArray1() in net.opengis.swe.DataArrayDocument2 clashes with getDataArray1() in net.opengis.swe.DataArrayDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataArrayDocument2.DataArray
required: net.opengis.swe.ArrayBaseType
    net.opengis.swe.DataArrayDocument2.DataArray getDataArray1();
                                                 ^
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\impl\DataArrayDocument2Impl.java:66: addNewDataArray1() in net.opengis.swe.impl.DataArrayDocument2Impl cannot implement addNewDataArray1() in net.opengis.swe.DataArrayDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataArrayDocument2.DataArray
required: net.opengis.swe.ArrayBaseType
    public net.opengis.swe.DataArrayDocument2.DataArray addNewDataArray1()
                                                        ^
c:\DOCUME~1\TOMKOB~1\LOCALS~1\Temp\xbean38967.d\src\net\opengis\swe\impl\DataArrayDocument2Impl.java:30: getDataArray1() in net.opengis.swe.impl.DataArrayDocument2Impl cannot implement getDataArray1() in net.opengis.swe.DataArrayDocument; attempting to use incompatible return type
found   : net.opengis.swe.DataArrayDocument2.DataArray
required: net.opengis.swe.ArrayBaseType
    public net.opengis.swe.DataArrayDocument2.DataArray getDataArray1()
                                                        ^
Note: Some input files use or override a deprecated API.
Note: Recompile with -deprecation for details.
8 errors

BUILD FAILED


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



_______________________________________________________________
SMS schreiben mit WEB.DE FreeMail - einfach, schnell und
kostenguenstig. Jetzt gleich testen! http://f.web.de/?mc=021192


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to