import assert from "node:assert" ; import { Command , CommandHandlerArgumentNames , } from "../types/command.js" ; import UvcDeviceLister from "../uvc-device-lister.js" ; export default class DevicesCommand implements Command { constructor ( private readonly uvcDeviceLister ) { assert . strictEqual ( arguments . length , 1 ) ; assert ( typeof this . uvcDeviceLister === "object" ) ; } async getArguments ( ) { return [ ] ; } async execute ( ) { assert . strictEqual ( arguments . length , 0 ) ; const devices = await this . uvcDeviceLister . get ( ) ; return devices ; } }