createInstance method
$CaptureConnection
createInstance(
- TypeChannelMessenger messenger,
- List<
Object?> arguments
override
Instantiates a new object with arguments
.
Implementation
@override
$CaptureConnection createInstance(
TypeChannelMessenger messenger,
List<Object?> arguments,
) {
final String constructorName = arguments[0] as String;
switch (constructorName) {
case '':
return $create$(
messenger,
(arguments[1] as List<dynamic>)
.map((_) => _ as $CaptureInputPort)
.toList(),
arguments[2] as $CaptureOutput,
);
}
throw ArgumentError.value(
constructorName,
'constructorName',
'Unable to invoke constructor of',
);
}