Lines Matching refs:mechanism
59 for (FRAMechanism *mechanism in mechanismList) {
60 if ([mechanism isKindOfClass:aClass]) {
61 return mechanism;
67 - (BOOL)addMechanism:(FRAMechanism *)mechanism error:(NSError *__autoreleasing *)error {
70 if ([mechanism isKindOfClass:[FRAPushMechanism class]]) {
78 *error = [FRAError createError:[NSString stringWithFormat:@"Duplicate mechanism for %@ account.", _issuer]
80 userInfo:@{ @"identity":self, @"mechanism":duplicateMechanism }];
85 [mechanism setParent:self];
86 [mechanismList addObject:mechanism];
89 result = [self.database insertMechanism:mechanism error:error];
94 - (BOOL)removeMechanism:(FRAMechanism *)mechanism error:(NSError *__autoreleasing *)error {
97 if (![mechanismList containsObject:mechanism]) {
108 result = [self.database deleteMechanism:mechanism error:error];
111 [mechanismList removeObject:mechanism];
112 [mechanism setParent:nil];
122 for (FRAMechanism *mechanism in self.mechanisms) {
123 count += [mechanism pendingNotificationsCount];