Пример #1
0
        internal SQLiteConnectionWrapper CreateConnectionWrapper()
        {
            SQLiteConnectionWrapper wrapper = null;

            if (IsPersistentConnection)
            {
                if (null == _connection)
                {
                    _connection = CreateNewConnection();
                }

                wrapper = new PersistentSQLiteConnectionWrapper( _connection );
            }
            else
            {
                _connection = CreateNewConnection();
                wrapper = new TransientSQLiteConnectionWrapper( _connection );
            }

            return wrapper;
        }
Пример #2
0
        internal SQLiteConnectionWrapper CreateConnectionWrapper()
        {
            SQLiteConnectionWrapper wrapper = null;

            if (IsPersistentConnection)
            {
                if (null == _connection)
                {
                    _connection = CreateNewConnection();
                }

                wrapper = new PersistentSQLiteConnectionWrapper(_connection);
            }
            else
            {
                _connection = CreateNewConnection();
                wrapper     = new TransientSQLiteConnectionWrapper(_connection);
            }

            return(wrapper);
        }