Record Class Dependency
java.lang.Object
java.lang.Record
network.ike.workspace.Dependency
- Record Components:
subproject- the name of the depended-on subprojectrelationship- the nature of the dependency — one ofKNOWN_RELATIONSHIPSversionProperty- optional POM property name that tracks the upstream subproject's version (e.g., "ike-maven-plugin.version"). Used byike:ws-releaseto update version references after releasing an upstream subproject. Null if no property tracking is needed.
public record Dependency(String subproject, String relationship, String versionProperty)
extends Record
An inter-repository dependency declared in a subproject's
depends-on list.
Relationship semantics (see IKE-WORKSPACE.md):
build— needs the upstream's compiled artifacts; orders the workspace build.content— references the upstream's architecture or concepts; a change may require only review.tooling— uses the upstream's CLI tools or Maven plugins.bundle— packages the upstream's artifact into an assembly at package time, resolved from the repository (~/.m2or a snapshot repo) rather than built from the workspace. Excluded from build ordering and cycle detection, still traversed by cascade analysis (IKE-Network/ike-issues#963). Carries a resolution hazard: the workspace does not guarantee the artifact is built first.
-
Field Summary
FieldsModifier and TypeFieldDescriptionThe recognizedrelationship:values. -
Constructor Summary
ConstructorsConstructorDescriptionDependency(String subproject, String relationship) Two-arg constructor for backwards compatibility (no version-property).Dependency(String subproject, String relationship, String versionProperty) Creates an instance of aDependencyrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanWhether this edge constrains workspace build order.Returns the value of therelationshiprecord component.Returns the value of thesubprojectrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of theversionPropertyrecord component.
-
Field Details
-
KNOWN_RELATIONSHIPS
-
-
Constructor Details
-
Dependency
-
Dependency
Creates an instance of aDependencyrecord class.- Parameters:
subproject- the value for thesubprojectrecord componentrelationship- the value for therelationshiprecord componentversionProperty- the value for theversionPropertyrecord component
-
-
Method Details
-
ordersBuild
public boolean ordersBuild()Whether this edge constrains workspace build order. Every relationship does exceptbundle, whose artifact is repository-resolved at package time and therefore orders nothing (IKE-Network/ike-issues#963).- Returns:
- true when the edge participates in topological sort and cycle detection
-
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). -
subproject
Returns the value of thesubprojectrecord component.- Returns:
- the value of the
subprojectrecord component
-
relationship
Returns the value of therelationshiprecord component.- Returns:
- the value of the
relationshiprecord component
-
versionProperty
Returns the value of theversionPropertyrecord component.- Returns:
- the value of the
versionPropertyrecord component
-