Constructor
GomCustomMigrationnew
Declaration
GomMigration*
gom_custom_migration_new (
guint version,
GomCustomMigrationFunc apply_func,
gpointer user_data,
GDestroyNotify user_destroy
)
Description
Creates a new GomCustomMigration that invokes apply_func
when gom_migration_apply() is called.
If apply_func is NULL, applying the migration succeeds immediately
with no work done.
Parameters
version-
Type:
guintThe migration version number.
apply_func-
Type:
GomCustomMigrationFuncCallback to run when the migration is applied.
The argument can be NULL. user_data-
Type:
gpointerUser data to pass to
apply_func.The argument can be NULL.The data is owned by the caller of the function. user_destroy-
Type:
GDestroyNotifyDestroy notify for
user_data.The argument can be NULL.
Return value
Type: GomMigration
A new GomCustomMigration.
| The caller of the function takes ownership of the data, and is responsible for freeing it. |