prefix issue ...

42 views
Skip to first unread message

Bohms, H.M. (Michel)

unread,
Aug 5, 2020, 2:36:43 PM8/5/20
to topbrai...@googlegroups.com

My code:

 

# baseURI: https://w3id.org/def/crb

# imports: https://w3id.org/def/smls-shacl

# prefix: crb

 

@prefix crb: <https://w3id.org/def/crb#> .

@prefix dash: <http://datashapes.org/dash#> .

@prefix ifc: <http://www.buildingsmart.com/def/ifc#> .

@prefix owl: <http://www.w3.org/2002/07/owl#> .

@prefix quantitykind: <http://qudt.org/vocab/quantitykind/> .

@prefix qudt: <http://qudt.org/schema/qudt/> .

@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

@prefix sh: <http://www.w3.org/ns/shacl#> .

@prefix skos: <http://www.w3.org/2004/02/skos/core#> .

@prefix smls-shacl: <https://w3id.org/def/smls-shacl#> .

@prefix unit: <http://qudt.org/vocab/unit/> .

@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

 

ifc:IfcDoor

  a rdfs:Class ;

.

ifc:Pset_DoorCommon

  a rdfs:Container ;

  rdfs:member ifc:isExternal ;

.

ifc:isExternal

  a rdf:Property ;

  rdfs:domain ifc:IfcDoor ;

  rdfs:range xsd:boolean ;

.

<https://w3id.org/def/crb>

  a owl:Ontology ;

  owl:imports <https://w3id.org/def/smls-shacl> ;

.

crb:Door

  a rdfs:Class ;

  rdfs:subClassOf smls-shacl:PhysicalObject ;

.

crb:E3.1

  a crb:EBKP_HType ;

.

crb:E3.2

  a crb:EBKP_HType ;

.

crb:E3.3

  a crb:EBKP_HType ;

.

crb:EBKP_HType

  a rdfs:Class ;

.

crb:ExteriorDoor

  a rdfs:Class ;

  rdfs:subClassOf crb:Door ;

.

crb:ExteriorDoorShape

  a sh:NodeShape ;

  sh:property [

      a sh:PropertyShape ;

      sh:path ifc:eBKP_H ;

      sh:hasValue crb:E3.1 ;

    ] ;

  sh:property [

      a sh:PropertyShape ;

      sh:path ifc:isExternal ;

      sh:hasValue true ;

    ] ;

  sh:property [

      a sh:PropertyShape ;

      sh:path (

          crb:crb_Measure_Pressure_kn_m2

          rdf:value

        ) ;

      sh:datatype xsd:decimal ;

      sh:minInclusive 0.8 ;

    ] ;

  sh:targetClass crb:ExteriorDoor ;

.

crb:ProductX

  a ifc:IfcDoor ;

  a crb:ExteriorDoor ;

  ifc:isExternal true ;

  crb:crb_Measure_Pressure_kn_m2 [

      rdf:value 0.5 ;

    ] ;

  crb:eBKP_H <https://w3id.org/def/crb#E3.1> ;

.

crb:crb_Measure_Pressure_kn_m2

  a rdf:Property ;

  smls-shacl:unit unit:KiloPA ;

.

crb:eBKP_H

  a rdf:Property ;

  rdfs:range crb:EBKP_HType ;

.

 

Is changed by tbc to:

 

# baseURI: https://w3id.org/def/crb

# imports: https://w3id.org/def/smls-shacl

# prefix: crb

 

@prefix crb: <https://w3id.org/def/crb#> .

@prefix dash: <http://datashapes.org/dash#> .

@prefix ifc: <http://www.buildingsmart.com/def/ifc#> .

@prefix owl: <http://www.w3.org/2002/07/owl#> .

@prefix quantitykind: <http://qudt.org/vocab/quantitykind/> .

@prefix qudt: <http://qudt.org/schema/qudt/> .

@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

@prefix sh: <http://www.w3.org/ns/shacl#> .

@prefix skos: <http://www.w3.org/2004/02/skos/core#> .

@prefix smls-shacl: <https://w3id.org/def/smls-shacl#> .

@prefix unit: <http://qudt.org/vocab/unit/> .

@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

 

ifc:IfcDoor

  a rdfs:Class ;

.

ifc:Pset_DoorCommon

  a rdfs:Container ;

  rdfs:member ifc:isExternal ;

.

ifc:isExternal

  a rdf:Property ;

  rdfs:domain ifc:IfcDoor ;

  rdfs:range xsd:boolean ;

.

<https://w3id.org/def/crb>

  a owl:Ontology ;

  owl:imports <https://w3id.org/def/smls-shacl> ;

.

crb:Door

  a rdfs:Class ;

  rdfs:subClassOf smls-shacl:PhysicalObject ;

.

<https://w3id.org/def/crb#E3.1>

  a crb:EBKP_HType ;

.

<https://w3id.org/def/crb#E3.2>

  a crb:EBKP_HType ;

.

<https://w3id.org/def/crb#E3.3>

  a crb:EBKP_HType ;

.

crb:EBKP_HType

  a rdfs:Class ;

.

crb:ExteriorDoor

  a rdfs:Class ;

  rdfs:subClassOf crb:Door ;

.

crb:ExteriorDoorShape

  a sh:NodeShape ;

  sh:property [

      a sh:PropertyShape ;

      sh:path ifc:eBKP_H ;

      sh:hasValue <https://w3id.org/def/crb#E3.1> ;

    ] ;

  sh:property [

      a sh:PropertyShape ;

      sh:path ifc:isExternal ;

      sh:hasValue true ;

    ] ;

  sh:property [

      a sh:PropertyShape ;

      sh:path (

          crb:crb_Measure_Pressure_kn_m2

          rdf:value

        ) ;

      sh:datatype xsd:decimal ;

      sh:minInclusive 0.8 ;

    ] ;

  sh:targetClass crb:ExteriorDoor ;

.

crb:ProductX

  a ifc:IfcDoor ;

  a crb:ExteriorDoor ;

  ifc:isExternal true ;

  crb:crb_Measure_Pressure_kn_m2 [

      rdf:value 0.5 ;

    ] ;

  crb:eBKP_H <https://w3id.org/def/crb#E3.1> ;

.

crb:crb_Measure_Pressure_kn_m2

  a rdf:Property ;

  smls-shacl:unit unit:KiloPA ;

.

crb:eBKP_H

  a rdf:Property ;

  rdfs:range crb:EBKP_HType ;

.

 

Why is that? Is a dot not allowed?

 

Thx Michel

 

 

 

This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. TNO accepts no liability for the content of this e-mail, for the manner in which you use it and for damage of any kind resulting from the risks inherent to the electronic transmission of messages.

Holger Knublauch

unread,
Aug 5, 2020, 8:48:51 PM8/5/20
to topbrai...@googlegroups.com

We are using the Jena API, so you may want to follow up on the jena-users mailing list on this question. But yes, it does not use prefixes if the local name contains the . character for me too.

Holger

--
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to topbraid-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/ce1992f3b58f4128afe508b149eaf8d3%40tno.nl.

Bohms, H.M. (Michel)

unread,
Aug 6, 2020, 4:52:24 AM8/6/20
to topbrai...@googlegroups.com
Ok thx
Will replace dots by dashes in the ex.

Op 6 aug. 2020 02:48 schreef Holger Knublauch <hol...@topquadrant.com>:

an...@seaborne.org

unread,
Aug 6, 2020, 10:56:03 AM8/6/20
to TopBraid Suite Users
Apache Jena outputs localname with DOT in it (when legal - it can't be last)

Input:


<https://w3id.org/def/crb#E3.2>
  a crb:EBKP_HType ;
.


riot --output TTL D.ttl

@prefix crb:  <https://w3id.org/def/crb#> .
@prefix rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

crb:E3.2  rdf:type  crb:EBKP_HType .


    Andy

Bohms, H.M. (Michel)

unread,
Aug 7, 2020, 5:56:08 AM8/7/20
to topbrai...@googlegroups.com, Davis Kantor

Hi Andy

 

So what does this mean for my example?

I actually put in the second form and get the first in tbc…

 

Could it be a jena version used issue?

 

Thx michel

an...@seaborne.org

unread,
Aug 8, 2020, 4:53:25 AM8/8/20
to TopBraid Suite Users
Hi Michel,

That output is from TBC's own Turtle writer, not from Jena at all.
The TBC writer is forked and modified code from an old Jena2 N3/Turtle writer that Jena no longer uses.

    Andy

Bohms, H.M. (Michel)

unread,
Aug 8, 2020, 6:42:07 AM8/8/20
to topbrai...@googlegroups.com
Ahhh ok so indeed a version issue
Well maybe a future update might resolve this then...holger?

Op 8 aug. 2020 10:53 schreef "an...@seaborne.org" <an...@seaborne.org>:

Holger Knublauch

unread,
Aug 16, 2020, 7:23:25 PM8/16/20
to topbrai...@googlegroups.com

Yes we did fork the TTL writer many years ago, as part of producing sorted/diff-friendly output. This explains the difference in behaviour. I have recorded an internal development ticket (TBS-3212) to address this for a future release.

Holger

Reply all
Reply to author
Forward
0 new messages