Package jetbrains.buildServer.vcs
Class VcsRootScope
- java.lang.Object
-
- jetbrains.buildServer.vcs.VcsRootScope
-
public class VcsRootScope extends java.lang.Object
Represents scope of VCS root. VCS root can have project or global scope. VCS roots with project scope are available to this project only. VCS roots with global scope are available globally, to all of the projects.
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
VcsRootScope(java.lang.String projectInternalId)
Creates new scope from internal project id
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
java.lang.String
getOwnerProjectId()
For local scopes returns internal id of the project - owner of this VCS rootstatic VcsRootScope
globalScope()
Use to create global scopeint
hashCode()
boolean
isAccessibleFrom(SBuildType buildType)
Returns true if VCS roots with this scope are accessible from the specified build configuration.boolean
isAccessibleFrom(SProject project)
Returns true if VCS roots with this scope are accessible from the specified project.boolean
isGlobal()
Returns true if scope is globalstatic VcsRootScope
projectScope(java.lang.String projectInternalId)
Use to create project scopestatic VcsRootScope
projectScope(SBuildType buildType)
Use to create project scopestatic VcsRootScope
projectScope(SProject project)
Use to create project scopejava.lang.String
toString()
-
-
-
Method Detail
-
getOwnerProjectId
@NotNull public java.lang.String getOwnerProjectId()
For local scopes returns internal id of the project - owner of this VCS root- Returns:
- owner project internal id
-
isGlobal
public boolean isGlobal()
Returns true if scope is global- Returns:
- true if scope is global
-
globalScope
@NotNull public static VcsRootScope globalScope()
Use to create global scope- Returns:
- global scope
-
projectScope
@NotNull public static VcsRootScope projectScope(@NotNull java.lang.String projectInternalId)
Use to create project scope- Parameters:
projectInternalId
- id of the owner project of the VCS root- Returns:
- new project scope
-
projectScope
@NotNull public static VcsRootScope projectScope(@NotNull SProject project)
Use to create project scope- Parameters:
project
- owner project of the VCS root- Returns:
- new project scope
- Since:
- 8.0
-
projectScope
@NotNull public static VcsRootScope projectScope(@NotNull SBuildType buildType)
Use to create project scope- Parameters:
buildType
- build type of the owner project of the VCS root- Returns:
- new project scope
- Since:
- 8.0
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
isAccessibleFrom
public boolean isAccessibleFrom(@NotNull SBuildType buildType)
Returns true if VCS roots with this scope are accessible from the specified build configuration.- Parameters:
buildType
- build configuration- Returns:
- true if VCS roots with this scope are accessible from the specified build configuration.
-
isAccessibleFrom
public boolean isAccessibleFrom(@NotNull SProject project)
Returns true if VCS roots with this scope are accessible from the specified project.- Parameters:
project
- the project- Returns:
- true if VCS roots with this scope are accessible from the specified project.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-