Verified Owner
Top Inners Fields Constructors Methods
org.jabref.logic.bst

pack-priv Class BstVMVisitor

extends BstBaseVisitor<Integer>
Class Inheritance
Annotations
@NullMarked
Imports
java.util.Comparator, .List, .ListIterator, .Map, org.jabref.logic.bibtex.FieldPreferences, .FieldWriter, org.jabref.model.entry.Month, org.jabref.model.entry.field.Field, .FieldFactory, .StandardField, org.antlr.v4.runtime.ParserRuleContext, org.antlr.v4.runtime.tree.ParseTree, .TerminalNode, org.jspecify.annotations.NullMarked, .Nullable, org.slf4j.Logger, .LoggerFactory

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static record

Field Summary

Modifier and TypeField and Description
private final StringBuilder
private final BstVMContext
private static final Logger
private @Nullable BstEntry

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private static String
normalizeFieldValue(String content, FieldWriter fieldWriter, Field field)

protected void
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
public Integer
Inherited from org.jabref.logic.bst.BstBaseVisitor:
visitBstFilevisitIdListOblvisitIdListOptvisitStack

Field Detail

bblback to summary
private final StringBuilder bbl
bstVMContextback to summary
private final BstVMContext bstVMContext
LOGGERback to summary
private static final Logger LOGGER
selectedBstEntryback to summary
private @Nullable BstEntry selectedBstEntry

Constructor Detail

BstVMVisitorback to summary
public BstVMVisitor(BstVMContext bstVMContext, StringBuilder bbl)

Method Detail

normalizeFieldValueback to summary
private static String normalizeFieldValue(String content, FieldWriter fieldWriter, Field field)
resolveIdentifierback to summary
protected void resolveIdentifier(String name, ParserRuleContext ctx)
visitBstFunctionback to summary
public Integer visitBstFunction(BstParser.BstFunctionContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitBstFunction.

Implements org.jabref.logic.bst.BstVisitor.visitBstFunction.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitBstFunction.

Visit a parse tree produced by BstParser#bstFunction.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitEntryCommandback to summary
public Integer visitEntryCommand(BstParser.EntryCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitEntryCommand.

Implements org.jabref.logic.bst.BstVisitor.visitEntryCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitEntryCommand.

Visit a parse tree produced by the entryCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitExecuteCommandback to summary
public Integer visitExecuteCommand(BstParser.ExecuteCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitExecuteCommand.

Implements org.jabref.logic.bst.BstVisitor.visitExecuteCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitExecuteCommand.

Visit a parse tree produced by the executeCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitFunctionCommandback to summary
public Integer visitFunctionCommand(BstParser.FunctionCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitFunctionCommand.

Implements org.jabref.logic.bst.BstVisitor.visitFunctionCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitFunctionCommand.

Visit a parse tree produced by the functionCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitIdentifierback to summary
public Integer visitIdentifier(BstParser.IdentifierContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitIdentifier.

Implements org.jabref.logic.bst.BstVisitor.visitIdentifier.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitIdentifier.

Visit a parse tree produced by BstParser#identifier.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitIntegersCommandback to summary
public Integer visitIntegersCommand(BstParser.IntegersCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitIntegersCommand.

Implements org.jabref.logic.bst.BstVisitor.visitIntegersCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitIntegersCommand.

Visit a parse tree produced by the integersCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitIterateCommandback to summary
public Integer visitIterateCommand(BstParser.IterateCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitIterateCommand.

Implements org.jabref.logic.bst.BstVisitor.visitIterateCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitIterateCommand.

Visit a parse tree produced by the iterateCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitMacroCommandback to summary
public Integer visitMacroCommand(BstParser.MacroCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitMacroCommand.

Implements org.jabref.logic.bst.BstVisitor.visitMacroCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitMacroCommand.

Visit a parse tree produced by the macroCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitReadCommandback to summary
public Integer visitReadCommand(BstParser.ReadCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitReadCommand.

Implements org.jabref.logic.bst.BstVisitor.visitReadCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitReadCommand.

Visit a parse tree produced by the readCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitReverseCommandback to summary
public Integer visitReverseCommand(BstParser.ReverseCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitReverseCommand.

Implements org.jabref.logic.bst.BstVisitor.visitReverseCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitReverseCommand.

Visit a parse tree produced by the reverseCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitSortCommandback to summary
public Integer visitSortCommand(BstParser.SortCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitSortCommand.

Implements org.jabref.logic.bst.BstVisitor.visitSortCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitSortCommand.

Visit a parse tree produced by the sortCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitStackitemback to summary
public Integer visitStackitem(BstParser.StackitemContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitStackitem.

Implements org.jabref.logic.bst.BstVisitor.visitStackitem.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitStackitem.

Visit a parse tree produced by BstParser#stackitem.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
visitStringsCommandback to summary
public Integer visitStringsCommand(BstParser.StringsCommandContext ctx)

Overrides org.jabref.logic.bst.BstBaseVisitor.visitStringsCommand.

Implements org.jabref.logic.bst.BstVisitor.visitStringsCommand.

Doc from org.jabref.logic.bst.BstBaseVisitor.visitStringsCommand.

Visit a parse tree produced by the stringsCommand labeled alternative in BstParser#commands.

The default implementation returns the result of calling visitChildren on ctx.

Annotations
@Override
org.jabref.logic.bst back to summary

public final Record BstVMVisitor.Identifier

extends Record
Class Inheritance
Record Components
name:String 

Field Summary

Modifier and TypeField and Description
private final String
name

Record Component accessed by name().

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public final boolean
equals(Object o)

Implements abstract java.lang.Record.equals.

Indicates whether some other object is "equal to" this one.

public final int
hashCode()

Implements abstract java.lang.Record.hashCode.

Returns a hash code value for the record.

public String
name()

Record Component getter of name.

public final String
toString()

Implements abstract java.lang.Record.toString.

Returns a string representation of the record.

Field Detail

nameback to summary
private final String name

Record Component accessed by name().

Constructor Detail

Identifierback to summary
public Identifier(String name)

Method Detail

equalsback to summary
public final boolean equals(Object o)

Implements abstract java.lang.Record.equals.

Doc from java.lang.Record.equals.

Indicates whether some other object is "equal to" this one. In addition to the general contract of Object.equals, record classes must further obey the invariant that when a record instance is "copied" by passing the result of the record component accessor methods to the canonical constructor, as follows:

    R copy = new R(r.c1(), r.c2(), ..., r.cn());
then it must be the case that r.equals(copy).
hashCodeback to summary
public final int hashCode()

Implements abstract java.lang.Record.hashCode.

Doc from java.lang.Record.hashCode.

Returns a hash code value for the record. Obeys the general contract of Object.hashCode. For records, hashing behavior is constrained by the refined contract of Record.equals, so that any two records created from the same components must have the same hash code.

nameback to summary
public String name()

Record Component getter of name.

toStringback to summary
public final String toString()

Implements abstract java.lang.Record.toString.

Doc from java.lang.Record.toString.

Returns a string representation of the record. In accordance with the general contract of Object#toString(), the toString method returns a string that "textually represents" this record. The result should be a concise but informative representation that is easy for a person to read.

In addition to this general contract, record classes must further participate in the invariant that any two records which are equal must produce equal strings. This invariant is necessarily relaxed in the rare case where corresponding equal component values might fail to produce equal strings for themselves.