Package su.onno.ui.comments
Record Class MentionRef
java.lang.Object
java.lang.Record
su.onno.ui.comments.MentionRef
A typed reference embedded in a comment body — the comment-thread analogue of
Ref<T>. It
carries the same (kind, name, id) route triple the UI uses to address any record, where
kind is "catalogs" or "documents" and name is the URL-safe route
segment (snake_case logical name, e.g. "sales_orders"). Like every other ref in the
framework, only the identity is stored — display, avatar and read access are resolved live (see
MentionResolver) so renames and deletes stay correct automatically.
In a stored body a mention is a token of the form @[Display](kind/name/id); see
Mentions for the parser/serializer. Two mentions are equal when their triples match,
regardless of the snapshot label that accompanied them in the text.
-
Constructor Summary
ConstructorsConstructorDescriptionMentionRef(String kind, String name, UUID id) Creates an instance of aMentionRefrecord 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.id()Returns the value of theidrecord component.kind()Returns the value of thekindrecord component.name()Returns the value of thenamerecord component.route()Thekind/name/idroute segment, the body of anonno://navigation url.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
MentionRef
Creates an instance of aMentionRefrecord class.- Parameters:
kind- the value for thekindrecord componentname- the value for thenamerecord componentid- the value for theidrecord component
-
-
Method Details
-
accessType
-
route
Thekind/name/idroute segment, the body of anonno://navigation url. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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). -
kind
Returns the value of thekindrecord component.- Returns:
- the value of the
kindrecord component
-
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-