owl>shacl for oneof?

15 views
Skip to first unread message

Bohms, H.M. (Michel)

unread,
Jul 19, 2021, 8:08:44 AM7/19/21
to topbrai...@googlegroups.com

In owl I have:

 

nen2660:AggregationStateType

  a owl:Class ;

  owl:oneOf (

      nen2660:Solid

      nen2660:Fluid

      nen2660:Gas

      nen2660:Plasma

    ) ;

.

 

What would be the shacl variant here?:

 

I had:

 

nen2660:AggregationStateType

  a sh:NodeShape ;

  sh:property [

      sh:path nen2660:aggregationStateType ;

      sh:in (

          nen2660:Solid

          nen2660:Fluid

          nen2660:Gas

          nen2660:Plasma

        ) ;

    ] ;

.

 

But guess that should be simpler like:

 

nen2660:AggregationStateType

  a sh:NodeShape ;

      sh:in (

          nen2660:Solid

          nen2660:Fluid

          nen2660:Gas

          nen2660:Plasma

        ) ;

.

Is that allowed?

 

 

 

 

 

Dr. ir. H.M. (Michel) Bohms
Scientist Specialist
Structural Reliability

T +31 (0)88 866 31 07
M +31 (0)63 038 12 20
michel...@tno.nl

Location

 

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.

 

David Price

unread,
Jul 19, 2021, 9:52:59 AM7/19/21
to topbrai...@googlegroups.com
If you have nen2660:Solid rdf:type nen2660:AggregationStateType, etc set then it does not appear to matter, both seem to work in Composer and in EDG.

I guess any preference depends on if the oneOf is only ever used by one property or not.

FWIW I’ve seen the property shape variant used more often than the node shape.

Also, IMO it is bad practice to name a property/path URI the same as a class except for case. The concern is that there are many implementation languages that are not case-sensitive and doing so can make developers life harder.

Cheers,
David

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. 
 

-- 
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/a8cfb755bb7b494a9a09ec231a6b30b8%40tno.nl.


Reply all
Reply to author
Forward
0 new messages