Struct RelationalCompiledQueryCacheKeyGenerator.RelationalCompiledQueryCacheKey
- Namespace
- Microsoft.EntityFrameworkCore.Query
- Assembly
- Microsoft.EntityFrameworkCore.Relational.dll
A key that uniquely identifies a query. This is used to store and lookup compiled versions of a query in a cache.
This type is typically used by database providers (and other extensions). It is generally not used in application code.
protected readonly struct RelationalCompiledQueryCacheKeyGenerator.RelationalCompiledQueryCacheKey : IEquatable<RelationalCompiledQueryCacheKeyGenerator.RelationalCompiledQueryCacheKey>
- Implements
- Inherited Members
Constructors
RelationalCompiledQueryCacheKey(CompiledQueryCacheKey, bool, QuerySplittingBehavior?, bool)
Initializes a new instance of the RelationalCompiledQueryCacheKeyGenerator.RelationalCompiledQueryCacheKey class.
public RelationalCompiledQueryCacheKey(CompiledQueryCacheKeyGenerator.CompiledQueryCacheKey compiledQueryCacheKey, bool useRelationalNulls, QuerySplittingBehavior? querySplittingBehavior, bool shouldBuffer)
Parameters
compiledQueryCacheKey
CompiledQueryCacheKeyThe non-relational cache key.
useRelationalNulls
boolTrue to use relational null logic.
querySplittingBehavior
QuerySplittingBehavior?QuerySplittingBehavior to use when loading related collections.
shouldBuffer
booltrue if the query should be buffered.
Methods
Equals(RelationalCompiledQueryCacheKey)
Indicates whether the current object is equal to another object of the same type.
public bool Equals(RelationalCompiledQueryCacheKeyGenerator.RelationalCompiledQueryCacheKey other)
Parameters
other
RelationalCompiledQueryCacheKeyGenerator.RelationalCompiledQueryCacheKeyAn object to compare with this object.
Returns
Equals(object)
Determines if this key is equivalent to a given object (i.e. if they are keys for the same query).
public override bool Equals(object obj)
Parameters
obj
objectThe object to compare this key to.
Returns
- bool
true if the object is a RelationalCompiledQueryCacheKeyGenerator.RelationalCompiledQueryCacheKey and is for the same query, otherwise false.
GetHashCode()
Gets the hash code for the key.
public override int GetHashCode()
Returns
- int
The hash code for the key.