Skip navigation links
org.jerkar.api.depmanagement

Class JkScope

    • Method Detail

      • of

        public static JkScope of(java.lang.String name)
        Creates a new JkScope passing its name.
      • of

        public static JkScope of(java.lang.String name,
                                 java.lang.String description,
                                 boolean transitive,
                                 JkScope... extending)
      • getName

        public java.lang.String getName()
        Returns the name of this scope. Name is used as identifier for scopes.
      • getDescription

        public java.lang.String getDescription()
        Human description for the purpose of this scope, can be null.
      • getExtendedScopes

        public java.util.Set<JkScope> getExtendedScopes()
        Scopes that are extended by this one.
      • isTransitive

        public boolean isTransitive()
        Returns true if the dependencies defined with this scope should be resolved recursively (meaning returning the dependencies of the dependencies and so on)
      • getAncestorScopes

        public java.util.List<JkScope> getAncestorScopes()
        Returns scopes this scope inherits from. It returns recursively parent scopes, parent of parent scopes and so on.
      • getCommonScopes

        public java.util.List<JkScope> getCommonScopes(java.util.Collection<JkScope> scopes)
        Returns this scope or its first ancestors found present in the specified scopes.
      • isExtending

        public boolean isExtending(JkScope jkScope)
        Returns true if this scope extends the specified one.
      • isInOrIsExtendingAnyOf

        public boolean isInOrIsExtendingAnyOf(java.lang.Iterable<? extends JkScope> scopes)
        Returns true if this scope is one or is extending any of the specified scopes.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • getInvolvedScopes

        public static java.util.Set<JkScope> getInvolvedScopes(java.lang.Iterable<JkScope> scopes)
        returns all specified scopes and all of their ancestors.