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

META-INF.jqassistant-rules.spring-data.xml Maven / Gradle / Ivy

Go to download

Plugin for jQAssistant to be able to scan and to analyze Spring related artifacts.

There is a newer version: 1.7.0-MS3
Show newest version
<jqassistant-rules xmlns="http://schema.jqassistant.org/rule/v1.10"
                   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                   xsi:schemaLocation="http://schema.jqassistant.org/rule/v1.10 https://schema.jqassistant.org/plugin/jqassistant-rule-v1.10.xsd">

    <concept id="spring-data:AnnotatedRepository">
        <providesConcept refId="spring-component:Repository"/>
        <providesConcept refId="spring-component:Component"/>
        <providesConcept refId="spring-injection:Injectable"/>
        <description>Labels all types annotated with "@org.springframework.stereotype.Repository" with "Spring",
            "Repository" and "Component".
        </description>
        <cypher><![CDATA[
            MATCH
              (repository:Type)-[:ANNOTATED_BY]->()-[:OF_TYPE]->(annotationType:Type)
            WHERE
              annotationType.fqn = "org.springframework.stereotype.Repository"
            SET
              repository:Spring:Repository:Component:Injectable
            RETURN
              repository as Repository
        ]]></cypher>
    </concept>

    <concept id="spring-data:ImplementedRepository">
        <providesConcept refId="spring-component:Repository"/>
        <providesConcept refId="spring-component:Component"/>
        <providesConcept refId="spring-injection:Injectable"/>
        <description>Labels all types implementing "org.springframework.data.repository.Repository" with "Spring",
            "Repository" and "Component".
        </description>
        <cypher><![CDATA[
            MATCH
              (repository:Type)-[:EXTENDS|IMPLEMENTS*]->(superType:Type)
            WHERE
              superType.fqn in [
                "org.springframework.data.repository.Repository",
                "org.springframework.data.repository.CrudRepository",
                "org.springframework.data.repository.PagingAndSortingRepository",
                "org.springframework.data.jpa.repository.JpaRepository",
                "org.springframework.data.jpa.repository.support.SimpleJpaRepository",
                "org.springframework.data.jpa.repository.support.QueryDslJpaRepository"
              ]
            SET
              repository:Spring:Repository:Component:Injectable
            RETURN
              repository as Repository
        ]]></cypher>
    </concept>

</jqassistant-rules>




© 2015 - 2025 Weber Informatics LLC | Privacy Policy