package test;
import thewebsemantic.Id;
public class KeepItSimple {
@Id
private String id;
private int value;
public int getValue() {return value;}
public void setValue(int i) {value = i;}
public String getId() {return id;}
public void setId(String id) {this.id = id;}
}
@prefix : <http://test.bean/> .
<http://thewebsemantic.com/javaclass>
a owl:AnnotationProperty .
<http://test.bean/KeepItSimple/kisv1.1>
a :KeepItSimple ;
:id "kisv1.1"^^xsd:string ;
:value "444"^^xsd:int .
:KeepItSimple
a rdfs:Class ;
<http://thewebsemantic.com/javaclass>
"test.bean.KeepItSimple" .
:id a rdf:Property .
:value
a rdf:Property .
You cannot remove the class position entirely at the moment. That
would cause the id to loose it's context and open the possibility of
having two things with the same URI. There is a way to override the
default of using the class name.
@RdfType overrides the default behavior
@RdfType("different")
public class Foo...
Would then be:
http://.../different/id
Can you suggest some ways of specifying that the URI not include the
class part...maybe
RdfType(blank=true) or something like that? If we can arrive at good
semantics for indicating that situation it shouldn't be too hard to
code that.
Taylor
> --
> You received this message because you are subscribed to the Google Groups "jenabean-dev" group.
> To post to this group, send email to jenabe...@googlegroups.com.
> To unsubscribe from this group, send email to jenabean-dev...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/jenabean-dev?hl=en.
>
>
I think something like this might work:
@RdfType("TypeName",includeInInstance=false)
Another Idea would be to provide templating for instances, for
example:
${namspace}${RdfType}/${id}
Thanks for your help,
Brandon