Record Class ManagedQualifier
java.lang.Object
java.lang.Record
org.j7m.middleware.application.api.ManagedQualifier
- Record Components:
annotationType- fully qualified binary annotation type namemembers- canonical member name to value mapping, at most64 entries
Exact immutable qualifier identity produced by a generated component index.
Member values use value(Object), including annotation defaults. Qualifier values are selection
data and must not be printed as diagnostic labels or used to carry credentials.
-
Constructor Summary
ConstructorsConstructorDescriptionManagedQualifier(String annotationType, Map<String, String> members) Validates and copies a bounded canonical qualifier. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theannotationTyperecord component.final booleanIndicates whether some other object is "equal to" this one.static Stringfingerprint(List<ManagedQualifier> qualifiers) Hashes an exact normalized qualifier set using sorted, length-framed UTF16 code units.final inthashCode()Returns a hash code value for this object.members()Returns the value of themembersrecord component.final StringtoString()Returns a string representation of this record class.static StringEncodes one supported annotation member without compiler/runtime formatting differences.
-
Constructor Details
-
ManagedQualifier
Validates and copies a bounded canonical qualifier.- Parameters:
annotationType- nonblank type name, at most512 charactersmembers- at most64 nonnull member names/canonical values- Throws:
IllegalArgumentException- for invalid bounds
-
-
Method Details
-
value
Encodes one supported annotation member without compiler/runtime formatting differences. Supported values are String, boxed primitives, Character, Enum, Class and arrays thereof. Nested annotation instances are unsupported. Arrays have at most64 elements and depth8; the complete canonical value has at most8192 characters. Length framing avoids collisions.- Parameters:
member- supported nonnull annotation member value- Returns:
- stable canonical representation, including the member's type
- Throws:
IllegalArgumentException- for unsupported values or excessive bounds
-
fingerprint
Hashes an exact normalized qualifier set using sorted, length-framed UTF16 code units. Host exports and binding requests share this representation; no qualifier values are exposed in the resulting routing fingerprint. A digest is compatibility data, not authentication.- Parameters:
qualifiers- at most16 unique qualifier types- Returns:
- lowercase SHA256 fingerprint, including the empty set
- Throws:
IllegalArgumentException- for invalid qualifier sets
-
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). -
annotationType
Returns the value of theannotationTyperecord component.- Returns:
- the value of the
annotationTyperecord component
-
members
-