Пример #1
0
        /// <summary>
        /// Command factory.
        /// </summary>
        /// <returns>An empty instance of <see cref="SqlCommand"/>.</returns>
        protected override IDbCommand /*!*/ CreateCommand()
        {
            SqlCommand       command = new SqlCommand();
            MsSqlLocalConfig local   = MsSqlConfiguration.GetLocal(context);

            command.CommandTimeout = (local.Timeout > 0) ? local.Timeout : 0;
            return(command);
        }
Пример #2
0
 /// <summary>
 /// Called by the Core after the library is loaded.
 /// </summary>
 protected override void Loaded(PhpLibraryAttribute assemblyAttribute, LibraryConfigStore configStore)
 {
     base.Loaded(assemblyAttribute, configStore);
     singleton = this;
     MsSqlConfiguration.RegisterLegacyOptions();
 }