/** * Returns a newly-created {@link Entry} of a JSON file. * * @param revision the revision of the JSON file * @param path the path of the JSON file * @param content the content of the JSON file */ public static Entry<JsonNode> ofJson(Revision revision, String path, JsonNode content) { return new Entry<>(revision, path, EntryType.JSON, content); }
/** * Returns a newly-created {@link Entry} of a directory. * * @param revision the revision of the directory * @param path the path of the directory */ public static Entry<Void> ofDirectory(Revision revision, String path) { return new Entry<>(revision, path, EntryType.DIRECTORY, null); }
/** * Returns a newly-created {@link Entry} of a directory. * * @param revision the revision of the directory * @param path the path of the directory */ public static Entry<Void> ofDirectory(Revision revision, String path) { return new Entry<>(revision, path, EntryType.DIRECTORY, null); }
/** * Returns a newly-created {@link Entry} of a text file. * * @param revision the revision of the text file * @param path the path of the text file * @param content the content of the text file */ public static Entry<String> ofText(Revision revision, String path, String content) { return new Entry<>(revision, path, EntryType.TEXT, content); }
/** * Returns a newly-created {@link Entry} of a JSON file. * * @param revision the revision of the JSON file * @param path the path of the JSON file * @param content the content of the JSON file */ public static Entry<JsonNode> ofJson(Revision revision, String path, JsonNode content) { return new Entry<>(revision, path, EntryType.JSON, content); }
/** * Returns a newly-created {@link Entry} of a text file. * * @param revision the revision of the text file * @param path the path of the text file * @param content the content of the text file */ public static Entry<String> ofText(Revision revision, String path, String content) { return new Entry<>(revision, path, EntryType.TEXT, content); }
/** * Returns a newly-created {@link Entry} of a directory. * * @param revision the revision of the directory * @param path the path of the directory */ public static Entry<Void> ofDirectory(Revision revision, String path) { return new Entry<>(revision, path, EntryType.DIRECTORY, null); }
/** * Returns a newly-created {@link Entry} of a JSON file. * * @param revision the revision of the JSON file * @param path the path of the JSON file * @param content the content of the JSON file */ public static Entry<JsonNode> ofJson(Revision revision, String path, JsonNode content) { return new Entry<>(revision, path, EntryType.JSON, content); }
/** * Returns a newly-created {@link Entry} of a text file. * * @param revision the revision of the text file * @param path the path of the text file * @param content the content of the text file */ public static Entry<String> ofText(Revision revision, String path, String content) { return new Entry<>(revision, path, EntryType.TEXT, content); }
/** * Returns a newly-created {@link Entry}. * * @param revision the revision of the {@link Entry} * @param path the path of the {@link Entry} * @param content the content of the {@link Entry} * @param type the type of the {@link Entry} * @param <T> the content type. {@link JsonNode} if JSON. {@link String} if text. */ public static <T> Entry<T> of(Revision revision, String path, EntryType type, @Nullable T content) { return new Entry<>(revision, path, type, content); }
/** * Returns a newly-created {@link Entry}. * * @param revision the revision of the {@link Entry} * @param path the path of the {@link Entry} * @param content the content of the {@link Entry} * @param type the type of the {@link Entry} * @param <T> the content type. {@link JsonNode} if JSON. {@link String} if text. */ public static <T> Entry<T> of(Revision revision, String path, EntryType type, @Nullable T content) { return new Entry<>(revision, path, type, content); }
/** * Returns a newly-created {@link Entry}. * * @param revision the revision of the {@link Entry} * @param path the path of the {@link Entry} * @param content the content of the {@link Entry} * @param type the type of the {@link Entry} * @param <T> the content type. {@link JsonNode} if JSON. {@link String} if text. */ public static <T> Entry<T> of(Revision revision, String path, EntryType type, @Nullable T content) { return new Entry<>(revision, path, type, content); }