Record Class CascadeRepo
- Record Components:
coordinate- the project's reactor-root coordinaterepo- the on-disk directory / GitHub repo nameurl- the canonical upstream git URL, ornullwhen unknownrepositoryKey- the<scm>-derived repository identity;nullwhen the assembler had noRepositoryKeyResolvercascade- the project's own parsedrelease-cascade.yaml
A node pairs a project's identity — its reactor-root Maven
MavenCoordinate and repository locators — with the
ProjectCascade parsed from that project's own
src/main/cascade/release-cascade.yaml. Nodes are produced
only by CascadeAssembler, which traverses the per-project
manifests and stitches them into a single ordered
ReleaseCascade.
Two identities live on the node. The coordinate names
the coordinate the assembler started from for this node —
the entry-point used to find the node's ProjectCascade.
The repositoryKey names the repository the
coordinate belongs to (the <scm>-derived join key), and is
the durable node identity once #496 part D collapses self-edges
and coordinate aliases onto the repository. repositoryKey
may be null on nodes assembled without a
RepositoryKeyResolver — older assemblies and tests are
unaffected.
The repo and url fields are pure locators —
the on-disk directory name and the canonical upstream git URL the
cascade executor uses to reach the project.
-
Constructor Summary
ConstructorsConstructorDescriptionCascadeRepo(String groupId, String artifactId, String repo, String url, ProjectCascade cascade) Convenience constructor accepting rawgroupId/artifactIdstrings.CascadeRepo(String groupId, String artifactId, String repo, String url, RepositoryKey repositoryKey, ProjectCascade cascade) CascadeRepo(MavenCoordinate coordinate, String repo, String url, ProjectCascade cascade) Convenience constructor for callers that have noRepositoryKeyyet — older assemblies and tests.CascadeRepo(MavenCoordinate coordinate, String repo, String url, RepositoryKey repositoryKey, ProjectCascade cascade) Canonical constructor — validates the coordinate and the embeddedProjectCascade, and defaultsrepoto the artifactId when blank. -
Method Summary
Modifier and TypeMethodDescriptionReturns the coordinate'sartifactId.cascade()Returns the value of thecascaderecord component.consumes()The groupIds this project consumes, drawn from itsupstreamedges.Returns the value of thecoordinaterecord component.The downstream edges — the projects that consume this one.final booleanIndicates whether some other object is "equal to" this one.ga()Returns the"groupId:artifactId"display form.groupId()Returns the coordinate'sgroupId.final inthashCode()Returns a hash code value for this object.booleanhead()Whether this project is the head of the cascade.repo()Returns the value of thereporecord component.Returns the value of therepositoryKeyrecord component.booleanterminal()Whether this project is the terminus of the cascade.final StringtoString()Returns a string representation of this record class.upstream()The upstream edges — the projects this one consumes.url()Returns the value of theurlrecord component.
-
Constructor Details
-
CascadeRepo
public CascadeRepo(MavenCoordinate coordinate, String repo, String url, RepositoryKey repositoryKey, ProjectCascade cascade) Canonical constructor — validates the coordinate and the embeddedProjectCascade, and defaultsrepoto the artifactId when blank. -
CascadeRepo
Convenience constructor for callers that have noRepositoryKeyyet — older assemblies and tests. TherepositoryKeyfield is set tonull.- Parameters:
coordinate- the project's coordinaterepo- the on-disk directory / GitHub repo nameurl- the canonical upstream git URL, ornullcascade- the project's parsed manifest
-
CascadeRepo
public CascadeRepo(String groupId, String artifactId, String repo, String url, ProjectCascade cascade) Convenience constructor accepting rawgroupId/artifactIdstrings. Wraps them into aMavenCoordinate.- Parameters:
groupId- the MavengroupIdartifactId- the MavenartifactIdrepo- the on-disk directory / GitHub repo nameurl- the canonical upstream git URLcascade- the project's parsed manifest
-
CascadeRepo
public CascadeRepo(String groupId, String artifactId, String repo, String url, RepositoryKey repositoryKey, ProjectCascade cascade) - Parameters:
groupId- the MavengroupIdartifactId- the MavenartifactIdrepo- the on-disk directory / GitHub repo nameurl- the canonical upstream git URLrepositoryKey- the repository identity, ornullcascade- the project's parsed manifest
-
-
Method Details
-
groupId
Returns the coordinate'sgroupId. Delegates toMavenCoordinate.groupId()for compatibility with the pre-record API.- Returns:
- the
groupId
-
artifactId
Returns the coordinate'sartifactId. Delegates toMavenCoordinate.artifactId()for compatibility with the pre-record API.- Returns:
- the
artifactId
-
ga
-
upstream
The upstream edges — the projects this one consumes.- Returns:
- this project's
upstreamedges; nevernull
-
downstream
The downstream edges — the projects that consume this one.- Returns:
- this project's
downstreamedges; nevernull
-
consumes
-
head
public boolean head()Whether this project is the head of the cascade.- Returns:
trueif it declares no upstream edge
-
terminal
public boolean terminal()Whether this project is the terminus of the cascade.- Returns:
trueif it declares no downstream edge
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
coordinate
Returns the value of thecoordinaterecord component.- Returns:
- the value of the
coordinaterecord component
-
repo
-
url
-
repositoryKey
Returns the value of therepositoryKeyrecord component.- Returns:
- the value of the
repositoryKeyrecord component
-
cascade
-