Skip to content

[SLI-0160] Create public API for the ShExC to Java translation #160

@thewillyhuman

Description

@thewillyhuman

Introduction

Java translation is from far the most used feature and users ask for an easy way to instantiate this. We propose to add a custom public API aimed to make the java translation process easy.

Proposed solution

// Creating a new ShExC to Java translator.
ShExLTranslator t = new ToJavaShExLTranslator();

// Events will store the list of warnings or errors produced during the compilation.
// Notice, if any error is produced duringthe compilation the outputDir will be empty.
// Else the outputDir will contain all the generated Java files.
List<CompilationEvent> events = t.translate(inputDir, outputDir);

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions