public class DefaultNTexts extends Object implements NTexts
| Constructor and Description |
|---|
DefaultNTexts() |
public static String escapeText0(String str)
str - strpublic NTextBuilder ofBuilder()
public NTextPlain ofPlain(String t)
public NTextList ofList(Collection<NText> nodes)
public NText ofStyled(String other, NTextStyles styles)
public NText ofStyled(NText other, NTextStyles styles)
public NText ofStyled(String plainText, NTextStyle style)
public NText ofStyled(NMsg other, NTextStyles styles)
public NText ofStyled(NMsg other, NTextStyle style)
public NText ofStyled(NText other, NTextStyle style)
public NTextCmd ofCommand(NTerminalCmd command)
public NText ofCodeOrCommand(String lang, String text)
ofCodeOrCommand in interface NTextspublic NText ofCodeOrCommand(String text)
ofCodeOrCommand in interface NTextspublic NText ofCodeOrCommand(String name, String text, char sep)
ofCodeOrCommand in interface NTextspublic NTitleSequence ofNumbering()
ofNumbering in interface NTextspublic NTitleSequence ofNumbering(String pattern)
ofNumbering in interface NTextspublic NTextAnchor ofAnchor(String anchorName)
public NTextAnchor ofAnchor(String anchorName, char sep)
public NTextInclude ofInclude(String value)
public NTextInclude ofInclude(String value, char sep)
public NOptional<NTextFormatTheme> getTheme(String name)
public NTextFormatTheme getTheme()
public NTexts setTheme(NTextFormatTheme theme)
public NCodeHighlighter getCodeHighlighter(String kind)
getCodeHighlighter in interface NTextspublic NTexts addCodeHighlighter(NCodeHighlighter format)
addCodeHighlighter in interface NTextspublic NTexts removeCodeHighlighter(String id)
removeCodeHighlighter in interface NTextspublic List<NCodeHighlighter> getCodeHighlighters()
getCodeHighlighters in interface NTextspublic NTextParser parser()
public NCodeHighlighter resolveCodeHighlighter(String kind)
public NTextTitle ofTitle(NText other, int level)
public NTextTitle ofTitle(String other, int level)
public NTextCode createCode(String start, String kind, String separator, String end, String text)
public NTextCmd createCommand(String start, NTerminalCmd command, String separator, String end)
public NTextAnchor createAnchor(String start, String separator, String end, String value)
public int getSupportLevel(NSupportLevelContext context)
getSupportLevel in interface NComponentpublic NStream<NText> flatten(NText text, NTextTransformConfig config)
public NStream<NText> flatten(NText text, NTextTransformer transformer, NTextTransformConfig config)
public NText transform(NText text, NTextTransformConfig config)
public NText transform(NText text, NTextTransformer transformer, NTextTransformConfig config)
public void traverseDFS(NText text, NTextVisitor visitor)
traverseDFS in interface NTextspublic void traverseBFS(NText text, NTextVisitor visitor)
traverseBFS in interface NTextspublic String escapeText(String str)
escapeText in interface NTextspublic String filterText(String text)
filterText in interface NTextspublic NFormat createFormat(NFormatSPI format)
createFormat in interface NTextspublic <T> NFormat createFormat(T object, NTextFormat<T> format)
createFormat in interface NTextspublic NOptional<NTextFormat<Number>> createNumberTextFormat(String type, String pattern)
createNumberTextFormat in interface NTextspublic NOptional<NStringFormat<Number>> createNumberStringFormat(String type, String pattern)
createNumberStringFormat in interface NTextspublic <T> NOptional<NStringFormat<T>> createStringFormat(String type, String pattern, Class<T> expectedType)
createStringFormat in interface NTextspublic <T> NOptional<NTextFormat<T>> createTextFormat(String type, String pattern, Class<T> expectedType)
createTextFormat in interface NTextsCopyright © 2025 vpc open source initiative. All rights reserved.