func OpenOptimisticTransactionDb(
	opts *Options,
	name string,
) (*OptimisticTransactionDB, error) {
	var (
		cErr  *C.char
		cName = C.CString(name)
	)
	defer C.free(unsafe.Pointer(cName))
	db := C.rocksdb_optimistictransactiondb_open(
		opts.c, cName, &cErr)
	if cErr != nil {
		defer C.free(unsafe.Pointer(cErr))
		return nil, errors.New(C.GoString(cErr))
	}
	baseDB := C.rocksdb_optimistictransactiondb_get_base_db(db)
	return &OptimisticTransactionDB{
		baseDB: &DB{
			name: name,
			c:    baseDB,
			opts: opts,
		},
		name: name,
		c:    db,
		opts: opts,
	}, nil
}
// OpenOptimisticTransactionDb opens a database with the specified options.
OpenOptimisticTransactionDb opens a database with the specified options.
// OpenOptimisticTransactionDb opens a database with the specified options .
func OpenOptimisticTransactionDb(
	opts *Options,
	name string,
) (*OptimisticTransactionDB, error) {
	var (
		cErr  *C.char
		cName = C.CString(name)
	)
	defer C.free(unsafe.Pointer(cName))
	db := C.rocksdb_optimistictransactiondb_open(
		opts.c, cName, &cErr)
	if cErr != nil {
		defer C.free(unsafe.Pointer(cErr))
		return nil, errors.New(C.GoString(cErr))
	}
	baseDB := C.rocksdb_optimistictransactiondb_get_base_db(db)
	return &OptimisticTransactionDB{
		baseDB: &DB{
			name: name,
			c:    baseDB,
			opts: opts,
		},
		name: name,
		c:    db,
		opts: opts,
	}, nil
}
func OpenOptimisticTransactionDb ( opts * Options , name string , ) ( * OptimisticTransactionDB , error ) { var ( cErr * C . char cName = C . CString ( name ) ) defer C . free ( unsafe . Pointer ( cName ) ) db := C . rocksdb_optimistictransactiondb_open ( opts . c , cName , & cErr ) if cErr != nil { defer C . free ( unsafe . Pointer ( cErr ) ) return nil , errors . New ( C . GoString ( cErr ) ) } baseDB := C . rocksdb_optimistictransactiondb_get_base_db ( db ) return & OptimisticTransactionDB { baseDB : & DB { name : name , c : baseDB , opts : opts , } , name : name , c : db , opts : opts , } , nil }
OpenOptimisticTransactionDb opens a database with the specified options.
OpenOptimisticTransactionDb opens a database with the specified options .