I think you can only get selector names if the property is declared explicitly (setter = XXX and / or getter = XXX)
So, to get the getter and setter switch names for some property "furType" of class "Cat":
objc_property_t prop = class_getProperty([Cat class], "furType"); char *setterName = property_copyAttributeValue(prop, "S"); if (setterName == NULL) { } char *getterName = property_copyAttributeValue(prop, "G"); if (getterName == NULL) { }
I do not know the return request, except for repeating all the properties and finding matches. Hope this helps.
source share