io7m | single-page | multi-page | epub | xstructural 2.1.0
4. Maven Plugin
Previous
Front Matter
Up
6. Schema
Next

# 5. API

- 5.1. Usage
- 5.2. JavaDoc

## 5.1. Usage

### 5.1.1. Usage

    var factory =
      ServiceLoader.load(XSProcessorFactoryType.class)
        .findFirst()
        .orElseThrow(() -> new IllegalStateException("Missing factory service"));

    final var request =
      XSProcessorRequest.builder()
        .setOutputDirectory(Paths.get(...))
        .setSourceFile(Paths.get(...))
        .setTask(Task.TRANSFORM_XHTML)
        .setStylesheet(Stylesheet.SINGLE_FILE)
        .build();

    final var processor = processors.create(request);
    processor.execute();

## 5.2. JavaDoc

1
Please see the included JavaDoc for API reference documentation.
4. Maven Plugin
Previous
Front Matter
Up
6. Schema
Next
io7m | single-page | multi-page | epub | xstructural 2.1.0