2016-06-21 1 views
0

Salut J'essaie d'appeler setObjectMapping: whenValueOfKeyPath: isEqualTo sur mon objet de mappage dynamique. Mais il me donne cette erreurAucune @interface visible pour RKDynamicMapping déclare le sélecteur setObjectMapping: whenValueOfKeyPath: isEqualTo - Restkit 0.2

Aucun @interface visible RKDynamicMapping déclare le sélecteur setObjectMapping: whenValueOfKeyPath: isEqualTo

RKDynamicMapping* dynamicMapping = [RKDynamicMapping new]; 
[dynamicMapping setObjectMapping:girlMapping whenValueOfKeyPath:@"type" isEqualTo:@"Girl"]; 

Où suis-je tort? Est-il supprimé dans RestKit 0.2?

Répondre

0

Finalement, j'ai trouvé la solution. nous pouvons utiliser addMatcher: matcherWithKeyPath: expectedValue: ObjectMapping propriété de l'objet RKDynamicMapping

[dynamicMapping addMatcher:[RKObjectMappingMatcher matcherWithKeyPath:@"type" expectedValue:@"Girl" objectMapping:girlMapping]];