All Downloads are FREE. Search and download functionalities are using the official Maven repository.

models.autoRealization.Tests.M2.LinkSpec.LinkSpec_CollectionResource.yaml Maven / Gradle / Ivy

There is a newer version: 1.4.2
Show newest version
$schema: ../../../../../../com.modelsolv.reprezen.realization/schema/auto-realization-config-schema.json
_type: RealizationModel
_documentation: |
      objectResource Root Object (IndexObject) has
        * Multi-valued references, Not auto-linkable to CR
          * Excludes taxFilings
          * Includes people, accountants, balanceSheets
      
      collectionResource Root Objects (CommentCollection, TaxFilingCollection) have
        * key properties
        
      Multi-valued reference, not auto-linkable to CR (balanceSheets)
        * key properties
        * multi-valued references, auto-linkable to CR (comments)
      
      Multi-Valued reference, auto-linkaable to CR (comments) has
        * key properties
        * Auto-link to collectionResource

name: LinkSpec_ObjectResource
realizationRules:

  ObjectResourceRoot:
    _type: RealizationRule
    namingPattern: ${TypeName}_Root
    appliesTo:
    - _type: ContextPattern
      resourceType: OBJECT_RESOURCE
      level:
        _type: RootObjectContext
    realization:
      _type: ObjectRealizationSpec
      propertySet:
        _documentation: Only include multi-valued references that are _not_ auto-linkable to a collectionResource.
        _type: ExclusivePropertySet
        includedProperties:
        - _type: PropertyRealization
          multiplicity: MULTI_VALUED
          propertyType:
            _type: ReferencePropertyRealization
            autoLinkableToCollectionResource: false
        
  CollectionResourceRoot:
    _type: RealizationRule
    namingPattern: ${TypeName}_Root
    appliesTo:
    - _type: ContextPattern
      resourceType: COLLECTION_RESOURCE
      level:
        _type: RootObjectContext
    realization:
      _type: ObjectRealizationSpec
      propertySet:
        _documentation: Only include key properties.
        _type: ExclusivePropertySet
        includedProperties:
        - _type: PropertyRealization
          propertyType:
            _type: PrimitivePropertyRealization
            isKey: true
        
  MultiRefNotLinkableToCR:
    _type: RealizationRule
    namingPattern: ${TypeName}_Ref
    appliesTo:
    - _type: ContextPattern
      autoLinkableToCollectionResource: FALSE
      level:
        _type: ReferencePropertyContext
        multiplicity: MULTI_VALUED
    realization:
      _type: ObjectRealizationSpec
      propertySet:
        _documentation: Only include multi-valued references that are auto-linkable to a CR
        _type: ExclusivePropertySet
        includedProperties:
        - _type: PropertyRealization
          multiplicity: MULTI_VALUED
          propertyType:
            _type: ReferencePropertyRealization
            autoLinkableToCollectionResource: true

  MultiRefLinkableToCR:
    _type: RealizationRule
    namingPattern: ${TypeName}_Ref
    appliesTo:
    - _type: ContextPattern
      autoLinkableToCollectionResource: true
      level:
        _type: ReferencePropertyContext
        multiplicity: MULTI_VALUED
    realization:
      _type: ObjectRealizationSpec
      propertySet:
        _documentation: Only include key properties.
        _type: ExclusivePropertySet
        includedProperties:
        - _type: PropertyRealization
          propertyType:
            _type: PrimitivePropertyRealization
            isKey: true
                        
      links:
      - strategy: specification
        linkRelation: detail
        targetResourceType: AUTO_LINK_COLLECTION_RESOURCE




© 2015 - 2024 Weber Informatics LLC | Privacy Policy