List Info

Thread: Construct of classes




Construct of classes
country flaguser name
Austria
2007-10-18 12:02:00
Hello,

i have this file (data+schema):
http://pastie.textmate.org/private/j0yyyh2yjastm7hdlaewg


I execute the following ruby-code:
adapter = ConnectionPool.add_data_source(:type =>
:redland,:location  
=> "./__db.rb",:want_new => true)
adapter.load "./rxml.nt","rdfxml"
Namespace.register(:test, 'http://www.As
sgiment1.com/schemas/lvas#')
classes = ObjectManager.construct_classes
puts classes.inspect
puts classes.first.find_all.length
puts TEST::lva.find_all.length


and the output is:
[<file:./rxml.nt#lva>]
0
NoMethodError: undefined method ‘length’ for nil:NilClass

Why is that? Is it a bug in Activerdf?
On another note: would it be even possible with activerdf to
resolve  
bags like i have it in my rdf-structure?

thanks in advance
Thomas_______________________________________________
ActiveRDF mailing list
ActiveRDFlists.deri.org
http
://lists.deri.org/mailman/listinfo/activerdf

Re: Construct of classes
country flaguser name
France
2007-10-18 13:48:53
thomas kern a écrit :
> Hello,
>
> i have this file (data+schema):
> http://pastie.textmate.org/private/j0yyyh2yjastm7hdlaewg

Try with:

xml:base="http://
www.Assgiment1.com/schemas/lvas#"

>
> I execute the following ruby-code:
> adapter = ConnectionPool.add_data_source(:type =>
:redland,:location 
> => "./__db.rb",:want_new => true)
> adapter.load "./rxml.nt","rdfxml"
> Namespace.register(:test, 'http://www.As
sgiment1.com/schemas/lvas#')
> classes = ObjectManager.construct_classes
> puts classes.inspect
> puts classes.first.find_all.length
> puts TEST::lva.find_all.length
>
>
> and the output is:
> [<file:./rxml.nt#lva>]
> 0
> NoMethodError: undefined method ‘length’ for
nil:NilClass
>
> Why is that? Is it a bug in Activerdf?
> On another note: would it be even possible with
activerdf to resolve 
> bags like i have it in my rdf-structure?
>
> thanks in advance
> Thomas_______________________________________________
> ActiveRDF mailing list
> ActiveRDFlists.deri.org
> http
://lists.deri.org/mailman/listinfo/activerdf
_______________________________________________
ActiveRDF mailing list
ActiveRDFlists.deri.org
http
://lists.deri.org/mailman/listinfo/activerdf

Re: Construct of classes
country flaguser name
Austria
2007-10-18 14:46:04
Thank you that works.

but it seems that activerdf has the same problem with the
bags than i  
have manually.
how can i access the bags/collections ?

thank you
Thomas

Am 18.10.2007 um 20:48 schrieb Yoan BLANC:

> thomas kern a écrit :
>> Hello,
>>
>> i have this file (data+schema):
>> http://pastie.textmate.org/private/j0yyyh2yjastm7hdlaewg

> Try with:
>
> xml:base="http://
www.Assgiment1.com/schemas/lvas#"
>
>>
>> I execute the following ruby-code:
>> adapter = ConnectionPool.add_data_source(:type  
>> => :redland,:location =>
"./__db.rb",:want_new => true)
>> adapter.load
"./rxml.nt","rdfxml"
>> Namespace.register(:test, 'http://www.As
sgiment1.com/schemas/lvas#')
>> classes = ObjectManager.construct_classes
>> puts classes.inspect
>> puts classes.first.find_all.length
>> puts TEST::lva.find_all.length
>>
>>
>> and the output is:
>> [<file:./rxml.nt#lva>]
>> 0
>> NoMethodError: undefined method ‘length’ for
nil:NilClass
>>
>> Why is that? Is it a bug in Activerdf?
>> On another note: would it be even possible with
activerdf to  
>> resolve bags like i have it in my rdf-structure?
>>
>> thanks in advance
>>
Thomas_______________________________________________
>> ActiveRDF mailing list
>> ActiveRDFlists.deri.org
>> http
://lists.deri.org/mailman/listinfo/activerdf
> _______________________________________________
> ActiveRDF mailing list
> ActiveRDFlists.deri.org
> http
://lists.deri.org/mailman/listinfo/activerdf
_______________________________________________
ActiveRDF mailing list
ActiveRDFlists.deri.org
http
://lists.deri.org/mailman/listinfo/activerdf

Re: Construct of classes
user name
2007-10-19 04:56:48
On 10/18/07/10/07 21:46 +0200, thomas kern wrote:
> Thank you that works.
>
> but it seems that activerdf has the same problem with
the bags than i 
> have manually. how can i access the bags/collections ?
Sorry, ActiveRDF does not handle collections (yet). I'm open
to patches 
though.

  -eyal
_______________________________________________
ActiveRDF mailing list
ActiveRDFlists.deri.org
http
://lists.deri.org/mailman/listinfo/activerdf

Re: Construct of classes
country flaguser name
Austria
2007-10-19 09:55:02
Am 19.10.2007 um 11:56 schrieb Eyal Oren:

> On 10/18/07/10/07 21:46 +0200, thomas kern wrote:
>> Thank you that works.
>>
>> but it seems that activerdf has the same problem
with the bags  
>> than i have manually. how can i access the
bags/collections ?
> Sorry, ActiveRDF does not handle collections (yet). I'm
open to  
> patches though.

thank you for your answer and I changed my structure so i
dont have  
collections, no patches from me ...

-thomas
_______________________________________________
ActiveRDF mailing list
ActiveRDFlists.deri.org
http
://lists.deri.org/mailman/listinfo/activerdf

[1-5]

about | contact  Other archives ( Real Estate discussion Medical topics )