# SQLiteTransactionListener

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

# SQLiteTransactionListener

*** ** * ** ***

[Kotlin](https://developer.android.com/reference/kotlin/android/database/sqlite/SQLiteTransactionListener "View this page in Kotlin")\|Java

`
public


interface
SQLiteTransactionListener
`  
`


`

|---------------------------------------------------|
| android.database.sqlite.SQLiteTransactionListener |

<br />

*** ** * ** ***

A listener for transaction events.

## Summary

|                                                                                          ### Public methods                                                                                          ||
|------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` abstract void` | ` `[onBegin](https://developer.android.com/reference/android/database/sqlite/SQLiteTransactionListener#onBegin())`() ` Called immediately after the transaction begins.            |
| ` abstract void` | ` `[onCommit](https://developer.android.com/reference/android/database/sqlite/SQLiteTransactionListener#onCommit())`() ` Called immediately before commiting the transaction.      |
| ` abstract void` | ` `[onRollback](https://developer.android.com/reference/android/database/sqlite/SQLiteTransactionListener#onRollback())`() ` Called if the transaction is about to be rolled back. |

## Public methods

### onBegin

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public abstract void onBegin ()
```

Called immediately after the transaction begins.

<br />

### onCommit

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public abstract void onCommit ()
```

Called immediately before commiting the transaction.

<br />

### onRollback

Added in[API level 5](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)  

```
public abstract void onRollback ()
```

Called if the transaction is about to be rolled back.

<br />