MCPcopy Create free account
hub / github.com/SmartThingsCommunity/smartthings-cli / inputProcessor

Function inputProcessor

src/lib/command/input-processor.ts:75–78  ·  view source on GitHub ↗
(hasInput: () => boolean | Promise<boolean>, read: () => Promise<T>,
		ioFormat: IOFormat = 'common')

Source from the content-addressed store, hash-verified

73 * Build an input processor given the necessary functions for doing so.
74 */
75export function inputProcessor<T>(hasInput: () => boolean | Promise<boolean>, read: () => Promise<T>,
76 ioFormat: IOFormat = 'common'): InputProcessor<T> {
77 return { ioFormat, hasInput, read }
78}
79
80export type CommandLineInputCommand<T> = {
81 hasCommandLineInput(): boolean

Callers 5

handlerFunction · 0.85
handlerFunction · 0.85
userInputProcessorFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected