private EntityCommandDefinition CreateCommandDefinition() { if (this._preparedCommandTree == null) { this._preparedCommandTree = this.MakeCommandTree(); } if (!this._preparedCommandTree.MetadataWorkspace.IsMetadataWorkspaceCSCompatible(this.Connection.GetMetadataWorkspace())) { throw new InvalidOperationException(Strings.EntityClient_CommandTreeMetadataIncompatible); } return(EntityProviderServices.CreateCommandDefinition(this._connection.StoreProviderFactory, this._preparedCommandTree, this._interceptionContext, this._dependencyResolver)); }
/// <summary> /// Creates a commandDefinition for the command, using the options specified. /// Note: This method must not be side-effecting of the command /// </summary> /// <returns> the command definition </returns> private EntityCommandDefinition CreateCommandDefinition() { MakeCommandTree(); // Always check the CQT metadata against the connection metadata (internally, CQT already // validates metadata consistency) if (!_preparedCommandTree.MetadataWorkspace.IsMetadataWorkspaceCSCompatible(Connection.GetMetadataWorkspace())) { throw new InvalidOperationException(Strings.EntityClient_CommandTreeMetadataIncompatible); } var result = EntityProviderServices.CreateCommandDefinition(_connection.StoreProviderFactory, _preparedCommandTree); return(result); }
// <summary> // Creates a commandDefinition for the command, using the options specified. // Note: This method must not be side-effecting of the command // </summary> // <returns> the command definition </returns> private EntityCommandDefinition CreateCommandDefinition() { // Do the work only if we don't have a command tree yet if (_preparedCommandTree == null) { _preparedCommandTree = MakeCommandTree(); } // Always check the CQT metadata against the connection metadata (internally, CQT already // validates metadata consistency) if (!_preparedCommandTree.MetadataWorkspace.IsMetadataWorkspaceCSCompatible(Connection.GetMetadataWorkspace())) { throw new InvalidOperationException(Strings.EntityClient_CommandTreeMetadataIncompatible); } return(EntityProviderServices.CreateCommandDefinition( _connection.StoreProviderFactory, _preparedCommandTree, _interceptionContext, _dependencyResolver)); }