gpt4 book ai didi

org.milyn.yaml.handler.YamlToSaxHandler类的使用及代码示例

转载 作者:知者 更新时间:2024-03-16 00:23:31 27 4
gpt4 key购买 nike

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

YamlToSaxHandler介绍

[英]Converts yaml events into sax events.
[中]将yaml事件转换为sax事件。

代码示例

代码示例来源:origin: smooks/smooks

public void addContentElement(String name, String  value, String anchorName, boolean addAnchorAttribute) throws SAXException {
  indent();
  startElement(name, anchorName, addAnchorAttribute);
  if(value != null && value.length() > 0) {
    contentHandler.characters(value.toCharArray(), 0, value.length());
  }
  endElement(name);
}

代码示例来源:origin: org.milyn/milyn-smooks-yaml

public void endStructureEvent(Event event, String name) throws SAXException {
  contentHandler.endElementStructure(name);
}

代码示例来源:origin: org.milyn/milyn-smooks-all

public void startElementStructure(String name, String anchorName, boolean addAnchorAttribute) throws SAXException {
  indent();
  startElement(name, anchorName, addAnchorAttribute);
  elementLevel++;
}

代码示例来源:origin: smooks/smooks

public void endElementStructure(String name) throws SAXException {
  elementLevel--;
  indent();
  endElement(name);
}

代码示例来源:origin: smooks/smooks

throw new SmooksException("The InputSource doesn't provide a Reader character stream. Make sure that you supply a reader to the Smooks.filterSource method.");
YamlToSaxHandler yamlToSaxHandler = new YamlToSaxHandler(contentHandler, anchorAttributeName, aliasAttributeName, indent);
yamlToSaxHandler.startElementStructure(rootName, null, false);
yamlToSaxHandler.endElementStructure(rootName);

代码示例来源:origin: smooks/smooks

contentHandler.startElementStructure(name, getAnchorName(event), false);
contentHandler.endElementStructure(name);

代码示例来源:origin: smooks/smooks

public void addValueEvent(ScalarEvent event, String name, String value) throws SAXException {
  contentHandler.addContentElement(name, value, event.getAnchor(), true);
}

代码示例来源:origin: smooks/smooks

public void startStructureEvent(CollectionStartEvent event, String name) throws SAXException {
  contentHandler.startElementStructure(name, event.getAnchor(), true);
}

代码示例来源:origin: org.milyn/milyn-smooks-yaml

throw new SmooksException("The InputSource doesn't provide a Reader character stream. Make sure that you supply a reader to the Smooks.filterSource method.");
YamlToSaxHandler yamlToSaxHandler = new YamlToSaxHandler(contentHandler, anchorAttributeName, aliasAttributeName, indent);
yamlToSaxHandler.startElementStructure(rootName, null, false);
yamlToSaxHandler.endElementStructure(rootName);

代码示例来源:origin: smooks/smooks

public void startElementStructure(String name, String anchorName, boolean addAnchorAttribute) throws SAXException {
  indent();
  startElement(name, anchorName, addAnchorAttribute);
  elementLevel++;
}

代码示例来源:origin: org.virtuslab/milyn-smooks-yaml

public void endElementStructure(String name) throws SAXException {
  elementLevel--;
  indent();
  endElement(name);
}

代码示例来源:origin: org.milyn/milyn-smooks-yaml

contentHandler.startElementStructure(name, getAnchorName(event), false);
contentHandler.endElementStructure(name);

代码示例来源:origin: smooks/smooks

public void addAliasEvent(AliasEvent event, String name) throws SAXException {
  contentHandler.addContentElement(name, null, event.getAnchor(), false);
}

代码示例来源:origin: org.milyn/milyn-smooks-all

public void startStructureEvent(CollectionStartEvent event, String name) throws SAXException {
  contentHandler.startElementStructure(name, event.getAnchor(), true);
}

代码示例来源:origin: org.milyn/milyn-smooks-all

public void addContentElement(String name, String  value, String anchorName, boolean addAnchorAttribute) throws SAXException {
  indent();
  startElement(name, anchorName, addAnchorAttribute);
  if(value != null && value.length() > 0) {
    contentHandler.characters(value.toCharArray(), 0, value.length());
  }
  endElement(name);
}

代码示例来源:origin: org.virtuslab/milyn-smooks-yaml

throw new SmooksException("The InputSource doesn't provide a Reader character stream. Make sure that you supply a reader to the Smooks.filterSource method.");
YamlToSaxHandler yamlToSaxHandler = new YamlToSaxHandler(contentHandler, anchorAttributeName, aliasAttributeName, indent);
yamlToSaxHandler.startElementStructure(rootName, null, false);
yamlToSaxHandler.endElementStructure(rootName);

代码示例来源:origin: org.milyn/milyn-smooks-yaml

public void startElementStructure(String name, String anchorName, boolean addAnchorAttribute) throws SAXException {
  indent();
  startElement(name, anchorName, addAnchorAttribute);
  elementLevel++;
}

代码示例来源:origin: org.milyn/milyn-smooks-yaml

public void endElementStructure(String name) throws SAXException {
  elementLevel--;
  indent();
  endElement(name);
}

代码示例来源:origin: org.milyn/milyn-smooks-all

contentHandler.startElementStructure(name, getAnchorName(event), false);
contentHandler.endElementStructure(name);

代码示例来源:origin: org.milyn/milyn-smooks-yaml

public void addAliasEvent(AliasEvent event, String name) throws SAXException {
  contentHandler.addContentElement(name, null, event.getAnchor(), false);
}

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com