@prefix rdf:      <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix xsd:      <http://www.w3.org/2001/XMLSchema#> .
@prefix skos:     <http://www.w3.org/2004/02/skos/core#> .
@prefix dcterms:  <http://purl.org/dc/terms/> .
@prefix arch:     <https://meta.linked.archi/core#> .
@prefix arch-vis: <https://meta.linked.archi/core-vis#> .
@prefix am:       <https://meta.linked.archi/archimate3/onto#> .
@prefix :         <https://meta.linked.archi/examples/diagram-nesting/> .

#################################################################
# Core-vis nesting example — nodes drawn inside other nodes
#
# What NestedNodeShape reports, and what it must not: a node drawn
# inside a node of its own view, and inside a node that is itself
# inside one (two levels), in each of two views — none reported; a
# node drawn inside a node of the other view, a node drawn inside
# itself, and two nodes drawn each inside the other — each reported.
#
# Used as the data graph of the `core-vis-nesting` validation profile
# in .scripts/validate.sh, which passes when the report is exactly
# diagram-nesting-example.expected.tsv.
#################################################################

:NestingExampleModel
    a                             arch:Model ;
    skos:prefLabel                "Core-vis Nesting Example"@en ;
    arch:modelConformsToMetamodel <https://meta.linked.archi/archimate3/metamodel#ArchiMate3.2> ;
    dcterms:created               "2026-12-02"^^xsd:date ;
.

:Ordering    a am:ApplicationComponent ; skos:prefLabel "Ordering"@en .
:Payments    a am:ApplicationComponent ; skos:prefLabel "Payments"@en .
:Invoicing   a am:ApplicationComponent ; skos:prefLabel "Invoicing"@en .
:Shipping    a am:ApplicationComponent ; skos:prefLabel "Shipping"@en .
:Reporting   a am:ApplicationComponent ; skos:prefLabel "Reporting"@en .

:FirstView
    a                            arch:View ;
    skos:prefLabel               "First view"@en ;
    arch:viewConformsToViewpoint <https://meta.linked.archi/archimate3/viewpoints#ApplicationCooperationViewpoint> ;
.

:SecondView
    a                            arch:View ;
    skos:prefLabel               "Second view"@en ;
    arch:viewConformsToViewpoint <https://meta.linked.archi/archimate3/viewpoints#ApplicationCooperationViewpoint> ;
.

#################################################################
# Not reported: nested in a node of its own view, one and two levels
#################################################################

:Group
    a                 arch-vis:ContainerNode ;
    arch-vis:view     :FirstView ;
    skos:prefLabel    "Group"@en ;
    arch-vis:bounds-x "0.0"^^xsd:double ;
    arch-vis:bounds-y "0.0"^^xsd:double ;
    arch-vis:bounds-w "600.0"^^xsd:double ;
    arch-vis:bounds-h "400.0"^^xsd:double ;
.

:OrderingInGroup
    a                    arch-vis:ArchNode ;
    arch-vis:view        :FirstView ;
    arch-vis:archElement :Ordering ;
    arch-vis:inNode      :Group ;
    arch-vis:bounds-x    "20.0"^^xsd:double ;
    arch-vis:bounds-y    "40.0"^^xsd:double ;
    arch-vis:bounds-w    "300.0"^^xsd:double ;
    arch-vis:bounds-h    "200.0"^^xsd:double ;
.

:PaymentsInOrdering
    a                    arch-vis:ArchNode ;
    arch-vis:view        :FirstView ;
    arch-vis:archElement :Payments ;
    arch-vis:inNode      :OrderingInGroup ;
    arch-vis:bounds-x    "40.0"^^xsd:double ;
    arch-vis:bounds-y    "80.0"^^xsd:double ;
    arch-vis:bounds-w    "120.0"^^xsd:double ;
    arch-vis:bounds-h    "55.0"^^xsd:double ;
.

:OtherGroup
    a                 arch-vis:ContainerNode ;
    arch-vis:view     :SecondView ;
    skos:prefLabel    "Other group"@en ;
    arch-vis:bounds-x "0.0"^^xsd:double ;
    arch-vis:bounds-y "0.0"^^xsd:double ;
    arch-vis:bounds-w "400.0"^^xsd:double ;
    arch-vis:bounds-h "200.0"^^xsd:double ;
.

:ReportingInOtherGroup
    a                    arch-vis:ArchNode ;
    arch-vis:view        :SecondView ;
    arch-vis:archElement :Reporting ;
    arch-vis:inNode      :OtherGroup ;
    arch-vis:bounds-x    "20.0"^^xsd:double ;
    arch-vis:bounds-y    "40.0"^^xsd:double ;
    arch-vis:bounds-w    "120.0"^^xsd:double ;
    arch-vis:bounds-h    "55.0"^^xsd:double ;
.

#################################################################
# Reported: in the other view's node, inside itself, in a cycle
#################################################################

:InvoicingInOtherView
    a                    arch-vis:ArchNode ;
    arch-vis:view        :FirstView ;
    arch-vis:archElement :Invoicing ;
    arch-vis:inNode      :OtherGroup ;
    arch-vis:bounds-x    "340.0"^^xsd:double ;
    arch-vis:bounds-y    "40.0"^^xsd:double ;
    arch-vis:bounds-w    "120.0"^^xsd:double ;
    arch-vis:bounds-h    "55.0"^^xsd:double ;
.

:ShippingInItself
    a                    arch-vis:ArchNode ;
    arch-vis:view        :FirstView ;
    arch-vis:archElement :Shipping ;
    arch-vis:inNode      :ShippingInItself ;
    arch-vis:bounds-x    "340.0"^^xsd:double ;
    arch-vis:bounds-y    "120.0"^^xsd:double ;
    arch-vis:bounds-w    "120.0"^^xsd:double ;
    arch-vis:bounds-h    "55.0"^^xsd:double ;
.

:CycleOne
    a                 arch-vis:ContainerNode ;
    arch-vis:view     :FirstView ;
    skos:prefLabel    "Cycle one"@en ;
    arch-vis:inNode   :CycleTwo ;
    arch-vis:bounds-x "20.0"^^xsd:double ;
    arch-vis:bounds-y "260.0"^^xsd:double ;
    arch-vis:bounds-w "200.0"^^xsd:double ;
    arch-vis:bounds-h "100.0"^^xsd:double ;
.

:CycleTwo
    a                 arch-vis:ContainerNode ;
    arch-vis:view     :FirstView ;
    skos:prefLabel    "Cycle two"@en ;
    arch-vis:inNode   :CycleOne ;
    arch-vis:bounds-x "40.0"^^xsd:double ;
    arch-vis:bounds-y "280.0"^^xsd:double ;
    arch-vis:bounds-w "160.0"^^xsd:double ;
    arch-vis:bounds-h "60.0"^^xsd:double ;
.
