@duplojs/server 0.0.0-stage → 0.1.0-beta.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -2
- package/dist/_virtual/_rolldown/runtime.cjs +33 -0
- package/dist/_virtual/_rolldown/runtime.mjs +17 -0
- package/dist/command/argument.cjs +27 -0
- package/dist/command/argument.d.ts +18 -0
- package/dist/command/argument.mjs +24 -0
- package/dist/command/create.cjs +102 -0
- package/dist/command/create.d.ts +47 -0
- package/dist/command/create.mjs +96 -0
- package/dist/command/error.cjs +206 -0
- package/dist/command/error.d.ts +61 -0
- package/dist/command/error.mjs +193 -0
- package/dist/command/exec.cjs +19 -0
- package/dist/command/exec.d.ts +14 -0
- package/dist/command/exec.mjs +17 -0
- package/dist/command/execOptions.cjs +41 -0
- package/dist/command/execOptions.d.ts +14 -0
- package/dist/command/execOptions.mjs +37 -0
- package/dist/command/help.cjs +250 -0
- package/dist/command/help.d.ts +10 -0
- package/dist/command/help.mjs +237 -0
- package/dist/command/index.cjs +82 -0
- package/dist/command/index.d.ts +8 -0
- package/dist/command/index.mjs +47 -0
- package/dist/command/kind.cjs +7 -0
- package/dist/command/kind.d.ts +2 -0
- package/dist/command/kind.mjs +5 -0
- package/dist/command/options/base.cjs +76 -0
- package/dist/command/options/base.d.ts +30 -0
- package/dist/command/options/base.mjs +69 -0
- package/dist/command/options/defaults/array.cjs +35 -0
- package/dist/command/options/defaults/array.d.ts +26 -0
- package/dist/command/options/defaults/array.mjs +29 -0
- package/dist/command/options/defaults/boolean.cjs +28 -0
- package/dist/command/options/defaults/boolean.d.ts +14 -0
- package/dist/command/options/defaults/boolean.mjs +25 -0
- package/dist/command/options/defaults/index.d.ts +3 -0
- package/dist/command/options/defaults/simple.cjs +25 -0
- package/dist/command/options/defaults/simple.d.ts +18 -0
- package/dist/command/options/defaults/simple.mjs +22 -0
- package/dist/command/options/identifier.cjs +7 -0
- package/dist/command/options/identifier.d.ts +4 -0
- package/dist/command/options/identifier.mjs +5 -0
- package/dist/command/options/index.d.ts +4 -0
- package/dist/command/options/types/index.d.ts +1 -0
- package/dist/command/options/types/options.d.ts +9 -0
- package/dist/command/types/eligibleType.d.ts +4 -0
- package/dist/command/types/forbiddenDuplicateName.d.ts +11 -0
- package/dist/command/types/forbiddenInvalidIdentifier.d.ts +6 -0
- package/dist/command/types/index.d.ts +3 -0
- package/dist/common/environmentVariable/expandEnvironmentVariables.cjs +27 -0
- package/dist/common/environmentVariable/expandEnvironmentVariables.d.ts +2 -0
- package/dist/common/environmentVariable/expandEnvironmentVariables.mjs +22 -0
- package/dist/common/environmentVariable/index.cjs +47 -0
- package/dist/common/environmentVariable/index.d.ts +16 -0
- package/dist/common/environmentVariable/index.mjs +41 -0
- package/dist/common/environmentVariable/overrideEnvironmentVariables.cjs +13 -0
- package/dist/common/environmentVariable/overrideEnvironmentVariables.d.ts +3 -0
- package/dist/common/environmentVariable/overrideEnvironmentVariables.mjs +9 -0
- package/dist/common/environmentVariable/parseEnvironmentFiles.cjs +32 -0
- package/dist/common/environmentVariable/parseEnvironmentFiles.d.ts +5 -0
- package/dist/common/environmentVariable/parseEnvironmentFiles.mjs +26 -0
- package/dist/common/environmentVariableOrThrow.cjs +23 -0
- package/dist/common/environmentVariableOrThrow.d.ts +12 -0
- package/dist/common/environmentVariableOrThrow.mjs +19 -0
- package/dist/common/exitProcess.cjs +7 -0
- package/dist/common/exitProcess.d.ts +6 -0
- package/dist/common/exitProcess.mjs +8 -0
- package/dist/common/getCurrentWorkDirectory.cjs +15 -0
- package/dist/common/getCurrentWorkDirectory.d.ts +8 -0
- package/dist/common/getCurrentWorkDirectory.mjs +11 -0
- package/dist/common/getCurrentWorkDirectoryOrThrow.cjs +25 -0
- package/dist/common/getCurrentWorkDirectoryOrThrow.d.ts +8 -0
- package/dist/common/getCurrentWorkDirectoryOrThrow.mjs +20 -0
- package/dist/common/getProcessArguments.cjs +18 -0
- package/dist/common/getProcessArguments.d.ts +6 -0
- package/dist/common/getProcessArguments.mjs +18 -0
- package/dist/common/index.cjs +44 -0
- package/dist/common/index.d.ts +9 -0
- package/dist/common/index.mjs +27 -0
- package/dist/common/meta/getCurrentDirectoryName.cjs +10 -0
- package/dist/common/meta/getCurrentDirectoryName.d.ts +7 -0
- package/dist/common/meta/getCurrentDirectoryName.mjs +7 -0
- package/dist/common/meta/index.d.ts +7 -0
- package/dist/common/setCurrentWorkingDirectory.cjs +11 -0
- package/dist/common/setCurrentWorkingDirectory.d.ts +8 -0
- package/dist/common/setCurrentWorkingDirectory.mjs +9 -0
- package/dist/common/setCurrentWorkingDirectoryOrThrow.cjs +23 -0
- package/dist/common/setCurrentWorkingDirectoryOrThrow.d.ts +8 -0
- package/dist/common/setCurrentWorkingDirectoryOrThrow.mjs +18 -0
- package/dist/dataStructure/common/codec/defaults/index.d.ts +2 -0
- package/dist/dataStructure/common/codec/defaults/json.cjs +25 -0
- package/dist/dataStructure/common/codec/defaults/json.d.ts +9 -0
- package/dist/dataStructure/common/codec/defaults/json.mjs +22 -0
- package/dist/dataStructure/common/codec/defaults/string.cjs +25 -0
- package/dist/dataStructure/common/codec/defaults/string.d.ts +13 -0
- package/dist/dataStructure/common/codec/defaults/string.mjs +22 -0
- package/dist/dataStructure/common/codec/index.d.ts +1 -0
- package/dist/dataStructure/common/error/defaultInterpreter.cjs +29 -0
- package/dist/dataStructure/common/error/defaultInterpreter.d.ts +69 -0
- package/dist/dataStructure/common/error/defaultInterpreter.mjs +26 -0
- package/dist/dataStructure/common/error/index.d.ts +1 -0
- package/dist/dataStructure/common/index.d.ts +2 -0
- package/dist/dataStructure/constraint/fileExist.cjs +19 -0
- package/dist/dataStructure/constraint/fileExist.d.ts +10 -0
- package/dist/dataStructure/constraint/fileExist.mjs +15 -0
- package/dist/dataStructure/constraint/folderExist.cjs +19 -0
- package/dist/dataStructure/constraint/folderExist.d.ts +10 -0
- package/dist/dataStructure/constraint/folderExist.mjs +15 -0
- package/dist/dataStructure/constraint/index.d.ts +5 -0
- package/dist/dataStructure/constraint/mimeType.cjs +18 -0
- package/dist/dataStructure/constraint/mimeType.d.ts +11 -0
- package/dist/dataStructure/constraint/mimeType.mjs +14 -0
- package/dist/dataStructure/constraint/size.cjs +29 -0
- package/dist/dataStructure/constraint/size.d.ts +16 -0
- package/dist/dataStructure/constraint/size.mjs +24 -0
- package/dist/dataStructure/constraint/types/constraints.d.ts +12 -0
- package/dist/dataStructure/constraint/types/index.d.ts +1 -0
- package/dist/dataStructure/fundamentalType/file.cjs +11 -0
- package/dist/dataStructure/fundamentalType/file.d.ts +8 -0
- package/dist/dataStructure/fundamentalType/file.mjs +8 -0
- package/dist/dataStructure/fundamentalType/folder.cjs +11 -0
- package/dist/dataStructure/fundamentalType/folder.d.ts +8 -0
- package/dist/dataStructure/fundamentalType/folder.mjs +8 -0
- package/dist/dataStructure/fundamentalType/index.d.ts +3 -0
- package/dist/dataStructure/fundamentalType/types/fundamentalTypes.d.ts +8 -0
- package/dist/dataStructure/fundamentalType/types/index.d.ts +1 -0
- package/dist/dataStructure/helper/file.cjs +10 -0
- package/dist/dataStructure/helper/file.d.ts +3 -0
- package/dist/dataStructure/helper/file.mjs +8 -0
- package/dist/dataStructure/helper/fileExist.cjs +7 -0
- package/dist/dataStructure/helper/fileExist.d.ts +2 -0
- package/dist/dataStructure/helper/fileExist.mjs +7 -0
- package/dist/dataStructure/helper/folder.cjs +10 -0
- package/dist/dataStructure/helper/folder.d.ts +3 -0
- package/dist/dataStructure/helper/folder.mjs +8 -0
- package/dist/dataStructure/helper/folderExist.cjs +7 -0
- package/dist/dataStructure/helper/folderExist.d.ts +2 -0
- package/dist/dataStructure/helper/folderExist.mjs +7 -0
- package/dist/dataStructure/helper/index.d.ts +6 -0
- package/dist/dataStructure/helper/mimeType.cjs +7 -0
- package/dist/dataStructure/helper/mimeType.d.ts +2 -0
- package/dist/dataStructure/helper/mimeType.mjs +7 -0
- package/dist/dataStructure/helper/size.cjs +7 -0
- package/dist/dataStructure/helper/size.d.ts +2 -0
- package/dist/dataStructure/helper/size.mjs +7 -0
- package/dist/dataStructure/index.cjs +83 -0
- package/dist/dataStructure/index.d.ts +6 -0
- package/dist/dataStructure/index.mjs +51 -0
- package/dist/dataStructure/kind.cjs +7 -0
- package/dist/dataStructure/kind.d.ts +2 -0
- package/dist/dataStructure/kind.mjs +5 -0
- package/dist/dataStructure/type/file.cjs +14 -0
- package/dist/dataStructure/type/file.d.ts +11 -0
- package/dist/dataStructure/type/file.mjs +11 -0
- package/dist/dataStructure/type/folder.cjs +14 -0
- package/dist/dataStructure/type/folder.d.ts +11 -0
- package/dist/dataStructure/type/folder.mjs +11 -0
- package/dist/dataStructure/type/index.d.ts +3 -0
- package/dist/dataStructure/type/types/index.d.ts +1 -0
- package/dist/dataStructure/type/types/types.d.ts +8 -0
- package/dist/file/appendFile.cjs +67 -0
- package/dist/file/appendFile.d.ts +43 -0
- package/dist/file/appendFile.mjs +54 -0
- package/dist/file/appendTextFile.cjs +67 -0
- package/dist/file/appendTextFile.d.ts +43 -0
- package/dist/file/appendTextFile.mjs +54 -0
- package/dist/file/copy.cjs +53 -0
- package/dist/file/copy.d.ts +43 -0
- package/dist/file/copy.mjs +40 -0
- package/dist/file/createEntryInterface.cjs +19 -0
- package/dist/file/createEntryInterface.d.ts +3 -0
- package/dist/file/createEntryInterface.mjs +15 -0
- package/dist/file/ensureDirectory.cjs +52 -0
- package/dist/file/ensureDirectory.d.ts +36 -0
- package/dist/file/ensureDirectory.mjs +41 -0
- package/dist/file/ensureFile.cjs +60 -0
- package/dist/file/ensureFile.d.ts +39 -0
- package/dist/file/ensureFile.mjs +48 -0
- package/dist/file/exists.cjs +43 -0
- package/dist/file/exists.d.ts +27 -0
- package/dist/file/exists.mjs +35 -0
- package/dist/file/fileInterface.cjs +76 -0
- package/dist/file/fileInterface.d.ts +31 -0
- package/dist/file/fileInterface.mjs +70 -0
- package/dist/file/folderInterface.cjs +76 -0
- package/dist/file/folderInterface.d.ts +33 -0
- package/dist/file/folderInterface.mjs +70 -0
- package/dist/file/index.cjs +634 -0
- package/dist/file/index.d.ts +35 -0
- package/dist/file/index.mjs +335 -0
- package/dist/file/link.cjs +70 -0
- package/dist/file/link.d.ts +46 -0
- package/dist/file/link.mjs +56 -0
- package/dist/file/linkStat.cjs +98 -0
- package/dist/file/linkStat.d.ts +31 -0
- package/dist/file/linkStat.mjs +88 -0
- package/dist/file/makeDirectory.cjs +60 -0
- package/dist/file/makeDirectory.d.ts +45 -0
- package/dist/file/makeDirectory.mjs +47 -0
- package/dist/file/makeTemporaryDirectory.cjs +48 -0
- package/dist/file/makeTemporaryDirectory.d.ts +32 -0
- package/dist/file/makeTemporaryDirectory.mjs +38 -0
- package/dist/file/makeTemporaryFile.cjs +62 -0
- package/dist/file/makeTemporaryFile.d.ts +36 -0
- package/dist/file/makeTemporaryFile.mjs +50 -0
- package/dist/file/move.cjs +71 -0
- package/dist/file/move.d.ts +46 -0
- package/dist/file/move.mjs +57 -0
- package/dist/file/readDirectory.cjs +44 -0
- package/dist/file/readDirectory.d.ts +35 -0
- package/dist/file/readDirectory.mjs +33 -0
- package/dist/file/readFile.cjs +51 -0
- package/dist/file/readFile.d.ts +33 -0
- package/dist/file/readFile.mjs +41 -0
- package/dist/file/readJsonFile.cjs +51 -0
- package/dist/file/readJsonFile.d.ts +33 -0
- package/dist/file/readJsonFile.mjs +41 -0
- package/dist/file/readLink.cjs +46 -0
- package/dist/file/readLink.d.ts +30 -0
- package/dist/file/readLink.mjs +37 -0
- package/dist/file/readTextFile.cjs +51 -0
- package/dist/file/readTextFile.d.ts +33 -0
- package/dist/file/readTextFile.mjs +41 -0
- package/dist/file/realPath.cjs +42 -0
- package/dist/file/realPath.d.ts +27 -0
- package/dist/file/realPath.mjs +34 -0
- package/dist/file/relocate.cjs +83 -0
- package/dist/file/relocate.d.ts +46 -0
- package/dist/file/relocate.mjs +68 -0
- package/dist/file/remove.cjs +60 -0
- package/dist/file/remove.d.ts +42 -0
- package/dist/file/remove.mjs +48 -0
- package/dist/file/rename.cjs +83 -0
- package/dist/file/rename.d.ts +46 -0
- package/dist/file/rename.mjs +68 -0
- package/dist/file/setMode.cjs +65 -0
- package/dist/file/setMode.d.ts +45 -0
- package/dist/file/setMode.mjs +56 -0
- package/dist/file/setOwner.cjs +53 -0
- package/dist/file/setOwner.d.ts +35 -0
- package/dist/file/setOwner.mjs +44 -0
- package/dist/file/setTime.cjs +55 -0
- package/dist/file/setTime.d.ts +36 -0
- package/dist/file/setTime.mjs +45 -0
- package/dist/file/stat.cjs +99 -0
- package/dist/file/stat.d.ts +62 -0
- package/dist/file/stat.mjs +89 -0
- package/dist/file/symlink.cjs +64 -0
- package/dist/file/symlink.d.ts +48 -0
- package/dist/file/symlink.mjs +52 -0
- package/dist/file/truncate.cjs +60 -0
- package/dist/file/truncate.d.ts +42 -0
- package/dist/file/truncate.mjs +47 -0
- package/dist/file/unknownEntryInterface.cjs +40 -0
- package/dist/file/unknownEntryInterface.d.ts +17 -0
- package/dist/file/unknownEntryInterface.mjs +35 -0
- package/dist/file/walkDirectory.cjs +57 -0
- package/dist/file/walkDirectory.d.ts +37 -0
- package/dist/file/walkDirectory.mjs +45 -0
- package/dist/file/writeFile.cjs +68 -0
- package/dist/file/writeFile.d.ts +43 -0
- package/dist/file/writeFile.mjs +55 -0
- package/dist/file/writeJsonFile.cjs +77 -0
- package/dist/file/writeJsonFile.d.ts +46 -0
- package/dist/file/writeJsonFile.mjs +64 -0
- package/dist/file/writeTextFile.cjs +68 -0
- package/dist/file/writeTextFile.d.ts +43 -0
- package/dist/file/writeTextFile.mjs +55 -0
- package/dist/implementor.cjs +67 -0
- package/dist/implementor.d.ts +35 -0
- package/dist/implementor.mjs +55 -0
- package/dist/index.cjs +76 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.mjs +15 -0
- package/dist/kind.cjs +7 -0
- package/dist/kind.d.ts +2 -0
- package/dist/kind.mjs +5 -0
- package/dist/override.d.ts +8 -0
- package/package.json +81 -3
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { codecsJson } from "../codec/defaults/json.mjs";
|
|
2
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
3
|
+
//#region scripts/dataStructure/common/error/defaultInterpreter.ts
|
|
4
|
+
const defaultErrorInterpreterDataStructureDictionary = {
|
|
5
|
+
...DDataStructure.defaultErrorInterpreterDataStructureDictionary,
|
|
6
|
+
"@DuplojsServerDataStructure/file-type": () => "Expected a valid file.",
|
|
7
|
+
"@DuplojsServerDataStructure/folder-type": () => "Expected a valid folder.",
|
|
8
|
+
"@DuplojsServerDataStructure/size-constraint": (source) => {
|
|
9
|
+
const { min, max } = source.definition;
|
|
10
|
+
if (min !== void 0 && max !== void 0) return `Expected a file size between ${min} and ${max} bytes.`;
|
|
11
|
+
if (min !== void 0) return `Expected a file size of at least ${min} bytes.`;
|
|
12
|
+
if (max !== void 0) return `Expected a file size of at most ${max} bytes.`;
|
|
13
|
+
return "Expected a valid file size.";
|
|
14
|
+
},
|
|
15
|
+
"@DuplojsServerDataStructure/mime-type-constraint": (source) => `Expected a file with a MIME type matching ${source.definition.regex.toString()}.`,
|
|
16
|
+
"@DuplojsServerDataStructure/file-exist-constraint": () => "Expected the file to exist.",
|
|
17
|
+
"@DuplojsServerDataStructure/folder-exist-constraint": () => "Expected the folder to exist."
|
|
18
|
+
};
|
|
19
|
+
const defaultErrorInterpreterCodecDictionary = [...DDataStructure.defaultErrorInterpreterCodecDictionary, [codecsJson.definition.file, (_codec, issue) => {
|
|
20
|
+
if (issue.from === "predicate") return DDataStructure.encodeIssueKind.has(issue) ? "The JSON file codec must produce a valid file path string." : "Expected a valid file path string for the JSON file codec.";
|
|
21
|
+
if (issue.from === "encoding") return "The JSON file codec could not encode the file.";
|
|
22
|
+
if (issue.from === "decoding") return "The JSON file codec could not decode the value as a file.";
|
|
23
|
+
return `The JSON file codec encountered an external error while ${DDataStructure.encodeIssueKind.has(issue) ? "encoding" : "decoding"}.`;
|
|
24
|
+
}]];
|
|
25
|
+
//#endregion
|
|
26
|
+
export { defaultErrorInterpreterCodecDictionary, defaultErrorInterpreterDataStructureDictionary };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './defaultInterpreter';
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_kind = require("../kind.cjs");
|
|
3
|
+
let _duplojs_lang_either = require("@duplojs/lang/either");
|
|
4
|
+
_duplojs_lang_either = require_runtime.__toESM(_duplojs_lang_either, 1);
|
|
5
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
6
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
7
|
+
//#region scripts/dataStructure/constraint/fileExist.ts
|
|
8
|
+
const fileExistConstraintKind = require_kind.createKind("file-exist-constraint");
|
|
9
|
+
const FileExistConstraint = _duplojs_lang_dataStructure.createConstraint(fileExistConstraintKind, ({ init }) => () => init({}, {
|
|
10
|
+
executeCheck: async (_self, data) => {
|
|
11
|
+
const result = _duplojs_lang_either.rightPipe(await data.stat(), (stat) => stat.isFile ? stat : _duplojs_lang_either.fail());
|
|
12
|
+
if (_duplojs_lang_either.isLeft(result)) return _duplojs_lang_dataStructure.ErrorSymbol;
|
|
13
|
+
return _duplojs_lang_dataStructure.SuccessSymbol;
|
|
14
|
+
},
|
|
15
|
+
isAsynchronous: () => true
|
|
16
|
+
}));
|
|
17
|
+
//#endregion
|
|
18
|
+
exports.FileExistConstraint = FileExistConstraint;
|
|
19
|
+
exports.fileExistConstraintKind = fileExistConstraintKind;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type * as DCommon from "@duplojs/lang/common";
|
|
2
|
+
import type * as DKind from "@duplojs/lang/kind";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
import type * as DSFile from '../../file';
|
|
5
|
+
export declare const fileExistConstraintKind: DKind.Handler<DKind.Definition<"@DuplojsServerDataStructure/file-exist-constraint", unknown>>;
|
|
6
|
+
export interface FileExistConstraintDefinition extends DDataStructure.ConstraintDefinition {
|
|
7
|
+
}
|
|
8
|
+
export interface FileExistConstraint extends DCommon.UnionToIntersection<DDataStructure.Constraint<DSFile.FileInterface, DSFile.FileInterface, FileExistConstraintDefinition> & DKind.Kind<typeof fileExistConstraintKind>> {
|
|
9
|
+
}
|
|
10
|
+
export declare const FileExistConstraint: () => FileExistConstraint;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createKind } from "../kind.mjs";
|
|
2
|
+
import * as DEither from "@duplojs/lang/either";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
//#region scripts/dataStructure/constraint/fileExist.ts
|
|
5
|
+
const fileExistConstraintKind = createKind("file-exist-constraint");
|
|
6
|
+
const FileExistConstraint = DDataStructure.createConstraint(fileExistConstraintKind, ({ init }) => () => init({}, {
|
|
7
|
+
executeCheck: async (_self, data) => {
|
|
8
|
+
const result = DEither.rightPipe(await data.stat(), (stat) => stat.isFile ? stat : DEither.fail());
|
|
9
|
+
if (DEither.isLeft(result)) return DDataStructure.ErrorSymbol;
|
|
10
|
+
return DDataStructure.SuccessSymbol;
|
|
11
|
+
},
|
|
12
|
+
isAsynchronous: () => true
|
|
13
|
+
}));
|
|
14
|
+
//#endregion
|
|
15
|
+
export { FileExistConstraint, fileExistConstraintKind };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_kind = require("../kind.cjs");
|
|
3
|
+
let _duplojs_lang_either = require("@duplojs/lang/either");
|
|
4
|
+
_duplojs_lang_either = require_runtime.__toESM(_duplojs_lang_either, 1);
|
|
5
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
6
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
7
|
+
//#region scripts/dataStructure/constraint/folderExist.ts
|
|
8
|
+
const folderExistConstraintKind = require_kind.createKind("folder-exist-constraint");
|
|
9
|
+
const FolderExistConstraint = _duplojs_lang_dataStructure.createConstraint(folderExistConstraintKind, ({ init }) => () => init({}, {
|
|
10
|
+
executeCheck: async (_self, data) => {
|
|
11
|
+
const result = _duplojs_lang_either.rightPipe(await data.stat(), (stat) => stat.isDirectory ? stat : _duplojs_lang_either.fail());
|
|
12
|
+
if (_duplojs_lang_either.isLeft(result)) return _duplojs_lang_dataStructure.ErrorSymbol;
|
|
13
|
+
return _duplojs_lang_dataStructure.SuccessSymbol;
|
|
14
|
+
},
|
|
15
|
+
isAsynchronous: () => true
|
|
16
|
+
}));
|
|
17
|
+
//#endregion
|
|
18
|
+
exports.FolderExistConstraint = FolderExistConstraint;
|
|
19
|
+
exports.folderExistConstraintKind = folderExistConstraintKind;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type * as DCommon from "@duplojs/lang/common";
|
|
2
|
+
import type * as DKind from "@duplojs/lang/kind";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
import type * as DSFile from '../../file';
|
|
5
|
+
export declare const folderExistConstraintKind: DKind.Handler<DKind.Definition<"@DuplojsServerDataStructure/folder-exist-constraint", unknown>>;
|
|
6
|
+
export interface FolderExistConstraintDefinition extends DDataStructure.ConstraintDefinition {
|
|
7
|
+
}
|
|
8
|
+
export interface FolderExistConstraint extends DCommon.UnionToIntersection<DDataStructure.Constraint<DSFile.FolderInterface, DSFile.FolderInterface, FolderExistConstraintDefinition> & DKind.Kind<typeof folderExistConstraintKind>> {
|
|
9
|
+
}
|
|
10
|
+
export declare const FolderExistConstraint: () => FolderExistConstraint;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createKind } from "../kind.mjs";
|
|
2
|
+
import * as DEither from "@duplojs/lang/either";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
//#region scripts/dataStructure/constraint/folderExist.ts
|
|
5
|
+
const folderExistConstraintKind = createKind("folder-exist-constraint");
|
|
6
|
+
const FolderExistConstraint = DDataStructure.createConstraint(folderExistConstraintKind, ({ init }) => () => init({}, {
|
|
7
|
+
executeCheck: async (_self, data) => {
|
|
8
|
+
const result = DEither.rightPipe(await data.stat(), (stat) => stat.isDirectory ? stat : DEither.fail());
|
|
9
|
+
if (DEither.isLeft(result)) return DDataStructure.ErrorSymbol;
|
|
10
|
+
return DDataStructure.SuccessSymbol;
|
|
11
|
+
},
|
|
12
|
+
isAsynchronous: () => true
|
|
13
|
+
}));
|
|
14
|
+
//#endregion
|
|
15
|
+
export { FolderExistConstraint, folderExistConstraintKind };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_kind = require("../kind.cjs");
|
|
3
|
+
let _duplojs_lang_common = require("@duplojs/lang/common");
|
|
4
|
+
_duplojs_lang_common = require_runtime.__toESM(_duplojs_lang_common, 1);
|
|
5
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
6
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
7
|
+
//#region scripts/dataStructure/constraint/mimeType.ts
|
|
8
|
+
const mimeTypeConstraintKind = require_kind.createKind("mime-type-constraint");
|
|
9
|
+
const MimeTypeConstraint = _duplojs_lang_dataStructure.createConstraint(mimeTypeConstraintKind, ({ init }) => (mimeType) => init({ regex: _duplojs_lang_common.toRegExp(mimeType) }, {
|
|
10
|
+
executeCheck: (self, data) => {
|
|
11
|
+
if (!self.definition.regex.test(data.getMimeType() ?? "")) return _duplojs_lang_dataStructure.ErrorSymbol;
|
|
12
|
+
return _duplojs_lang_dataStructure.SuccessSymbol;
|
|
13
|
+
},
|
|
14
|
+
isAsynchronous: () => false
|
|
15
|
+
}));
|
|
16
|
+
//#endregion
|
|
17
|
+
exports.MimeTypeConstraint = MimeTypeConstraint;
|
|
18
|
+
exports.mimeTypeConstraintKind = mimeTypeConstraintKind;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as DCommon from "@duplojs/lang/common";
|
|
2
|
+
import type * as DKind from "@duplojs/lang/kind";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
import type * as DSFile from '../../file';
|
|
5
|
+
export declare const mimeTypeConstraintKind: DKind.Handler<DKind.Definition<"@DuplojsServerDataStructure/mime-type-constraint", unknown>>;
|
|
6
|
+
export interface MimeTypeConstraintDefinition extends DDataStructure.ConstraintDefinition {
|
|
7
|
+
regex: RegExp;
|
|
8
|
+
}
|
|
9
|
+
export interface MimeTypeConstraint extends DCommon.UnionToIntersection<DDataStructure.Constraint<DSFile.FileInterface, DSFile.FileInterface, MimeTypeConstraintDefinition> & DKind.Kind<typeof mimeTypeConstraintKind>> {
|
|
10
|
+
}
|
|
11
|
+
export declare const MimeTypeConstraint: (mimeType: Parameters<typeof DCommon.toRegExp>[0]) => MimeTypeConstraint;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { createKind } from "../kind.mjs";
|
|
2
|
+
import * as DCommon from "@duplojs/lang/common";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
//#region scripts/dataStructure/constraint/mimeType.ts
|
|
5
|
+
const mimeTypeConstraintKind = createKind("mime-type-constraint");
|
|
6
|
+
const MimeTypeConstraint = DDataStructure.createConstraint(mimeTypeConstraintKind, ({ init }) => (mimeType) => init({ regex: DCommon.toRegExp(mimeType) }, {
|
|
7
|
+
executeCheck: (self, data) => {
|
|
8
|
+
if (!self.definition.regex.test(data.getMimeType() ?? "")) return DDataStructure.ErrorSymbol;
|
|
9
|
+
return DDataStructure.SuccessSymbol;
|
|
10
|
+
},
|
|
11
|
+
isAsynchronous: () => false
|
|
12
|
+
}));
|
|
13
|
+
//#endregion
|
|
14
|
+
export { MimeTypeConstraint, mimeTypeConstraintKind };
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_kind = require("../kind.cjs");
|
|
3
|
+
let _duplojs_lang_common = require("@duplojs/lang/common");
|
|
4
|
+
_duplojs_lang_common = require_runtime.__toESM(_duplojs_lang_common, 1);
|
|
5
|
+
let _duplojs_lang_either = require("@duplojs/lang/either");
|
|
6
|
+
_duplojs_lang_either = require_runtime.__toESM(_duplojs_lang_either, 1);
|
|
7
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
8
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
9
|
+
//#region scripts/dataStructure/constraint/size.ts
|
|
10
|
+
const sizeConstraintKind = require_kind.createKind("size-constraint");
|
|
11
|
+
const SizeConstraint = _duplojs_lang_dataStructure.createConstraint(sizeConstraintKind, ({ init }) => (params) => init({
|
|
12
|
+
max: params.max === void 0 ? void 0 : _duplojs_lang_common.stringToBytes(params.max),
|
|
13
|
+
min: params.min === void 0 ? void 0 : _duplojs_lang_common.stringToBytes(params.min)
|
|
14
|
+
}, {
|
|
15
|
+
executeCheck: async (self, data) => {
|
|
16
|
+
const result = _duplojs_lang_either.rightPipe(await data.stat(), (stat) => {
|
|
17
|
+
if (!stat.isFile) return _duplojs_lang_either.fail();
|
|
18
|
+
if (self.definition.max !== void 0 && stat.sizeBytes > self.definition.max) return _duplojs_lang_either.fail();
|
|
19
|
+
if (self.definition.min !== void 0 && stat.sizeBytes < self.definition.min) return _duplojs_lang_either.fail();
|
|
20
|
+
return stat;
|
|
21
|
+
});
|
|
22
|
+
if (_duplojs_lang_either.isLeft(result)) return _duplojs_lang_dataStructure.ErrorSymbol;
|
|
23
|
+
return _duplojs_lang_dataStructure.SuccessSymbol;
|
|
24
|
+
},
|
|
25
|
+
isAsynchronous: () => true
|
|
26
|
+
}));
|
|
27
|
+
//#endregion
|
|
28
|
+
exports.SizeConstraint = SizeConstraint;
|
|
29
|
+
exports.sizeConstraintKind = sizeConstraintKind;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import * as DCommon from "@duplojs/lang/common";
|
|
2
|
+
import type * as DKind from "@duplojs/lang/kind";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
import type * as DSFile from '../../file';
|
|
5
|
+
export declare const sizeConstraintKind: DKind.Handler<DKind.Definition<"@DuplojsServerDataStructure/size-constraint", unknown>>;
|
|
6
|
+
export interface SizeConstraintDefinition extends DDataStructure.ConstraintDefinition {
|
|
7
|
+
min?: number;
|
|
8
|
+
max?: number;
|
|
9
|
+
}
|
|
10
|
+
export interface SizeConstraintParams {
|
|
11
|
+
min?: number | DCommon.BytesInString;
|
|
12
|
+
max?: number | DCommon.BytesInString;
|
|
13
|
+
}
|
|
14
|
+
export interface SizeConstraint extends DCommon.UnionToIntersection<DDataStructure.Constraint<DSFile.FileInterface, DSFile.FileInterface, SizeConstraintDefinition> & DKind.Kind<typeof sizeConstraintKind>> {
|
|
15
|
+
}
|
|
16
|
+
export declare const SizeConstraint: (params: SizeConstraintParams) => SizeConstraint;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { createKind } from "../kind.mjs";
|
|
2
|
+
import * as DCommon from "@duplojs/lang/common";
|
|
3
|
+
import * as DEither from "@duplojs/lang/either";
|
|
4
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
5
|
+
//#region scripts/dataStructure/constraint/size.ts
|
|
6
|
+
const sizeConstraintKind = createKind("size-constraint");
|
|
7
|
+
const SizeConstraint = DDataStructure.createConstraint(sizeConstraintKind, ({ init }) => (params) => init({
|
|
8
|
+
max: params.max === void 0 ? void 0 : DCommon.stringToBytes(params.max),
|
|
9
|
+
min: params.min === void 0 ? void 0 : DCommon.stringToBytes(params.min)
|
|
10
|
+
}, {
|
|
11
|
+
executeCheck: async (self, data) => {
|
|
12
|
+
const result = DEither.rightPipe(await data.stat(), (stat) => {
|
|
13
|
+
if (!stat.isFile) return DEither.fail();
|
|
14
|
+
if (self.definition.max !== void 0 && stat.sizeBytes > self.definition.max) return DEither.fail();
|
|
15
|
+
if (self.definition.min !== void 0 && stat.sizeBytes < self.definition.min) return DEither.fail();
|
|
16
|
+
return stat;
|
|
17
|
+
});
|
|
18
|
+
if (DEither.isLeft(result)) return DDataStructure.ErrorSymbol;
|
|
19
|
+
return DDataStructure.SuccessSymbol;
|
|
20
|
+
},
|
|
21
|
+
isAsynchronous: () => true
|
|
22
|
+
}));
|
|
23
|
+
//#endregion
|
|
24
|
+
export { SizeConstraint, sizeConstraintKind };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { FileExistConstraint } from '../fileExist';
|
|
2
|
+
import { FolderExistConstraint } from '../folderExist';
|
|
3
|
+
import { MimeTypeConstraint } from '../mimeType';
|
|
4
|
+
import { SizeConstraint } from '../size';
|
|
5
|
+
declare module "@duplojs/lang/dataStructure" {
|
|
6
|
+
interface ConstraintsStore {
|
|
7
|
+
fileExist: FileExistConstraint;
|
|
8
|
+
folderExist: FolderExistConstraint;
|
|
9
|
+
size: SizeConstraint;
|
|
10
|
+
mimeType: MimeTypeConstraint;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type * from './constraints';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_fileInterface = require("../../file/fileInterface.cjs");
|
|
3
|
+
const require_kind = require("../kind.cjs");
|
|
4
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
5
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
6
|
+
//#region scripts/dataStructure/fundamentalType/file.ts
|
|
7
|
+
const fileFundamentalTypeKind = require_kind.createKind("file-fundamental-type");
|
|
8
|
+
const TheFile = _duplojs_lang_dataStructure.createFundamentalType(fileFundamentalTypeKind, (self, data) => require_fileInterface.isFileInterface(data) ? _duplojs_lang_dataStructure.SuccessSymbol : _duplojs_lang_dataStructure.ErrorSymbol);
|
|
9
|
+
//#endregion
|
|
10
|
+
exports.TheFile = TheFile;
|
|
11
|
+
exports.fileFundamentalTypeKind = fileFundamentalTypeKind;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type * as DCommon from "@duplojs/lang/common";
|
|
2
|
+
import type * as DKind from "@duplojs/lang/kind";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
import * as DSFile from '../../file';
|
|
5
|
+
export declare const fileFundamentalTypeKind: DKind.Handler<DKind.Definition<"@DuplojsServerDataStructure/file-fundamental-type", unknown>>;
|
|
6
|
+
export interface TheFile extends DCommon.UnionToIntersection<DDataStructure.FundamentalType<DSFile.FileInterface> & DKind.Kind<typeof fileFundamentalTypeKind>> {
|
|
7
|
+
}
|
|
8
|
+
export declare const TheFile: TheFile;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { isFileInterface } from "../../file/fileInterface.mjs";
|
|
2
|
+
import { createKind } from "../kind.mjs";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
//#region scripts/dataStructure/fundamentalType/file.ts
|
|
5
|
+
const fileFundamentalTypeKind = createKind("file-fundamental-type");
|
|
6
|
+
const TheFile = DDataStructure.createFundamentalType(fileFundamentalTypeKind, (self, data) => isFileInterface(data) ? DDataStructure.SuccessSymbol : DDataStructure.ErrorSymbol);
|
|
7
|
+
//#endregion
|
|
8
|
+
export { TheFile, fileFundamentalTypeKind };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_folderInterface = require("../../file/folderInterface.cjs");
|
|
3
|
+
const require_kind = require("../kind.cjs");
|
|
4
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
5
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
6
|
+
//#region scripts/dataStructure/fundamentalType/folder.ts
|
|
7
|
+
const folderFundamentalTypeKind = require_kind.createKind("folder-fundamental-type");
|
|
8
|
+
const TheFolder = _duplojs_lang_dataStructure.createFundamentalType(folderFundamentalTypeKind, (self, data) => require_folderInterface.isFolderInterface(data) ? _duplojs_lang_dataStructure.SuccessSymbol : _duplojs_lang_dataStructure.ErrorSymbol);
|
|
9
|
+
//#endregion
|
|
10
|
+
exports.TheFolder = TheFolder;
|
|
11
|
+
exports.folderFundamentalTypeKind = folderFundamentalTypeKind;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type * as DCommon from "@duplojs/lang/common";
|
|
2
|
+
import type * as DKind from "@duplojs/lang/kind";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
import * as DSFile from '../../file';
|
|
5
|
+
export declare const folderFundamentalTypeKind: DKind.Handler<DKind.Definition<"@DuplojsServerDataStructure/folder-fundamental-type", unknown>>;
|
|
6
|
+
export interface TheFolder extends DCommon.UnionToIntersection<DDataStructure.FundamentalType<DSFile.FolderInterface> & DKind.Kind<typeof folderFundamentalTypeKind>> {
|
|
7
|
+
}
|
|
8
|
+
export declare const TheFolder: TheFolder;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { isFolderInterface } from "../../file/folderInterface.mjs";
|
|
2
|
+
import { createKind } from "../kind.mjs";
|
|
3
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
4
|
+
//#region scripts/dataStructure/fundamentalType/folder.ts
|
|
5
|
+
const folderFundamentalTypeKind = createKind("folder-fundamental-type");
|
|
6
|
+
const TheFolder = DDataStructure.createFundamentalType(folderFundamentalTypeKind, (self, data) => isFolderInterface(data) ? DDataStructure.SuccessSymbol : DDataStructure.ErrorSymbol);
|
|
7
|
+
//#endregion
|
|
8
|
+
export { TheFolder, folderFundamentalTypeKind };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type * from './fundamentalTypes';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_file = require("../type/file.cjs");
|
|
3
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
4
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
5
|
+
//#region scripts/dataStructure/helper/file.ts
|
|
6
|
+
function file(constraints = []) {
|
|
7
|
+
return _duplojs_lang_dataStructure.TypeStructure(require_file.FileType(), constraints);
|
|
8
|
+
}
|
|
9
|
+
//#endregion
|
|
10
|
+
exports.file = file;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
2
|
+
import type * as DSFile from '../../file';
|
|
3
|
+
export declare function file<const GenericConstraints extends readonly DDataStructure.Constraint<DSFile.FileInterface>[] = readonly []>(constraints?: GenericConstraints): NoInfer<DDataStructure.TypeStructure<DSFile.FileInterface<import('@duplojs/lang/path').AnyPath>, readonly [...GenericConstraints]>>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FileType } from "../type/file.mjs";
|
|
2
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
3
|
+
//#region scripts/dataStructure/helper/file.ts
|
|
4
|
+
function file(constraints = []) {
|
|
5
|
+
return DDataStructure.TypeStructure(FileType(), constraints);
|
|
6
|
+
}
|
|
7
|
+
//#endregion
|
|
8
|
+
export { file };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
const require_runtime = require("../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_folder = require("../type/folder.cjs");
|
|
3
|
+
let _duplojs_lang_dataStructure = require("@duplojs/lang/dataStructure");
|
|
4
|
+
_duplojs_lang_dataStructure = require_runtime.__toESM(_duplojs_lang_dataStructure, 1);
|
|
5
|
+
//#region scripts/dataStructure/helper/folder.ts
|
|
6
|
+
function folder(constraints = []) {
|
|
7
|
+
return _duplojs_lang_dataStructure.TypeStructure(require_folder.FolderType(), constraints);
|
|
8
|
+
}
|
|
9
|
+
//#endregion
|
|
10
|
+
exports.folder = folder;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
2
|
+
import type * as DSFile from '../../file';
|
|
3
|
+
export declare function folder<const GenericConstraints extends readonly DDataStructure.Constraint<DSFile.FolderInterface>[] = readonly []>(constraints?: GenericConstraints): NoInfer<DDataStructure.TypeStructure<DSFile.FolderInterface<import('@duplojs/lang/path').AnyPath>, readonly [...GenericConstraints]>>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FolderType } from "../type/folder.mjs";
|
|
2
|
+
import * as DDataStructure from "@duplojs/lang/dataStructure";
|
|
3
|
+
//#region scripts/dataStructure/helper/folder.ts
|
|
4
|
+
function folder(constraints = []) {
|
|
5
|
+
return DDataStructure.TypeStructure(FolderType(), constraints);
|
|
6
|
+
}
|
|
7
|
+
//#endregion
|
|
8
|
+
export { folder };
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
const require_runtime = require("../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_kind = require("./kind.cjs");
|
|
3
|
+
const require_file = require("./fundamentalType/file.cjs");
|
|
4
|
+
const require_folder = require("./fundamentalType/folder.cjs");
|
|
5
|
+
const require_json = require("./common/codec/defaults/json.cjs");
|
|
6
|
+
const require_string = require("./common/codec/defaults/string.cjs");
|
|
7
|
+
const require_defaultInterpreter = require("./common/error/defaultInterpreter.cjs");
|
|
8
|
+
const require_fileExist = require("./constraint/fileExist.cjs");
|
|
9
|
+
const require_folderExist = require("./constraint/folderExist.cjs");
|
|
10
|
+
const require_mimeType = require("./constraint/mimeType.cjs");
|
|
11
|
+
const require_size = require("./constraint/size.cjs");
|
|
12
|
+
const require_fileExist$1 = require("./helper/fileExist.cjs");
|
|
13
|
+
const require_file$1 = require("./type/file.cjs");
|
|
14
|
+
const require_folder$1 = require("./type/folder.cjs");
|
|
15
|
+
const require_file$2 = require("./helper/file.cjs");
|
|
16
|
+
const require_folder$2 = require("./helper/folder.cjs");
|
|
17
|
+
const require_folderExist$1 = require("./helper/folderExist.cjs");
|
|
18
|
+
const require_mimeType$1 = require("./helper/mimeType.cjs");
|
|
19
|
+
const require_size$1 = require("./helper/size.cjs");
|
|
20
|
+
//#region scripts/dataStructure/index.ts
|
|
21
|
+
var dataStructure_exports = /* @__PURE__ */ require_runtime.__exportAll({
|
|
22
|
+
FileExistConstraint: () => require_fileExist.FileExistConstraint,
|
|
23
|
+
FileType: () => require_file$1.FileType,
|
|
24
|
+
FolderExistConstraint: () => require_folderExist.FolderExistConstraint,
|
|
25
|
+
FolderType: () => require_folder$1.FolderType,
|
|
26
|
+
MimeTypeConstraint: () => require_mimeType.MimeTypeConstraint,
|
|
27
|
+
SizeConstraint: () => require_size.SizeConstraint,
|
|
28
|
+
TheFile: () => require_file.TheFile,
|
|
29
|
+
TheFolder: () => require_folder.TheFolder,
|
|
30
|
+
codecsJson: () => require_json.codecsJson,
|
|
31
|
+
codecsString: () => require_string.codecsString,
|
|
32
|
+
createKind: () => require_kind.createKind,
|
|
33
|
+
defaultErrorInterpreterCodecDictionary: () => require_defaultInterpreter.defaultErrorInterpreterCodecDictionary,
|
|
34
|
+
defaultErrorInterpreterDataStructureDictionary: () => require_defaultInterpreter.defaultErrorInterpreterDataStructureDictionary,
|
|
35
|
+
file: () => require_file$2.file,
|
|
36
|
+
fileExist: () => require_fileExist$1.fileExist,
|
|
37
|
+
fileExistConstraintKind: () => require_fileExist.fileExistConstraintKind,
|
|
38
|
+
fileFundamentalTypeKind: () => require_file.fileFundamentalTypeKind,
|
|
39
|
+
fileTypeKind: () => require_file$1.fileTypeKind,
|
|
40
|
+
folder: () => require_folder$2.folder,
|
|
41
|
+
folderExist: () => require_folderExist$1.folderExist,
|
|
42
|
+
folderExistConstraintKind: () => require_folderExist.folderExistConstraintKind,
|
|
43
|
+
folderFundamentalTypeKind: () => require_folder.folderFundamentalTypeKind,
|
|
44
|
+
folderTypeKind: () => require_folder$1.folderTypeKind,
|
|
45
|
+
mimeType: () => require_mimeType$1.mimeType,
|
|
46
|
+
mimeTypeConstraintKind: () => require_mimeType.mimeTypeConstraintKind,
|
|
47
|
+
size: () => require_size$1.size,
|
|
48
|
+
sizeConstraintKind: () => require_size.sizeConstraintKind
|
|
49
|
+
});
|
|
50
|
+
//#endregion
|
|
51
|
+
exports.FileExistConstraint = require_fileExist.FileExistConstraint;
|
|
52
|
+
exports.FileType = require_file$1.FileType;
|
|
53
|
+
exports.FolderExistConstraint = require_folderExist.FolderExistConstraint;
|
|
54
|
+
exports.FolderType = require_folder$1.FolderType;
|
|
55
|
+
exports.MimeTypeConstraint = require_mimeType.MimeTypeConstraint;
|
|
56
|
+
exports.SizeConstraint = require_size.SizeConstraint;
|
|
57
|
+
exports.TheFile = require_file.TheFile;
|
|
58
|
+
exports.TheFolder = require_folder.TheFolder;
|
|
59
|
+
exports.codecsJson = require_json.codecsJson;
|
|
60
|
+
exports.codecsString = require_string.codecsString;
|
|
61
|
+
exports.createKind = require_kind.createKind;
|
|
62
|
+
Object.defineProperty(exports, "dataStructure_exports", {
|
|
63
|
+
enumerable: true,
|
|
64
|
+
get: function() {
|
|
65
|
+
return dataStructure_exports;
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
exports.defaultErrorInterpreterCodecDictionary = require_defaultInterpreter.defaultErrorInterpreterCodecDictionary;
|
|
69
|
+
exports.defaultErrorInterpreterDataStructureDictionary = require_defaultInterpreter.defaultErrorInterpreterDataStructureDictionary;
|
|
70
|
+
exports.file = require_file$2.file;
|
|
71
|
+
exports.fileExist = require_fileExist$1.fileExist;
|
|
72
|
+
exports.fileExistConstraintKind = require_fileExist.fileExistConstraintKind;
|
|
73
|
+
exports.fileFundamentalTypeKind = require_file.fileFundamentalTypeKind;
|
|
74
|
+
exports.fileTypeKind = require_file$1.fileTypeKind;
|
|
75
|
+
exports.folder = require_folder$2.folder;
|
|
76
|
+
exports.folderExist = require_folderExist$1.folderExist;
|
|
77
|
+
exports.folderExistConstraintKind = require_folderExist.folderExistConstraintKind;
|
|
78
|
+
exports.folderFundamentalTypeKind = require_folder.folderFundamentalTypeKind;
|
|
79
|
+
exports.folderTypeKind = require_folder$1.folderTypeKind;
|
|
80
|
+
exports.mimeType = require_mimeType$1.mimeType;
|
|
81
|
+
exports.mimeTypeConstraintKind = require_mimeType.mimeTypeConstraintKind;
|
|
82
|
+
exports.size = require_size$1.size;
|
|
83
|
+
exports.sizeConstraintKind = require_size.sizeConstraintKind;
|