SEL constructor
SEL(
- String selectorName
Implementation
factory SEL(String selectorName) {
if (_cache.containsKey(selectorName)) {
return _cache[selectorName]!;
}
final selectorNamePtr = selectorName.toNativeUtf8();
Pointer<Void> ptr = sel_registerName(selectorNamePtr);
calloc.free(selectorNamePtr);
if (ptr == nullptr) {
throw 'Failed to register a Selector!';
}
return SEL._internal(selectorName, ptr);
}