wasm-imagemagick > ExecutionContext
Allow multiple execute() calls remembering previous execute() generated output files and previous given input files that can be used as input files in next calls.
ExecutionContext
▸ addBuiltInImages(): Promise
<void
>
Defined in executionContext.ts:27
Add ImageMagick built-in images like rose:
, logo:
, etc to this execution context so they are present in getAllFiles()
.
Returns: Promise
<void
>
▸ addFiles(files: MagickFile[]): void
Defined in executionContext.ts:17
Programmatically add new files so they are available if following execute()
calls.
Parameters:
Name | Type |
---|---|
files | MagickFile[] |
Returns: void
▸ execute(configOrCommands: * ExecuteConfig | ExecuteCommand | string
*): Promise
<ExecuteResult>
Defined in executionContext.ts:12
This behaves almost the same as execute.
Parameters:
Name | Type |
---|---|
configOrCommands | ExecuteConfig | ExecuteCommand | string |
Returns: Promise
<ExecuteResult>
▸ getAllFiles(): Promise
<MagickInputFile[]>
Defined in executionContext.ts:22
Get all the files currently available in this context.
Returns: Promise
<MagickInputFile[]>
▸ getFile(name: string
): Promise
< MagickInputFile | undefined
>
Defined in executionContext.ts:32
Get a file by name or undefined if none.
Parameters:
Name | Type |
---|---|
name | string |
Returns: Promise
< MagickInputFile | undefined
>
▸ removeFiles(names: string
[]): MagickInputFile[]
Defined in executionContext.ts:38
Remove files by name.
Parameters:
Name | Type |
---|---|
names | string [] |
Returns: MagickInputFile[] the files actually removed.