java.lang.Object
java.lang.Record
org.aya.cli.literate.HighlightInfo.Def
- All Implemented Interfaces:
Comparable<HighlightInfo>,HighlightInfo
- Enclosing interface:
HighlightInfo
public static record HighlightInfo.Def(@NotNull org.aya.util.error.SourcePos sourcePos, @NotNull org.aya.pretty.doc.Link target, @NotNull HighlightInfo.DefKind kind, @Nullable org.aya.generic.AyaDocile type)
extends Record
implements HighlightInfo
A definition of a symbol
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.aya.cli.literate.HighlightInfo
HighlightInfo.Def, HighlightInfo.DefKind, HighlightInfo.Err, HighlightInfo.Lit, HighlightInfo.LitKind, HighlightInfo.Ref, HighlightInfo.UserMeta -
Constructor Summary
ConstructorsConstructorDescriptionDef(@NotNull org.aya.util.error.SourcePos sourcePos, @NotNull org.aya.pretty.doc.Link target, @NotNull HighlightInfo.DefKind kind, @Nullable org.aya.generic.AyaDocile type) Creates an instance of aDefrecord class. -
Method Summary
Modifier and TypeMethodDescriptionbooleanIndicates whether some other object is "equal to" this one.inthashCode()Returns a hash code value for this object.@NotNull HighlightInfo.DefKindkind()Returns the value of thekindrecord component.@NotNull org.aya.util.error.SourcePosReturns the value of thesourcePosrecord component.@NotNull org.aya.pretty.doc.Linktarget()Returns the value of thetargetrecord component.final StringtoString()Returns a string representation of this record class.@Nullable org.aya.generic.AyaDociletype()Returns the value of thetyperecord component.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.aya.cli.literate.HighlightInfo
compareTo
-
Constructor Details
-
Def
public Def(@NotNull @NotNull org.aya.util.error.SourcePos sourcePos, @NotNull @NotNull org.aya.pretty.doc.Link target, @NotNull @NotNull HighlightInfo.DefKind kind, @Nullable @Nullable org.aya.generic.AyaDocile type) Creates an instance of aDefrecord class.- Parameters:
sourcePos- the value for thesourcePosrecord componenttarget- the value for thetargetrecord componentkind- the value for thekindrecord componenttype- the value for thetyperecord component
-
-
Method Details
-
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). -
hashCode
public int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. -
sourcePos
@NotNull public @NotNull org.aya.util.error.SourcePos sourcePos()Returns the value of thesourcePosrecord component.- Specified by:
sourcePosin interfaceHighlightInfo- Returns:
- the value of the
sourcePosrecord component
-
target
@NotNull public @NotNull org.aya.pretty.doc.Link target()Returns the value of thetargetrecord component.- Returns:
- the value of the
targetrecord component
-
kind
Returns the value of thekindrecord component.- Returns:
- the value of the
kindrecord component
-
type
@Nullable public @Nullable org.aya.generic.AyaDocile type()Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-