public sealed class DocumentChange : IEquatable<DocumentChange>
Reference documentation and code samples for the Firestore API class DocumentChange.
A DocumentChange represents a change to the documents matching a query. It contains the document affected and a the type of change that occurred (added, modifed, or removed).
Implements
IEquatableDocumentChangeNamespace
Google.Cloud.FirestoreAssembly
Google.Cloud.Firestore.dll
Properties
ChangeType
public DocumentChange.Type ChangeType { get; }
The type of change that was observed.
Property Value | |
---|---|
Type | Description |
DocumentChangeType |
Document
public DocumentSnapshot Document { get; }
The newly added or modified document, or the document that was deleted.
Property Value | |
---|---|
Type | Description |
DocumentSnapshot |
NewIndex
public int? NewIndex { get; }
The index of the changed document in the result set immediately after this DocumentChange (i.e. supposing that all prior DocumentChange objects and this one have been applied), null if the change type is Removed. The index will never be negative.
Property Value | |
---|---|
Type | Description |
int |
OldIndex
public int? OldIndex { get; }
The index of the changed document in the result set immediately prior to this DocumentChange (i.e. supposing that all prior DocumentChange objects have been applied), or null if the change type is Added. The index will never be negative.
Property Value | |
---|---|
Type | Description |
int |
Methods
GetHashCode()
public override int GetHashCode()
Serves as the default hash function.
Returns | |
---|---|
Type | Description |
int | A hash code for the current object. |