@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix dsd: <https://w3id.org/dsd#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix xml: <http://www.w3.org/XML/1998/namespace> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix adms: <http://www.w3.org/ns/adms#> .
@prefix foaf: <http://xmlns.com/foaf/0.1/> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix vann: <http://purl.org/vocab/vann/> .
@prefix void: <http://rdfs.org/ns/void#> .
@prefix schema: <http://schema.org/> .
@prefix dcterms: <http://purl.org/dc/terms/> .

<https://w3id.org/dsd>
    dcterms:contributor [
        a foaf:Person ;
        foaf:homepage <https://orcid.org/0000-0003-2689-0876> ;
        foaf:mbox <mailto:johannes.schrott@jku.at> ;
        foaf:name "Johannes Schrott"
    ] ;
    dcterms:created "2015-09-17" ;
    dcterms:creator [
        a foaf:Person ;
        foaf:homepage <https://orcid.org/0000-0001-5313-0368> ;
        foaf:mbox <mailto:lisa.ehrlinger@scch.at> ;
        foaf:name "Lisa Ehrlinger"
    ] ;
    dcterms:description "The Data Source Description Vocabulary (DSD) allows the representation of data sources and their internal structure independently of their type. The figure below provides an overview on OWL classes and object properties present in the vocabulary. For simplicity, inverse object properties and some subclasses are not shown. Additionally, a distinction between \"essential\" OWL classes, that are required for the description of data sources, and \"optional\" classes, which provide additional non-necessary features, is being made.<br><img src=\"https://dqm.faw.jku.at/ontologies/dsd/4.0.0/DSD4.png\" style=\"width: calc(100%); max-width: 1000px\">" ;
    dcterms:issued "2023-03-06"^^xsd:date ;
    dcterms:license <https://w3id.org/dsd/LICENSE>, "LGPL-2.1 license" ;
    dcterms:modified "2023-03-06" ;
    dcterms:publisher [
        a foaf:Organization ;
        foaf:homepage "https://www.jku.at/faw" ;
        foaf:name "Institute for Application-oriented Knowledge Processeing, Johannes Kepler University Linz, Austria"
    ] ;
    dcterms:title "The Data Source Description Vocabulary" ;
    vann:preferredNamespacePrefix "dsd" ;
    vann:preferredNamespaceUri "https://w3id.org/dsd#" ;
    schema:citation "Cite this vocabulary as: Ehrlinger, L. The Data Source Description vocabulary 4.0.0."@en ;
    a owl:Ontology ;
    owl:versionIRI <https://w3id.org/dsd/4.0.0> ;
    owl:versionInfo "4.0.0" ;
    foaf:depiction <https://dqm.faw.jku.at/ontologies/dsd/4.0.0/DSD4.png> .

dsd:AggregationAssociation
    a owl:Class ;
    rdfs:comment "Describes the relationship between an aggregation that is composed out of several components."@en ;
    rdfs:isDefinedBy dsd:AggregationAssociation ;
    rdfs:label "Aggregation association"@en ;
    rdfs:subClassOf dsd:Association .

dsd:Association
    a owl:Class ;
    rdfs:comment "An Association describes a relationship between two instances of the class Concept. There are three disjoint subclasses of Association for Aggregation, Inheritance, and Reference."@en ;
    rdfs:isDefinedBy dsd:Association ;
    rdfs:label "Association"@en .

dsd:Attribute
    a owl:Class ;
    rdfs:comment """An Attribute describes a property of a Concept. DSD also provides OWL data properties for the description of certain attribute characteristics, such as, nullable or unique.
Example:  If a Concept represents a relational table, its attributes correspond to the columns."""@en ;
    rdfs:isDefinedBy dsd:Attribute ;
    rdfs:label "Attribute"@en .

dsd:CSV_File
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:Completeness
    a owl:NamedIndividual .

dsd:Concept
    a owl:Class ;
    rdfs:comment """A representation of a strutural part of a Data Source.
Example: Corresponds to a table or a view from a relational database; a class in object-oriented structures."""@en ;
    rdfs:isDefinedBy dsd:Concept ;
    rdfs:label "Concept"@en ;
    owl:hasKey (dsd:hasPrimaryKey
    ) .

dsd:Correctness
    a owl:NamedIndividual .

dsd:Datasource
    a owl:Class ;
    rdfs:comment """A generic class for representing data sources.
Example: An instance of this class can represent a data source, e.g., a relational information system, a comma separated list, semi-structured text files or a graph. Optionally, an object property referencing an instance of Data Source Type may be present."""@en ;
    rdfs:isDefinedBy dsd:Datasource ;
    rdfs:label "Data source"@en ;
    owl:disjointUnionOf (dsd:AggregationAssociation
        dsd:Attribute
        dsd:Concept
        dsd:ForeignKey
        dsd:InheritanceAssociation
        dsd:PrimaryKey
        dsd:ReferenceAssociation
        dsd:Schema
    ) ;
    owl:disjointWith dsd:DatasourceType .

dsd:DatasourceType
    a owl:Class ;
    rdfs:comment "This class provides instances of the most common data source types. These instances may be referenced from an instance of the class Data Source."@en ;
    rdfs:isDefinedBy dsd:DatasourceType ;
    rdfs:label "Data source type"@en .

dsd:Excel_Sheet
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:ForeignKey
    a owl:Class ;
    rdfs:comment "References to a Primary key and consists of one or more Attributes."@en ;
    rdfs:isDefinedBy dsd:ForeignKey ;
    rdfs:label "Foreign key"@en .

dsd:InheritanceAssociation
    a owl:Class ;
    rdfs:comment "Describes the relationship between several child Concepts and their parent."@en ;
    rdfs:isDefinedBy dsd:InheritanceAssociation ;
    rdfs:label "Inheritance association"@en ;
    rdfs:subClassOf dsd:Association .

dsd:Minimality
    a owl:NamedIndividual .

dsd:NoSQL_DB
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:OO_DB
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:Pertinence
    a owl:NamedIndividual .

dsd:PlainText
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:PrimaryKey
    a owl:Class ;
    rdfs:comment "Identifies a Concept and consists of one or more Attributes."@en ;
    rdfs:isDefinedBy dsd:PrimaryKey ;
    rdfs:label "Primary key"@en .

dsd:RDF_Store
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:ReferenceAssociation
    a owl:Class ;
    rdfs:comment "Describes a regular relationship between two or more Concepts."@en ;
    rdfs:isDefinedBy dsd:ReferenceAssociation ;
    rdfs:label "Reference association"@en ;
    rdfs:subClassOf dsd:Association .

dsd:Relational_DB
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:Schema
    a owl:Class ;
    rdfs:comment "Instances of the class Schema provide an optional  hierarchy level between an instance of Data Source and instances of Concept. Schemas allow the grouping of Concepts and are very common in enterprise databases."@en ;
    rdfs:label "Schema"@en .

dsd:XML_File
    a owl:NamedIndividual, dsd:DatasourceType .

dsd:avgInstanceLength
    a owl:DatatypeProperty ;
    rdfs:comment "Gives a value of the average (character) length of instances of this concept. E.g., row entries in a MySQL DB."@en ;
    rdfs:isDefinedBy dsd:avgInstanceLength ;
    rdfs:label "Average length of instance"@en ;
    rdfs:subPropertyOf dsd:hasConceptDescriptor .

dsd:consistsOfAttribute
    a owl:ObjectProperty ;
    rdfs:comment "A Primary or Foreign Key consists of one or several Attributes."@en ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:ForeignKey
            dsd:PrimaryKey
        )
    ] ;
    rdfs:isDefinedBy dsd:consistsOfAttribute ;
    rdfs:label "consists of Attributes"@en ;
    rdfs:range dsd:Attribute .

dsd:constraintOnDelete
    a owl:DatatypeProperty ;
    rdfs:comment "Describes the constraint that is defined on a foreign key, which action should be carried out if the referenced primary key is deleted."@en ;
    rdfs:isDefinedBy dsd:constraintOnDelete ;
    rdfs:label "Constraint on Delete"@en ;
    rdfs:range xsd:string ;
    rdfs:subPropertyOf dsd:hasFKDescriptor .

dsd:constraintOnUpdate
    a owl:DatatypeProperty ;
    rdfs:comment "Describes which constraint is defined on a foreign key if the referenced primary key content is updated."@en ;
    rdfs:isDefinedBy dsd:constraintOnUpdate ;
    rdfs:label "Constraint on Update"@en ;
    rdfs:range xsd:string ;
    rdfs:subPropertyOf dsd:hasFKDescriptor .

dsd:defaultValue
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment dsd:defaultValue, "Provides an default value for an attribute."@en ;
    rdfs:label "Default Value"@en ;
    rdfs:range xsd:string ;
    rdfs:subPropertyOf dsd:hasAttributeDescriptor .

dsd:hasAggregation
    a owl:FunctionalProperty, owl:ObjectProperty ;
    rdfs:comment "Describes the connection between an AggregationAssociation and its Aggregation." ;
    rdfs:domain dsd:AggregationAssociation ;
    rdfs:isDefinedBy dsd:hasAggregation ;
    rdfs:label "has Aggregation"@en ;
    rdfs:range dsd:Concept ;
    rdfs:subPropertyOf dsd:hasAssociationMember .

dsd:hasAggregationComponent
    a owl:ObjectProperty ;
    rdfs:comment "Describes the connection between an AggregationAssociation and one of its components." ;
    rdfs:domain dsd:AggregationAssociation ;
    rdfs:isDefinedBy dsd:hasAggregationComponent ;
    rdfs:label "has Aggregation Component" ;
    rdfs:range dsd:Concept ;
    rdfs:subPropertyOf dsd:hasAssociationMember .

dsd:hasAssociationDescriptor
    a owl:DatatypeProperty ;
    rdfs:comment "Provides annotations for an association."@en ;
    rdfs:domain dsd:Association ;
    rdfs:isDefinedBy dsd:hasAssociationDescriptor ;
    rdfs:label "has Association Descriptor"@en .

dsd:hasAssociationMember
    a owl:ObjectProperty ;
    rdfs:comment "Describes the edges from an Association to its Members (Parent, Child, Aggregation, Component)."@en ;
    rdfs:domain dsd:Association ;
    rdfs:isDefinedBy dsd:hasAssociationMember ;
    rdfs:label "has Association Member"@en ;
    rdfs:range dsd:Concept ;
    rdfs:subPropertyOf owl:topObjectProperty .

dsd:hasAttribute
    a owl:ObjectProperty ;
    rdfs:comment "Describes the number of Attributes a Concept or Association comprises."@en ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:Association
            dsd:Concept
        )
    ] ;
    rdfs:isDefinedBy dsd:hasAttribute ;
    rdfs:label "has Attribute"@en ;
    rdfs:range dsd:Attribute ;
    owl:inverseOf dsd:isAttributeOf .

dsd:hasAttributeDescriptor
    a owl:DatatypeProperty ;
    rdfs:comment "Provides annotations for an attribute."@en ;
    rdfs:domain dsd:Attribute ;
    rdfs:isDefinedBy dsd:hasAttributeDescriptor ;
    rdfs:label "has Attribute Descriptor"@en .

dsd:hasChild
    a owl:ObjectProperty ;
    rdfs:comment "Describes the connection between an InheritanceAssociation and one of its childs." ;
    rdfs:domain dsd:InheritanceAssociation ;
    rdfs:isDefinedBy dsd:hasChild ;
    rdfs:label "has Child"@en ;
    rdfs:range dsd:Concept ;
    rdfs:subPropertyOf dsd:hasAssociationMember .

dsd:hasComponent
    a owl:ObjectProperty ;
    rdfs:comment "Describes the number of components a Datasource comprises." ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:Datasource
            dsd:Schema
        )
    ] ;
    rdfs:isDefinedBy dsd:hasComponent ;
    rdfs:label "has Component"@en ;
    rdfs:range [
        a owl:Class ;
        owl:unionOf (dsd:Association
            dsd:Attribute
            dsd:Concept
            dsd:ForeignKey
            dsd:PrimaryKey
        )
    ] ;
    owl:inverseOf dsd:isComponentOf .

dsd:hasConceptDescriptor
    a owl:DatatypeProperty ;
    rdfs:comment "Provides annotations for a concept."@en ;
    rdfs:domain dsd:Concept ;
    rdfs:isDefinedBy dsd:hasConceptDescriptor ;
    rdfs:label "has Concept Descriptor"@en .

dsd:hasFKDescriptor
    a owl:DatatypeProperty ;
    rdfs:comment "Foreign key descriptor: A textual description of what should happen if the reference of this foreign key is modified (updated/deleted)."@en ;
    rdfs:domain dsd:ForeignKey ;
    rdfs:isDefinedBy dsd:hasFKDescriptor ;
    rdfs:label "has Foreign Key Descriptor"@en .

dsd:hasForeignKey
    a owl:ObjectProperty ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:Association
            dsd:Concept
        )
    ] ;
    rdfs:isDefinedBy dsd:hasForeignKey ;
    rdfs:label "has Foreign Key"@en ;
    rdfs:range dsd:ForeignKey .

dsd:hasParent
    a owl:ObjectProperty ;
    rdfs:comment "Describes the connection between an InheritanceAssociation and a parent Concept." ;
    rdfs:domain dsd:InheritanceAssociation ;
    rdfs:isDefinedBy dsd:hasParent ;
    rdfs:label "has Parent" ;
    rdfs:range dsd:Concept ;
    rdfs:subPropertyOf dsd:hasAssociationMember .

dsd:hasPrimaryKey
    a owl:FunctionalProperty, owl:ObjectProperty ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:Association
            dsd:Concept
        )
    ] ;
    rdfs:isDefinedBy dsd:hasPrimaryKey ;
    rdfs:label "has Primary Key"@en ;
    rdfs:range dsd:PrimaryKey .

dsd:hasSchema
    a owl:InverseFunctionalProperty, owl:ObjectProperty ;
    rdfs:domain dsd:Datasource ;
    rdfs:label "has Schema"@en ;
    rdfs:range dsd:Schema ;
    owl:inverseOf dsd:isSchemaOf .

dsd:isAttributeOf
    a owl:ObjectProperty ;
    rdfs:comment "Describes an Attributes's connection to its Concept or Association."@en ;
    rdfs:domain dsd:Attribute ;
    rdfs:isDefinedBy dsd:isAttributeOf ;
    rdfs:label "is Attribute of"@en ;
    rdfs:range [
        a owl:Class ;
        owl:unionOf (dsd:Association
            dsd:Concept
        )
    ] .

dsd:isAutoIncrement
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment dsd:isAutoIncrement, "If the attribute automatically increments on a new insertion of a new value."@en ;
    rdfs:label "automatically increments"@en ;
    rdfs:range xsd:boolean ;
    rdfs:subPropertyOf dsd:hasAttributeDescriptor .

dsd:isComplete
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment "Defines whether an inheritance association is complete. If property is set to FALSE, the association is incomplete."@en ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:AggregationAssociation
            dsd:InheritanceAssociation
        )
    ] ;
    rdfs:isDefinedBy dsd:isComplete ;
    rdfs:label "is Complete"@en ;
    rdfs:range xsd:boolean ;
    rdfs:subPropertyOf dsd:hasAssociationDescriptor .

dsd:isComponentOf
    a owl:ObjectProperty ;
    rdfs:comment "Describes a components connection to its Datasource."@en ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:Association
            dsd:Attribute
            dsd:Concept
            dsd:ForeignKey
            dsd:PrimaryKey
        )
    ] ;
    rdfs:isDefinedBy dsd:isComponentOf ;
    rdfs:label "is Component of"@en ;
    rdfs:range [
        a owl:Class ;
        owl:unionOf (dsd:Datasource
            dsd:Schema
        )
    ] .

dsd:isDisjoint
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment "Describes whether the children of an inheritance association are disjoint. If property is set to FALSE, the children are overlapping."@en ;
    rdfs:domain dsd:AggregationAssociation, dsd:InheritanceAssociation ;
    rdfs:isDefinedBy dsd:isDisjoint ;
    rdfs:label "is Disjoint"@en ;
    rdfs:range xsd:boolean ;
    rdfs:subPropertyOf dsd:hasAssociationDescriptor .

dsd:isNullable
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment dsd:isNullable, "If the attribute can contain NULL values."@en ;
    rdfs:label "is Nullable"@en ;
    rdfs:range xsd:boolean ;
    rdfs:subPropertyOf dsd:hasAttributeDescriptor .

dsd:isOfDataType
    a owl:AsymmetricProperty, owl:FunctionalProperty, owl:ObjectProperty ;
    rdfs:comment "Describes an Attribute with an XLS Datatype."@en ;
    rdfs:domain dsd:Attribute ;
    rdfs:isDefinedBy dsd:isOfDataType ;
    rdfs:label "is of Data Type"@en .

dsd:isOfDatasourceType
    a owl:AsymmetricProperty, owl:FunctionalProperty, owl:ObjectProperty ;
    rdfs:comment "Describes the type of a Data Source. This vocabulary provides some Individuals that can be used."@en ;
    rdfs:domain dsd:Datasource ;
    rdfs:isDefinedBy dsd:isOfDatasourceType ;
    rdfs:label "is of Data Source Type"@en ;
    rdfs:range dsd:DatasourceType .

dsd:isSchemaOf
    a owl:FunctionalProperty, owl:ObjectProperty ;
    rdfs:domain dsd:Schema ;
    rdfs:label "is Schema of"@en ;
    rdfs:range dsd:Datasource .

dsd:isUnique
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment dsd:isUnique, "Describes if an attribute is unique or not."@en ;
    rdfs:label "is Unique"@en ;
    rdfs:range xsd:boolean ;
    rdfs:subPropertyOf dsd:hasAttributeDescriptor .

dsd:maxCharacterLength
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment dsd:maxCharacterLength, "Maximum character length of this attribute, given in the number of bits."@en ;
    rdfs:label "Maximum Character Length"@en ;
    rdfs:range xsd:integer ;
    rdfs:subPropertyOf dsd:hasAttributeDescriptor .

dsd:noOfInstances
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment dsd:noOfInstances, "Number of instances of a concept/association."@en ;
    rdfs:label "Number of Instances"@en ;
    rdfs:range xsd:nonNegativeInteger ;
    rdfs:subPropertyOf dsd:hasConceptDescriptor .

dsd:ordinalPosition
    a owl:DatatypeProperty, owl:FunctionalProperty ;
    rdfs:comment dsd:ordinalPosition, "The ordinal position of the attribute to the concept, this information might not always be available (depending on the data source)."@en ;
    rdfs:label "Ordinal Position"@en ;
    rdfs:range xsd:positiveInteger ;
    rdfs:subPropertyOf dsd:hasAttributeDescriptor .

dsd:referencesFrom
    a owl:AsymmetricProperty, owl:ObjectProperty ;
    rdfs:domain dsd:ReferenceAssociation ;
    rdfs:isDefinedBy dsd:referencesFrom ;
    rdfs:label "references from" ;
    rdfs:range dsd:Concept ;
    rdfs:subPropertyOf owl:topObjectProperty .

dsd:referencesTo
    a owl:ObjectProperty ;
    rdfs:comment "A ForeignKey or Concept references to another Concept or a PrimaryKey."@en ;
    rdfs:domain [
        a owl:Class ;
        owl:unionOf (dsd:Concept
            dsd:PrimaryKey
            dsd:ReferenceAssociation
        )
    ] ;
    rdfs:isDefinedBy dsd:referencesTo ;
    rdfs:label "referencesTo"@en ;
    rdfs:range [
        a owl:Class ;
        owl:unionOf (dsd:Concept
            dsd:ForeignKey
            dsd:ReferenceAssociation
        )
    ] ;
    rdfs:subPropertyOf owl:topObjectProperty .

[]
    a owl:AllDisjointClasses ;
    owl:members (dsd:AggregationAssociation
        dsd:InheritanceAssociation
        dsd:ReferenceAssociation
    ) .

