call method

dynamic call(
  1. dynamic typeOrSerializedValue, [
  2. dynamic value
])

Implementation

dynamic call(dynamic typeOrSerializedValue, [dynamic value]) {
  if (typeOrSerializedValue is String) {
    return _makePure(schemaFromName(typeOrSerializedValue).serialize(value));
  }

  if (typeOrSerializedValue is Uint8List || typeOrSerializedValue is SerializedBcs) {
    return _makePure(typeOrSerializedValue);
  }

  throw ArgumentError('pure must be called with either a bcs type name, or a serialized bcs value');
}