$getProperty method
Obtiene una propiedad o método de la clase puente por su identificador.
Implementation
@override
$Value? $getProperty(Runtime runtime, String identifier) {
if (identifier == 'coleccionPorNombre') {
return $Function((runtime, target, args) {
final future = $value.coleccionPorNombre(args[0]!.$value);
return $Future.wrap(future.then((result) => $String(result)));
});
}
if (identifier == 'obtenerDataColeccionRelacionada') {
return $Function((runtime, target, args) {
final future = $value.obtenerDataColeccionRelacionada(
args[0]!.$value, args[1]!.$value.cast());
return $Future.wrap(future.then((result) => $String(result)));
});
}
if (identifier == 'leeById') {
return $Function((runtime, target, args) {
final future = $value.leeById(args[0]!.$value, args[1]!.$value);
return $Future.wrap(future.then((result) => result));
});
}
if (identifier == 'getKey') {
return $Function((runtime, target, args) {
$String coleccion = $String(args[1]!.$value);
final future = $value.getKey($Map.wrap(args[0]!.$value), coleccion);
return $Future.wrap(future);
});
}
return null;
}