Equinox Items Helper

abstract class EquinoxItemsHelper<T : EquinoxItem?>

The EquinoxItemsHelper class is useful to manage all the EquinoxItem database operations

Author

N7ghtm4r3 - Tecknobit

Inheritors

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard
interface BatchQuery
The BatchQuery interface is useful to manage the batch queries to insert or delete values in batch
Link copied to clipboard
InsertCommand list of supported commands to insert records in the batch queries
Link copied to clipboard
The SyncBatchContainer interface is useful to execute the syncBatch method to synchronize the data.

Properties

Link copied to clipboard
private val _IN_CLAUSE_: String = " IN "
IN_CLAUSE in clause query part
Link copied to clipboard
val _VALUES_: String = " VALUES "
VALUES values query part
Link copied to clipboard
val _WHERE_: String = " WHERE "
WHERE where query part
Link copied to clipboard
CLOSED_ROUND_BRACKET closed round bracket character
Link copied to clipboard
val COMMA: String = ","
COMMA comma character
Link copied to clipboard
val DELETE_FROM_: String = "DELETE FROM "
DELETE_FROM_ delete from query command
Link copied to clipboard
protected open var entityManager: EntityManager
entityManager entity manager helper
Link copied to clipboard
OPENED_ROUND_BRACKET opened round bracket character
Link copied to clipboard
QUESTION_MARK question mark character
Link copied to clipboard
val SINGLE_QUOTE: String = "'"
SINGLE_QUOTE single quote character

Functions

Link copied to clipboard
protected open fun batchDelete(table: String, values: List<List<out Any>>, columns: Array<String>)
Method to execute a batch delete of a list of data simultaneously
Link copied to clipboard
protected open fun batchInsert(command: EquinoxItemsHelper.InsertCommand, table: String, values: List<out Any>, batchQuery: EquinoxItemsHelper.BatchQuery, columns: Array<String>)
Method to execute a batch insert of a list of data simultaneously
Link copied to clipboard
private open fun findMaxSize(inValues: List<List<out Any>>): Int
Method to find the max size of a list
Link copied to clipboard
private open fun formatColumns(columns: Array<String>): String
Method to format the columns value for the query
Link copied to clipboard
private open fun formatInClause(columns: Int, inValues: List<out Any>): String
Method to format the in clause for the query
Link copied to clipboard
private open fun formatPlaceholder(columns: Array<String>): String
Method to format the placeholder value for the query
Link copied to clipboard
private open fun formatValuesForQuery(start: String, values: List<out Any>, formatter: String, isToClose: Boolean): String
Method to format a list of values for the query
Link copied to clipboard
private open fun mergeAlternativelyInColumnsValues(inValues: List<List<out Any>>): List<out Any>
Method to merge alternatively different lists
Link copied to clipboard
protected open fun <V> syncBatch(container: EquinoxItemsHelper.SyncBatchContainer, table: String, targetId: String, updatedData: List<V>, batchQuery: EquinoxItemsHelper.BatchQuery)
Method to execute a batch synchronization of a list of data simultaneously