# Functions
AsGormScope convert following types to a func(*gorm.DB)*gorm.DB: - Option or slice of Option - Condition or slice of Condition - func(*gorm.DB)*gorm.DB (noop) - slice of func(*gorm.DB)*gorm.DB
This function is intended for custom repository implementations.
ErrorOnZeroRows a post-exec option that force repository returns error in case of db.AffectedRows == 0 This option is useful on certain operations such as CrudRepository.Delete, or CrudRepository.Update, which doesn't return error if there is no row get affected/deleted.
Joins is an Option for Find* operations, typically used to populate "ToOne" relationship using JOIN clause e.g.
MustApplyConditions takes a slice of Condition and apply it to the given gorm.DB.
MustApplyOptions takes a slice of Option and apply it to the given gorm.DB.
Omit is an Option specifying fields that you want to ignore when creating, updating and querying.
Or is a Condition that directly bridge parameters to (*gorm.DB).Or().
Page is an Option specifying pagination when retrieve records from database page: page number started with 0 size: page size (# of records per page) e.g.
Preload is an Option for Find* operations, typically used to populate relationship fields using separate queries e.g.
Select is an Option specify fields that you want when querying, creating, updating.
Sort is an Option specifying order when retrieve records from database by using column.
SortBy an Option similar to Sort, but specifying model's field name This Option also support order by direct "ToOne" relation's field when used together with Joins.
No description provided by the author
Where is a Condition that directly bridge parameters to (*gorm.DB).Where().
# Variables
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Structs
GormCrud implements CrudRepository and can be embedded into any repositories using gorm as ORM.
No description provided by the author
GormMetadata implements GormSchemaResolver.
GormUtils implements Utility interface.
# Interfaces
Condition is typically used for generic CRUD repository supported condition depends on operation and underlying implementation: - map[string]interface{} (should be generally supported) e.g.
No description provided by the author
Factory usually used in repository creation.
No description provided by the author
GormSchemaResolver extends SchemaResolver to expose more schema related functions.
Option is typically used for generic CRUD repository supported options depends on operation and underlying implementation - Omit for read/write - Joins for read - Preload for read - Select for read/write - Sort for read - Page for read - func(*gorm.DB) *gormDB - ..
SchemaResolver resolves schema related values.
Utility is a collection of repository related patterns that are useful for common service layer implementation.
# Type aliases
No description provided by the author