feat: Determine Typed Converter output based on input type

This commit is contained in:
Joachim Van Herwegen
2021-10-26 16:30:10 +02:00
parent 27306d6e3f
commit fa94c7d4bb
17 changed files with 107 additions and 134 deletions

View File

@@ -22,15 +22,7 @@ const logger: jest.Mocked<Logger> = getLoggerFor('GuardedStream') as any;
class DummyConverter extends BaseTypedRepresentationConverter {
public constructor() {
super('*/*', 'custom/type');
}
public async getInputTypes(): Promise<Record<string, number>> {
return { [INTERNAL_QUADS]: 1 };
}
public async getOutputTypes(): Promise<Record<string, number>> {
return { 'x/x': 1 };
super(INTERNAL_QUADS, 'x/x');
}
public async handle({ representation }: RepresentationConverterArgs): Promise<Representation> {