You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by Jeremy Boynes <jb...@apache.org> on 2006/01/17 21:18:27 UTC

SDO without XML?

I am writing some unit tests which use SDO and would like to create
instances of my interfaces without having to mess with XML or schemas.
Is it possible to configure the DataFactory to create instances of an
interface based purely on definitions in the interface class itself?

I was looking to do something like:
setup() {
    JavaHelper.define(MyInterface.class);
}
testFoo() {
    MyInterface foo = dataFactory.create(MyInterface.class);
}

Thanks
--
Jeremy

Re: SDO without XML?

Posted by Edward Slattery <ed...@googlemail.com>.
I would like to be included in that bit of design when it happens. The C++
implementation of the DataFactory has addType(uri,name, several bools) and
addPropertyToType(typeuri, typename,
name, propuri, propname, several bools), so the factory can be used to
define the types and
properties. It would be good if the two could converge.

regards,
ed.


On 17/01/06, Frank Budinsky <fr...@ca.ibm.com> wrote:
>
> Defining an SDO model using annotated Java interfaces is something that
> SDO intends to allow in the future, but currently (in version 2) it isn't
> defined in the spec.
>
> We'd like to start to add this kind of support in the Tuscany impl, but it
> would be forging new ground - we'd need to work with the SDO spec people
> to make sure that we're doing it in a way consistent with future versions
> of the spec.
>
> Currently, you need to define your SDO metamodel using XML Schema.
>
> Frank.
>
>
>
>
> Jeremy Boynes <jb...@apache.org>
> 01/17/2006 03:18 PM
> Please respond to
> tuscany-dev
>
>
> To
> tuscany-dev@ws.apache.org
> cc
>
> Subject
> SDO without XML?
>
>
>
>
>
>
> I am writing some unit tests which use SDO and would like to create
> instances of my interfaces without having to mess with XML or schemas.
> Is it possible to configure the DataFactory to create instances of an
> interface based purely on definitions in the interface class itself?
>
> I was looking to do something like:
> setup() {
>    JavaHelper.define(MyInterface.class);
> }
> testFoo() {
>    MyInterface foo = dataFactory.create(MyInterface.class);
> }
>
> Thanks
> --
> Jeremy
>
>
>

Re: SDO without XML?

Posted by Raymond Feng <en...@gmail.com>.
I guess you can also model the data in UML and use the EMF tooling to
generate the SDO interfaces/classes.

Raymond

----- Original Message ----- 
From: "Frank Budinsky" <fr...@ca.ibm.com>
To: <tu...@ws.apache.org>
Sent: Tuesday, January 17, 2006 12:41 PM
Subject: Re: SDO without XML?


> Defining an SDO model using annotated Java interfaces is something that
> SDO intends to allow in the future, but currently (in version 2) it isn't
> defined in the spec.
>
> We'd like to start to add this kind of support in the Tuscany impl, but it
> would be forging new ground - we'd need to work with the SDO spec people
> to make sure that we're doing it in a way consistent with future versions
> of the spec.
>
> Currently, you need to define your SDO metamodel using XML Schema.
>
> Frank.
>
>
>
>
> Jeremy Boynes <jb...@apache.org>
> 01/17/2006 03:18 PM
> Please respond to
> tuscany-dev
>
>
> To
> tuscany-dev@ws.apache.org
> cc
>
> Subject
> SDO without XML?
>
>
>
>
>
>
> I am writing some unit tests which use SDO and would like to create
> instances of my interfaces without having to mess with XML or schemas.
> Is it possible to configure the DataFactory to create instances of an
> interface based purely on definitions in the interface class itself?
>
> I was looking to do something like:
> setup() {
>     JavaHelper.define(MyInterface.class);
> }
> testFoo() {
>     MyInterface foo = dataFactory.create(MyInterface.class);
> }
>
> Thanks
> --
> Jeremy
>
>


Re: SDO without XML?

Posted by Frank Budinsky <fr...@ca.ibm.com>.
Defining an SDO model using annotated Java interfaces is something that 
SDO intends to allow in the future, but currently (in version 2) it isn't 
defined in the spec.

We'd like to start to add this kind of support in the Tuscany impl, but it 
would be forging new ground - we'd need to work with the SDO spec people 
to make sure that we're doing it in a way consistent with future versions 
of the spec. 

Currently, you need to define your SDO metamodel using XML Schema.

Frank.




Jeremy Boynes <jb...@apache.org> 
01/17/2006 03:18 PM
Please respond to
tuscany-dev


To
tuscany-dev@ws.apache.org
cc

Subject
SDO without XML?






I am writing some unit tests which use SDO and would like to create
instances of my interfaces without having to mess with XML or schemas.
Is it possible to configure the DataFactory to create instances of an
interface based purely on definitions in the interface class itself?

I was looking to do something like:
setup() {
    JavaHelper.define(MyInterface.class);
}
testFoo() {
    MyInterface foo = dataFactory.create(MyInterface.class);
}

Thanks
--
Jeremy