EntityKey Class

Definition

An identifier for an entity.

[System.Diagnostics.DebuggerDisplay("{ConcatKeyValue()}")]
[System.Runtime.Serialization.DataContract(IsReference=true)]
[System.Serializable]
public sealed class EntityKey : IEquatable<System.Data.Entity.Core.EntityKey>
type EntityKey = class
    interface IEquatable<EntityKey>
Public NotInheritable Class EntityKey
Implements IEquatable(Of EntityKey)
Inheritance
EntityKey
Attributes
Implements

Constructors

EntityKey()

Initializes a new instance of the EntityKey class.

EntityKey(String, IEnumerable<EntityKeyMember>)

Initializes a new instance of the EntityKey class with an entity set name and an IEnumerable<T> collection of EntityKeyMember objects.

EntityKey(String, IEnumerable<KeyValuePair<String,Object>>)

Initializes a new instance of the EntityKey class with an entity set name and a generic KeyValuePair collection.

EntityKey(String, String, Object)

Initializes a new instance of the EntityKey class with an entity set name and specific entity key pair.

Properties

EntityContainerName

Gets or sets the name of the entity container.

EntityKeyValues

Gets or sets the key values associated with this EntityKey.

EntityNotValidKey

Gets a singleton EntityKey identifying an entity resulted from a failed TREAT.

EntitySetName

Gets or sets the name of the entity set.

IsTemporary

Gets a value that indicates whether the EntityKey is temporary.

NoEntitySetKey

Gets a singleton EntityKey by which a read-only entity is identified.

Methods

Equals(EntityKey)

Returns a value that indicates whether this instance is equal to a specified EntityKey .

Equals(Object)

Returns a value that indicates whether this instance is equal to a specified object.

GetEntitySet(MetadataWorkspace)

Gets the entity set for this entity key from the given metadata workspace.

GetHashCode()

Serves as a hash function for the current EntityKey object. GetHashCode() is suitable for hashing algorithms and data structures such as a hash table.

OnDeserialized(StreamingContext)

Helper method that is used to deserialize an EntityKey.

OnDeserializing(StreamingContext)

Helper method that is used to deserialize an EntityKey.

Operators

Equality(EntityKey, EntityKey)

Compares two EntityKey objects.

Inequality(EntityKey, EntityKey)

Compares two EntityKey objects.

Applies to