Package io.realm.kotlin

Core functions and types.

Types

BaseRealm
Link copied to clipboard
interface BaseRealm : Versioned
Base class for all Realm instances (Realm and MutableRealm).
CompactOnLaunchCallback
Link copied to clipboard
fun fun interface CompactOnLaunchCallback
This interface is used to determine if a Realm file should be compacted the first time the file is opened and before the instance is returned.
Configuration
Link copied to clipboard
interface Configuration
Base configuration options shared between all realm configuration types.
Deleteable
Link copied to clipboard
interface Deleteable
A deleteable is an entity that can be deleted in a write transaction or as part of a migration.
InitialDataCallback
Link copied to clipboard
fun fun interface InitialDataCallback
This interface is used to write data to a Realm file when the file is first created.
InitialRealmFileConfiguration
Link copied to clipboard
data class InitialRealmFileConfiguration(assetFile: String, checksum: String?)
Configuration for pre-bundled asset files used as initial state of the realm file.
LogConfiguration
Link copied to clipboard
data class LogConfiguration(level: LogLevel, loggers: List<RealmLogger>)
Configuration for log events created by a Realm instance.
MutableRealm
Link copied to clipboard
interface MutableRealm : TypedRealm
Represents the writeable state of a Realm file.
Realm
Link copied to clipboard
interface Realm : TypedRealm
A Realm instance is the main entry point for interacting with a persisted realm.
RealmConfiguration
Link copied to clipboard
interface RealmConfiguration : Configuration
A Realm Configuration defining specific setup and configuration for a Realm instance.
TypedRealm
Link copied to clipboard
interface TypedRealm : BaseRealm
A typed realm that can be queried for objects of a specific type.
UpdatePolicy
Link copied to clipboard
enum UpdatePolicy : Enum<UpdatePolicy>
Update policy that controls how to handle import of objects with existing primary keys when import them with MutableRealm.copyToRealm and DynamicMutableRealm.copyToRealm.
Versioned
Link copied to clipboard
interface Versioned
VersionId
Link copied to clipboard
data class VersionId(version: Long) : Comparable<VersionId>
A VersionId representing the transactional id of the Realm itself or it's objects.

Functions

delete
Link copied to clipboard
inline fun <T : BaseRealmObject> MutableRealm.delete()
Deletes all objects of the specified class from the Realm.