MCPcopy Create free account
hub / github.com/CoderLine/alphaTab / MidiEventSerializerPlugin

Class MidiEventSerializerPlugin

packages/alphatab/test/PrettyFormat.ts:726–743  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

724 * @internal
725 */
726export class MidiEventSerializerPlugin implements PrettyFormatNewPlugin {
727 public static readonly instance = new MidiEventSerializerPlugin();
728 serialize(
729 val: unknown,
730 config: PrettyFormatConfig,
731 indentation: string,
732 depth: number,
733 refs: unknown[],
734 printer: PrettyFormatPrinter
735 ): string {
736 const json = JsonConverter.midiEventToJsObject(val as MidiEvent);
737 return printer(json, config, indentation, depth, refs);
738 }
739
740 test(arg0: unknown): boolean {
741 return arg0 instanceof MidiEvent;
742 }
743}
744
745/**
746 * A serializer plugin for pretty-format for creating simple Score model snapshots

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected