registerWith static method
Registers all method channel handlers for RASP, screen, memory, and location.
Implementation
static void registerWith(Registrar registrar) {
// RASP channel
final raspChannel = MethodChannel(
ShieldCodec.d(ShieldCodec.chRasp),
const StandardMethodCodec(),
registrar,
);
raspChannel.setMethodCallHandler(_handleRaspCall);
// Screen channel
final screenChannel = MethodChannel(
ShieldCodec.d(ShieldCodec.chScreen),
const StandardMethodCodec(),
registrar,
);
screenChannel.setMethodCallHandler(_handleScreenCall);
// Memory channel
final memoryChannel = MethodChannel(
ShieldCodec.d(ShieldCodec.chMemory),
const StandardMethodCodec(),
registrar,
);
memoryChannel.setMethodCallHandler(_handleMemoryCall);
// Location channel
final locationChannel = MethodChannel(
ShieldCodec.d(ShieldCodec.chLocation),
const StandardMethodCodec(),
registrar,
);
locationChannel.setMethodCallHandler(_handleLocationCall);
}