org.dadacoalition.yedit.editor.scanner.YAMLToken类的使用及代码示例

x33g5p2x  于2022-02-05 转载在 其他  
字(2.9k)|赞(0)|评价(0)|浏览(88)

本文整理了Java中org.dadacoalition.yedit.editor.scanner.YAMLToken类的一些代码示例,展示了YAMLToken类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YAMLToken类的具体详情如下:
包路径:org.dadacoalition.yedit.editor.scanner.YAMLToken
类名称:YAMLToken

YAMLToken介绍

暂无

代码示例

代码示例来源:origin: oyse/yedit

private boolean tokenHasTag(IToken token, IDocument document){
  if(!(token instanceof YAMLToken) || ((YAMLToken) token).getTokenType() != YAMLToken.COMMENT){
    return false;
  }
  
  String comment = getTokenString(document);
  return hasTag(comment);
}

代码示例来源:origin: RepreZen/KaiZen-OpenAPI-Editor

protected void init() {
  TextAttribute keyAttr = tokenAttribute(PreferenceConstants.COLOR_KEY, PreferenceConstants.BOLD_KEY,
      PreferenceConstants.ITALIC_KEY, PreferenceConstants.UNDERLINE_KEY);
  IToken keyToken = new YAMLToken(keyAttr, YAMLToken.KEY);
  IToken pathKeyToken = new YAMLToken(pathKeyAttr, YAMLToken.KEY);
  IToken scalarToken = new YAMLToken(scalarAttr, YAMLToken.SCALAR);
  IToken commentToken = new YAMLToken(commentAttr, YAMLToken.COMMENT);
      PreferenceConstants.UNDERLINE_DOCUMENT);
  IToken documentStartToken = new YAMLToken(documentAttr, YAMLToken.DOCUMENT_START);
  IToken documentEndToken = new YAMLToken(documentAttr, YAMLToken.DOCUMENT_END);
  IToken anchorToken = new YAMLToken(anchorAttr, YAMLToken.ANCHOR);
  IToken aliasToken = new YAMLToken(aliasAttr, YAMLToken.ALIAS);
  IToken indicatorCharToken = new YAMLToken(new TextAttribute(null), YAMLToken.INDICATOR_CHARACTER);
  IToken tagPropToken = new YAMLToken(tagAttr, YAMLToken.TAG_PROPERTY);
  IToken predefinedValToken = new YAMLToken(constantAttr, YAMLToken.CONSTANT);
  IToken whitespaceToken = new YAMLToken(new TextAttribute(null), YAMLToken.WHITESPACE);
  IToken directiveToken = new YAMLToken(new TextAttribute(null), YAMLToken.DIRECTIVE);

代码示例来源:origin: oyse/yedit

IToken keyToken = new YAMLToken(keyAttr, YAMLToken.KEY);
    PreferenceConstants.ITALIC_SCALAR,
    PreferenceConstants.UNDERLINE_SCALAR);
IToken scalarToken = new YAMLToken(scalarAttr, YAMLToken.SCALAR);
    PreferenceConstants.ITALIC_COMMENT,
    PreferenceConstants.UNDERLINE_COMMENT);
IToken commentToken = new YAMLToken(commentAttr, YAMLToken.COMMENT);
IToken documentStartToken = new YAMLToken(documentAttr, YAMLToken.DOCUMENT_START);
IToken documentEndToken = new YAMLToken(documentAttr, YAMLToken.DOCUMENT_END);
    PreferenceConstants.ITALIC_ANCHOR,
    PreferenceConstants.UNDERLINE_ANCHOR);
IToken anchorToken = new YAMLToken(anchorAttr, YAMLToken.ANCHOR);
    PreferenceConstants.ITALIC_ALIAS,
    PreferenceConstants.UNDERLINE_ALIAS);
IToken aliasToken = new YAMLToken(aliasAttr, YAMLToken.ALIAS);
IToken indicatorCharToken = new YAMLToken(new TextAttribute(null),
    YAMLToken.INDICATOR_CHARACTER);
    PreferenceConstants.ITALIC_TAG_PROPERTY,
    PreferenceConstants.UNDERLINE_TAG_PROPERTY);
IToken tagPropToken = new YAMLToken(tagAttr, YAMLToken.TAG_PROPERTY);
    PreferenceConstants.ITALIC_CONSTANT,

代码示例来源:origin: oyse/yedit

if( yt.getTokenType() == YAMLToken.SCALAR && !startsWithQuote( tokenString ) ){
  YEditLog.logger.info( "Replacing characters in string " + tokenString );                        
  Matcher m = replaceCharPattern.matcher(tokenString);

相关文章