Skip to content

Commit

Permalink
Merge pull request #630 from decorators-squad/323
Browse files Browse the repository at this point in the history
#323 Scaffolding for YAML 'loading'
  • Loading branch information
amihaiemil authored Aug 16, 2024
2 parents 18c7275 + fa74210 commit 577391b
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/main/java/com/amihaiemil/eoyaml/YamlMapping.java
Original file line number Diff line number Diff line change
Expand Up @@ -518,4 +518,17 @@ default List<YamlNode> children() {
default JsonObject toJsonObject() {
return (JsonObject) this.accept(new YamlToJsonVisitor());
}

/**
* Turn this YamlMapping to a given Object type ("loading").
* @param clazz Class type of the Object into which this YamlMapping should
* be loaded.
* @param <T> Type of the Object,
* @return Object into which this YamlMapping is loaded.
* @todo #323:60min Implement this method similarly to toJsonObject(),
* using a visitor.
*/
default <T> T toObject(final Class<T> clazz) {
return null;
}
}

0 comments on commit 577391b

Please sign in to comment.