Skip to content

Commit 4dd7ec8

Browse files
authored
Add an NS_SWIFT_NAME for FIRSnapshotMetadata (#334)
Fixes b/67332554 Note that this is a breaking change for Swift users of the API.
1 parent 5496eff commit 4dd7ec8

File tree

3 files changed

+21
-2
lines changed

3 files changed

+21
-2
lines changed

Firestore/CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
1+
# Unreleased
2+
- [fixed] Add an NS_SWIFT_NAME for FIRSnapshotMetadata
3+
14
# 2017-10-03 -- v0.8.0
25
- Initial public release.

Firestore/Example/SwiftBuildTest/main.swift

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -275,10 +275,23 @@ func transactions() {
275275

276276
func types() {
277277
// Just highlighting the types of everything, though devs can/will often omit them.
278-
let _: Firestore;
278+
// This list comes from:
279+
//
280+
// grep -r ^FIR_SWIFT_NAME Firestore/Source/Public | sed 's/.*(/let _: /; s/)/;/'
279281
let _: CollectionReference;
282+
let _: DocumentChange;
283+
let _: DocumentListenOptions;
280284
let _: DocumentReference;
281-
let _: Query;
282285
let _: DocumentSnapshot;
286+
let _: FieldPath;
287+
let _: FieldValue;
288+
let _: Firestore;
289+
let _: FirestoreSettings;
290+
let _: GeoPoint;
291+
let _: QueryListenOptions;
292+
let _: Query;
283293
let _: QuerySnapshot;
294+
let _: SnapshotMetadata;
295+
let _: Transaction;
296+
let _: WriteBatch;
284297
}

Firestore/Source/Public/FIRSnapshotMetadata.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,12 @@
1616

1717
#import <Foundation/Foundation.h>
1818

19+
#import "FIRFirestoreSwiftNameSupport.h"
20+
1921
NS_ASSUME_NONNULL_BEGIN
2022

2123
/** Metadata about a snapshot, describing the state of the snapshot. */
24+
FIR_SWIFT_NAME(SnapshotMetadata)
2225
@interface FIRSnapshotMetadata : NSObject
2326

2427
- (instancetype)init NS_UNAVAILABLE;

0 commit comments

Comments
 (0)