Struct QueryResult
Represents the result of a game state query.
Implements
Inherited Members
Namespace: Microsoft.XboxStudios.GameStateTracker
Assembly: GameStateTracker.Abstractions.dll
Syntax
public readonly struct QueryResult : IEquatable<QueryResult>
Remarks
Initializes a new instance of the QueryResult struct.
Constructors
View SourceQueryResult(in ObjectInfo, KeyValuePair<string, object>)
Represents the result of a game state query.
Declaration
public QueryResult(in ObjectInfo key, KeyValuePair<string, object> value = default)
Parameters
Type | Name | Description |
---|---|---|
ObjectInfo | key | The object description. |
KeyValuePair<string, object> | value | The property name and value. |
Remarks
Initializes a new instance of the QueryResult struct.
Properties
View SourceKey
Gets the description of the queried object.
Declaration
public ObjectInfo Key { get; }
Property Value
Type | Description |
---|---|
ObjectInfo |
Value
Gets the property name and value.
Declaration
public KeyValuePair<string, object> Value { get; }
Property Value
Type | Description |
---|---|
KeyValuePair<string, object> |
Methods
View SourceEquals(QueryResult)
Determines if the query results are equal.
Declaration
public bool Equals(QueryResult other)
Parameters
Type | Name | Description |
---|---|---|
QueryResult | other | The query result to compare to. |
Returns
Type | Description |
---|---|
bool | True if the query results are not equal. |
Equals(object?)
Indicates whether this instance and a specified object are equal.
Declaration
public override bool Equals(object? obj)
Parameters
Type | Name | Description |
---|---|---|
object | obj | The object to compare with the current instance. |
Returns
Type | Description |
---|---|
bool | true if |
Overrides
View SourceGetHashCode()
Returns the hash code for this instance.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int | A 32-bit signed integer that is the hash code for this instance. |
Overrides
View SourceToString()
Returns the fully qualified type name of this instance.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string | The fully qualified type name. |
Overrides
Operators
View Sourceoperator ==(QueryResult, QueryResult)
Determines if the query results are equal to each other.
Declaration
public static bool operator ==(QueryResult left, QueryResult right)
Parameters
Type | Name | Description |
---|---|---|
QueryResult | left | The first query result to compare. |
QueryResult | right | The second query result to compare. |
Returns
Type | Description |
---|---|
bool | True if the query results are equal. |
operator !=(QueryResult, QueryResult)
Determines if the query results are not equal to each other.
Declaration
public static bool operator !=(QueryResult left, QueryResult right)
Parameters
Type | Name | Description |
---|---|---|
QueryResult | left | The first query result to compare. |
QueryResult | right | The second query result to compare. |
Returns
Type | Description |
---|---|
bool | True if the query results are not equal. |