TeamFoundationSqlResourceComponent Methods
Include Protected Members
Include Inherited Members
The TeamFoundationSqlResourceComponent type exposes the following members.
Methods
Name | Description | |
---|---|---|
AddStatement(String) | Add a statement to the current SQL batch. You must call PrepareSqlBatch before you call AddStatement. | |
AddStatement(String, Int32) | Add a statement to the current SQL batch. You must call PrepareSqlBatch before you call AddStatement. If the number of parameters that will be added by using this statement will exceed the maximum number of allowed parameters in a single SQL batch, the statements that are already part of the batch will be executed, and then a new batch will begin with the statement that's being added. | |
AddStatement(String, Int32, Boolean) | Add a statement to the current SQL batch. You must call PrepareSqlBatch before you call AddStatement. If the number of parameters that will be added by using this statement will exceed the maximum number of allowed parameters in a single SQL batch, the statements that are already part of the batch will be executed, and then a new batch will begin with the statement that's being added. | |
AddStatement(String, Int32, Boolean, Boolean) | Add a statement to the current SQL batch. You must call PrepareSqlBatch before you call AddStatement. If the number of parameters that will be added by using this statement will exceed the maximum number of allowed parameters in a single SQL batch, the statements that are already part of the batch will be executed, and then a new batch will begin with the statement that's being added. | |
BeginTransaction | Used to wrap several calls in a single transaction. All executes on this component will be in the transaction until Commit or RollBack are called. | |
BindBinary(String, array<Byte[], SqlDbType) | This is a helper function that handles binding a binary value to a SqlParameter. | |
BindBinary(String, array<Byte[], Int32, SqlDbType) | A helper function that handles binding a binary value to a sqlparameter. | |
BindBoolean | A helper function that handles binding a Boolean or a bit value to a sqlparameter. | |
BindByte(String, Byte) | A helper function that handles binding an 8-bit value to its sqlparameters. | |
BindByte(String, Byte, Byte) | A helper function that handles binding an 8-bit value that might be null to its sqlparameters. | |
BindDateTime | A helper function that handles binding a date/time value to a sqlparameter. | |
BindDefault | A helper function that handles binding a value to default type. | |
BindDouble | This is a helper function that takes care of binding 32 bit value to their sqlparameters. | |
BindGuid | This is a helper function that handles binding GUIDs to their sqlparameters. | |
BindInt | A helper function that handles binding a 32-bit value to its sqlparameters. | |
BindLong | A helper function that handles binding a 64-bit value to its sqlparameters. | |
BindNullableBoolean | This is a helper function that takes care of binding boolean or a bit value to a sqlparameter. | |
BindNullableByte | This is a helper function that handles binding an 8-bit value to its SqlParameters. | |
BindNullableDateTime | This is a helper function that takes care of binding a date/time value to a sqlparameter. | |
BindNullableGuid | A helper function that handles binding GUIDs to their sqlparameters. The value Empty is considered NULL and a NULL is bound to the given parameter. | |
BindNullableInt | If parameterValue == nullValue, a NULL is bound to the given parameter. Otherwise, parameterValue is bound as a 32-bit integer. | |
BindNullableShort | If parameterValue == nullValue, a NULL is bound to the given parameter. Otherwise, parameterValue is bound as a 16-bit integer | |
BindNullValue | This is a generic binding helper that builds a specific parameter typed null value. | |
BindShort | This is a helper function that handles binding 16 bit value to their sqlparameters. | |
BindString(String, String, Int32, BindStringBehavior, SqlDbType) | This is a helper function that handles binding strings to their SqlParameters. It makes sure that null values are correctly handled. | |
BindString(String, String, Int32, Boolean, SqlDbType) | This is a helper function that handles binding strings to their SqlParameters.It makes sure that null values are correctly handled. This is the old version of this method; use the overload that takes a BindStringBehavior to be more explicit about how null and empty strings are to be handled. | |
BindSysname | A helper function that handles binding sysname strings to their sqlparameters. It makes sure null values are correctly set up. | |
BindTable<T> | Binds a table. | |
BindVariant | ||
BindXml(String, TeamFoundationDatabaseXmlWriter) | Used to bind an XML document to an XML parameter. | |
BindXml(String, String) | Used to bind an XML document to an XML parameter. | |
Cancel | ||
CanRetryOnException | Indicates whether the SQL exception can be retried. | |
CanRetryOnSqlError | ||
CommitTransaction | Commit the transaction that is active for this component. | |
Dispose | ||
Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) | |
Execute | Internal helper that encapsulates the logic for ExecuteReader and ExecuteNonQuery. | |
ExecuteNonQuery() | Executes the current SQL command and does not produce a result set. | |
ExecuteNonQuery(Boolean) | Executes the current SQL command and does not produce a result set. The only result is the Return Value, which is a single scalar value. | |
ExecuteReader() | Overload using default command behavior. | |
ExecuteReader(CommandBehavior) | Executes the current SQL command and returns a reader. | |
ExecuteScalar | Execute the current SQL command by using ExecuteScalar and stores the result. | |
ExecuteUnknown(Object) | Executes the current SQL command by using ExecuteUnknown() and returns the object. | |
ExecuteUnknown(SqlDataReader, Object) | The method that is used by ExecuteUnknown() to populate an object based on a reader caller of ExecuteUnknown must override this method. | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
FlushBatch | Flushes the batch that is pended to this point and creates a new batch so that users may call AddStatement again. | |
GetHashCode | Serves as the default hash function. (Inherited from Object.) | |
GetParameterName | Helper method to format a parameter name. | |
GetSqlErrorNumberAsString | Helper that returns all the error numbers in a string for tracing purposes It's not super efficient but should only be called in case SQL is having issues which *should* be rare. | |
GetSqlErrorNumbers | Helper that returns all the error numbers contained in a sql exception object | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
HandleCustomException | Handle custom exceptions. | |
HandleException | Determine whether the SQL exception can be handled; SQL exceptions that cannot be retried or mapped are "unhandled." | |
Initialize(String) | Initializes a component. | |
Initialize(TeamFoundationRequestContext, String, Int32) | ||
Initialize(String, Int32, Int32, Int32, Int32) | Initializes a component. | |
MapException(SqlException) | Map a SQL exception into an application-specific exception, if it is possible. Otherwise, the exception is reported using Watson. | |
MapException(SqlException, QueryExecutionState) | Map a SQL exception into an application-specific exception, if it is possible. Otherwise, the exception is reported using Watson. | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
PrepareConnectionString | Allows derived classes to update connection string. | |
PrepareSqlBatch(Int32) | Setup to execute a batch of SQL statements. This method will close all existing commands or readers. | |
PrepareSqlBatch(Int32, Boolean) | Setup to execute a batch of SQL statements. This method will close all existing command or reader. | |
PrepareStoredProcedure(String) | Setup to execute a SQL stored procedure. This method will close all existing commands or readers. | |
PrepareStoredProcedure(String, Boolean) | Setup to execute a SQL Server stored procedure. This method will close all existing command or reader. | |
PrepareStoredProcedure(String, Int32) | Setup to execute a SQL stored procedure. This method will close all existing commands or readers. | |
PrepareStoredProcedure(String, Boolean, Int32) | Setup to execute a SQL Server stored procedure. This method will close all existing command or reader. | |
ReleaseVerificationLock | ||
RollbackTransaction | Roll back and discard all changes that were made during the transaction on this component. | |
Sleep | ||
ToString | Returns a string that represents the current object. (Inherited from Object.) | |
Trace(Int32, TraceLevel, String, array<Object[]) | Push trace messages to the trace service associated with the request context. | |
Trace(Int32, TraceLevel, array<String[], String, array<Object[]) | Push trace messages to the trace service associated with the request context. | |
TraceEnter | Trace entry to a method with a consistently formatted message and a time stamp. | |
TraceException | Report an exception at TraceLevel.Error to the trace log in a consistent way. | |
TraceLeave | Trace exit from a method with a consistently formatted message and a time stamp. | |
TranslateException | Examines a SQL Type Exception and transforms it into a more significant one.The default behavior is to do nothing; that is, it is to rethrow the original exception.WIT is the only component that currently overrides the current behavior. | |
TranslateSqlException | Not all TFS services use TeamFoundationSqlResourceComponent, but most want to use the common error handling that it contains. Therefore, a static TranslateSqlException can be used externally from the component. | |
VerifyInitialized | Throws an InvalidOperationException if the component is not initialized. | |
VerifyInMasterDbOnAzure | Throws InvalidOperationException if components is used against SQL Azure and the Initial Catalog in the connection string is not master or empty. | |
VerifyNotSqlAzure | Throws NotSupportedException if components are used against SQL Azure. | |
VerifyServiceVersion(String, Int32, Int32%, Int32%) | Connects to the database, takes a shared session lock on the TfsDb resource and verifies that the database supports specified service version.NOTE: This method will be re-written. We must query CONTEXT_INFO(), take a shared lock and query database service version using one query. In addition, we must make sure that the database still supports current component in case we lost connection to the database. | |
VerifyServiceVersion(String, Int32, Int32%, Int32%, Boolean) | This method connects to the database, takes a shared or exclusive session lock on the TfsDb resource and verifies that the database supports specified service version. NOTE: This method will be re-written. We must query CONTEXT_INFO(), take a shared lock and query database service version using one query. In addition, we must ensure that the database still supports current component in case we lost connection to the database. |
Top