diff options
Diffstat (limited to 'Firestore/Source/Model')
-rw-r--r-- | Firestore/Source/Model/FSTDocumentSet.h | 10 | ||||
-rw-r--r-- | Firestore/Source/Model/FSTDocumentSet.mm | 10 |
2 files changed, 0 insertions, 20 deletions
diff --git a/Firestore/Source/Model/FSTDocumentSet.h b/Firestore/Source/Model/FSTDocumentSet.h index a7f8c4a..022e900 100644 --- a/Firestore/Source/Model/FSTDocumentSet.h +++ b/Firestore/Source/Model/FSTDocumentSet.h @@ -59,16 +59,6 @@ NS_ASSUME_NONNULL_BEGIN - (FSTDocument *_Nullable)lastDocument; /** - * Returns the document previous to the document associated with the given key in the set according - * to its built in ordering. Returns nil if the document associated with the given key is the - * first document. - * - * @param key A key that must be present in the DocumentSet. - * @throws NSInvalidArgumentException if key is not present. - */ -- (FSTDocument *_Nullable)predecessorDocumentForKey:(FSTDocumentKey *)key; - -/** * Returns the index of the document with the provided key in the document set. Returns NSNotFound * if the key is not present. */ diff --git a/Firestore/Source/Model/FSTDocumentSet.mm b/Firestore/Source/Model/FSTDocumentSet.mm index c4c0f49..6f44799 100644 --- a/Firestore/Source/Model/FSTDocumentSet.mm +++ b/Firestore/Source/Model/FSTDocumentSet.mm @@ -135,16 +135,6 @@ typedef FSTImmutableSortedSet<FSTDocument *> SetType; return [self.sortedSet lastObject]; } -- (FSTDocument *_Nullable)predecessorDocumentForKey:(FSTDocumentKey *)key { - FSTDocument *doc = [self.index objectForKey:key]; - if (!doc) { - @throw [NSException exceptionWithName:NSInvalidArgumentException - reason:[NSString stringWithFormat:@"Key %@ does not exist", key] - userInfo:nil]; - } - return [self.sortedSet predecessorObject:doc]; -} - - (NSUInteger)indexOfKey:(FSTDocumentKey *)key { FSTDocument *doc = [self.index objectForKey:key]; return doc ? [self.sortedSet indexOfObject:doc] : NSNotFound; |