true if the snapshot contains the result of local writes (e.g.
SetAsync or UpdateAsync calls) that have not yet been committed to the backend. If your listener has opted into metadata updates (via MetadataChanges.Include) you will receive another snapshot with HasPendingWrites equal to false once the writes have been committed to the backend.
IsFromCache
boolIsFromCache
true if the snapshot was created from cached data rather than guaranteed up-to-date server data.
If your listener has opted into metadata updates (via MetadataChanges.Include) you will receive another snapshot with IsFromCache equal to false once the client has received up-to-date data from the backend.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2021-09-08 UTC."],[],[],null,["# Firebase.Firestore.SnapshotMetadata Class Reference\n\nFirebase.Firestore.SnapshotMetadata\n===================================\n\nMetadata about a snapshot, describing the state of the snapshot.\n\nSummary\n-------\n\n| ### Constructors and Destructors ||\n|---|---|\n| [SnapshotMetadata](#class_firebase_1_1_firestore_1_1_snapshot_metadata_1ac77d05832cdc11ea503c5a709f8b7f4d)`(bool hasPendingWrites, bool isFromCache)` Creates a new instance of the class. ||\n\n| ### Properties ||\n|------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------|\n| [HasPendingWrites](#class_firebase_1_1_firestore_1_1_snapshot_metadata_1ad82a4beede53aa1cdb4ca4d522406527) | `bool` `true` if the snapshot contains the result of local writes (e.g. |\n| [IsFromCache](#class_firebase_1_1_firestore_1_1_snapshot_metadata_1a71762ba2d51746a0285af93a1a1dcf44) | `bool` `true` if the snapshot was created from cached data rather than guaranteed up-to-date server data. |\n\n| ### Public functions ||\n|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------|\n| [Equals](#class_firebase_1_1_firestore_1_1_snapshot_metadata_1adbcb3ccd1f2fbdaa508234964c8c2307)`(object obj)` | `override bool` |\n| [Equals](#class_firebase_1_1_firestore_1_1_snapshot_metadata_1a602485aba60748fc9977b5d398082d13)`(`[SnapshotMetadata](/docs/reference/unity/class/firebase/firestore/snapshot-metadata#class_firebase_1_1_firestore_1_1_snapshot_metadata)` other)` | `bool` Compares this snapshot metadata with another for equality. |\n| [GetHashCode](#class_firebase_1_1_firestore_1_1_snapshot_metadata_1a7be3512a85742371ff57611327bd3f33)`()` | `override int` |\n\nProperties\n----------\n\n### HasPendingWrites\n\n```c#\nbool HasPendingWrites\n``` \n`true` if the snapshot contains the result of local writes (e.g.\n\n`SetAsync` or `UpdateAsync` calls) that have not yet been committed to the backend. If your listener has opted into metadata updates (via `MetadataChanges.Include`) you will receive another snapshot with `HasPendingWrites` equal to `false` once the writes have been committed to the backend. \n\n### IsFromCache\n\n```c#\nbool IsFromCache\n``` \n`true` if the snapshot was created from cached data rather than guaranteed up-to-date server data.\n\nIf your listener has opted into metadata updates (via `MetadataChanges.Include`) you will receive another snapshot with `IsFromCache` equal to `false` once the client has received up-to-date data from the backend.\n\nPublic functions\n----------------\n\n### Equals\n\n```c#\noverride bool Equals(\n object obj\n)\n``` \n\n### Equals\n\n```c#\nbool Equals(\n SnapshotMetadata other\n)\n``` \nCompares this snapshot metadata with another for equality.\n\n\u003cbr /\u003e\n\n| Details ||\n|-------------|-----------------------------------------------------------------------------------------------------------------------------|\n| Parameters | |---------|-------------------------------------------------| | `other` | The snapshot metadata to compare this one with. | |\n| **Returns** | `true` if this snapshot metadata is equal to *other* ; `false` otherwise. |\n\n### GetHashCode\n\n```c#\noverride int GetHashCode()\n``` \n\n### SnapshotMetadata\n\n```c#\n SnapshotMetadata(\n bool hasPendingWrites,\n bool isFromCache\n)\n``` \nCreates a new instance of the class.\n\n\u003cbr /\u003e\n\n| Details ||\n|------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Parameters | |--------------------|-----------------------------------------------------| | `hasPendingWrites` | Indicates whether this snapshot has pending writes. | | `isFromCache` | Indicates whether this snapshot is from the cache. | |"]]