Dave Jarvis' Repositories

git clone https://repo.autonoma.ca/repo/keenwrite.git

Invoke launcher, separate headless app from gui app

AuthorDaveJarvis <email>
Date2021-12-04 19:45:31 GMT-0800
Commit0ab1a3dd14228129c1f3f985e52e090cd0c003c6
Parentde88463
Delta19 lines added, 3 lines removed, 16-line increase
src/main/java/com/keenwrite/dom/DocumentConverter.java
package com.keenwrite.dom;
+import org.jetbrains.annotations.NotNull;
import org.jsoup.helper.W3CDom;
import org.jsoup.nodes.Node;
private static final NodeVisitor LIGATURE_VISITOR = new NodeVisitor() {
@Override
- public void head( final Node node, final int depth ) {
+ public void head( final @NotNull Node node, final int depth ) {
if( node instanceof final TextNode textNode ) {
final var parent = node.parentNode();
@Override
- public void tail( final Node node, final int depth ) {
+ public void tail( final @NotNull Node node, final int depth ) {
}
};
@Override
- public Document fromJsoup( final org.jsoup.nodes.Document in ) {
+ public @NotNull Document fromJsoup( final org.jsoup.nodes.Document in ) {
assert in != null;
src/main/java/com/keenwrite/cmdline/HeadlessApp.java
+package com.keenwrite.cmdline;
+
+/**
+ * Responsible for running the application in headless mode.
+ */
+public class HeadlessApp {
+
+ /**
+ * Entry point for running the application in headless mode.
+ *
+ * @param args The parsed command-line arguments.
+ */
+ public static void main( final Arguments args ) {
+ }
+}