The interfaces that underlie this library.
The value storage handler interface that consumers generally work with is FluentHandler
, which enhances
the core ValueStorageHandler
interface with fluent methods to build variations with additional
constraints.
The options passed to functions in the library are also described as interfaces. The most frequently used is
ValueStorageHandlerOptions
, which are the options passed to the
ValueStorageHandler.storeValue
method to control the storage behavior (e.g., to map property names
to file names, etc.).
The FileWriter
and DirectoryCreator
interfaces are the low-level abstractions over the
underlying runtime platform. Deno and Node.js/Bun have implementations built into the library, but it is possible
to write additional implementations over other file system-like media and use them with the library.
Options that apply specifically to the array to directory builder method:
HandlerBuilder.arrayToDirectory
.
Options specific to the HandlerBuilder.customFile
method.
Interface of a directory creator, that can asynchronously create a new directory.
Options passed to the DirectoryCreator
createDirectory
method.
The common options passed to the file handler builder methods on interface HandlerBuilder
.
Interface of a writer that can write text files from strings and Uint8Array
s to the file system.
Extension of the value storage handler with a fluent API for convenience.
A fluent builder interface for creating value storage handlers handlers.
Options that apply to the directory-related builder methods: HandlerBuilder.arrayToDirectory
and
HandlerBuilder.objectToDirectory
.
Interface implemented by objects that can store values to files or directories.
Options passed to the ValueStorageHandler storeValueToFile
method.
Our own equivalent to the Node.js Abortable
interface. Unfortunately, the Deno and Node.js
AbortSignal
types aren't completely identical, so using Abortable
directly causes
type checking issues.
The signature expected of the custom canStoreValue
implementation passed to the
HandlerBuilder.customFile
method.
The signature expected of serializer functions passed to the HandlerBuilder.customFile
method.
Add Package
deno add jsr:@scroogieboy/object-to-directory
Import symbol
import * as mod from "@scroogieboy/object-to-directory/interfaces";
---- OR ----
Import directly with a jsr specifier
import * as mod from "jsr:@scroogieboy/object-to-directory/interfaces";
Add Package
npx jsr add @scroogieboy/object-to-directory
Import symbol
import * as mod from "@scroogieboy/object-to-directory/interfaces";
Add Package
yarn dlx jsr add @scroogieboy/object-to-directory
Import symbol
import * as mod from "@scroogieboy/object-to-directory/interfaces";
Add Package
pnpm dlx jsr add @scroogieboy/object-to-directory
Import symbol
import * as mod from "@scroogieboy/object-to-directory/interfaces";
Add Package
bunx jsr add @scroogieboy/object-to-directory
Import symbol
import * as mod from "@scroogieboy/object-to-directory/interfaces";