koara-xml

Koara to XML parser written in Java

License

License

GroupId

GroupId

io.koara
ArtifactId

ArtifactId

koara-xml
Last Version

Last Version

0.14.0
Release Date

Release Date

Type

Type

jar
Description

Description

koara-xml
Koara to XML parser written in Java
Source Code Management

Source Code Management

https://github.com/koara/koara-java-xml.git

Download koara-xml

How to add to project

<!-- https://jarcasting.com/artifacts/io.koara/koara-xml/ -->
<dependency>
    <groupId>io.koara</groupId>
    <artifactId>koara-xml</artifactId>
    <version>0.14.0</version>
</dependency>
// https://jarcasting.com/artifacts/io.koara/koara-xml/
implementation 'io.koara:koara-xml:0.14.0'
// https://jarcasting.com/artifacts/io.koara/koara-xml/
implementation ("io.koara:koara-xml:0.14.0")
'io.koara:koara-xml:jar:0.14.0'
<dependency org="io.koara" name="koara-xml" rev="0.14.0">
  <artifact name="koara-xml" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.koara', module='koara-xml', version='0.14.0')
)
libraryDependencies += "io.koara" % "koara-xml" % "0.14.0"
[io.koara/koara-xml "0.14.0"]

Dependencies

compile (1)

Group / Artifact Type Version
io.koara : koara jar 0.14.0

test (2)

Group / Artifact Type Version
junit : junit jar 4.11
org.slf4j : slf4j-nop jar 1.7.12

Project Modules

There are no modules declared in this project.

Koara

Build Status Coverage Status ![Latest Version](https://img.shields.io/maven-central/v/com.codeaddslife.koara/koara-xml.svg?label=Maven Central) License

Koara-java-xml

Koara is a modular lightweight markup language. This project can render the koara AST to Xml in Java.
The AST is created by the core koara parser.

Getting started

  • Download JAR file

  • Gradle

    dependencies {
      compile "com.codeaddslife.koara:koara-xml:0.15.0"
    }
  • Maven

    <dependency>
      <groupId>com.codeaddslife.koara</groupId>
      <artifactId>koara-xml</artifactId>
      <version>0.15.0</version>
    </dependency>

Usage

package demo;

import com.codeaddslife.koara.Parser;
import com.codeaddslife.koara.ast.Document;
import XmlRenderer;

public class App {

	public static void main(String[] args) {
		Parser parser = new Parser();
		Document result = parser.parse("Hello World!");
		XmlRenderer renderer = new XmlRenderer();
		result.accept(renderer);
		System.out.println(renderer.getOutput());
	}
	
}

Configuration

You can configure the Renderer:

  • parser.setHardWrap(boolean hardWrap)
    Default: false

    Specify if newlines should be hard-wrapped (return-based linebreaks) by default.

  • renderer.setDeclarationTag(String declarationTag)
    Default: null

    Add an XML Declaration Tag add the top of the generated output.

io.koara

Koara

A modular lightweight markup language

Versions

Version
0.14.0
0.13.0
0.12.0
0.10
0.9.3
0.9.1