Uses of Interface
is.codion.framework.domain.entity.Entity.Key
Packages that use Entity.Key
Package
Description
Package configuration values:
EntityConnectionProvider.CLIENT_DOMAIN_TYPE
EntityConnectionProvider.CLIENT_CONNECTION_TYPE
EntityConnectionProvider.DESCRIPTION
Package configuration values:
EntityValidator.STRICT_VALIDATION
Entities.VALIDATE_FOREIGN_KEYS
Entities.STRICT_DESERIALIZATION
AttributeDefinition.FRACTION_DIGITSAttributeDefinition.NUMBER_GROUPINGAttributeDefinition.GROUPING_SEPARATORAttributeDefinition.DECIMAL_SEPARATORAttributeDefinition.USE_LEXICAL_STRING_COMPARATORAttributeDefinition.ROUNDING_MODEForeignKeyDefinition.REFERENCE_DEPTH
Provides a type-safe condition API for building SQL WHERE clauses programmatically.
Package configuration values:
EntityApplicationModel.USER_PREFERENCES
EntityApplicationModel.RESTORE_DEFAULT_PREFERENCES
EntityApplicationModel.PREFERENCES_KEY
EntityEditModel.EDIT_EVENTS
EntityEditModel.EntityEditor.PERSIST_FOREIGN_KEYS
EntityQueryModel.LIMIT
EntityTableModel.ON_INSERT
EntityTableModel.ORDER_QUERY
ForeignKeyModelLink.SET_CONDITION_ON_INSERT
ForeignKeyModelLink.SET_VALUE_ON_INSERT
ForeignKeyModelLink.REFRESH_ON_SELECTION
ForeignKeyModelLink.CLEAR_CONDITION_ON_EMPTY_SELECTION
ForeignKeyModelLink.CLEAR_VALUE_ON_EMPTY_SELECTION
EntitySearchModel.DEFAULT_LIMIT
Package configuration values:
EntityComboBoxModel.EDIT_EVENTS
-
Uses of Entity.Key in is.codion.framework.db
Methods in is.codion.framework.db that return Entity.KeyModifier and TypeMethodDescriptionInserts the given entity, returning the primary key.Methods in is.codion.framework.db that return types with arguments of type Entity.KeyModifier and TypeMethodDescriptionEntityConnection.insert(Collection<Entity> entities) Inserts the given entities, returning the primary keys.Methods in is.codion.framework.db with parameters of type Entity.KeyModifier and TypeMethodDescriptionvoidEntityConnection.delete(Entity.Key key) Deletes the entity with the given primary key.EntityConnection.select(Entity.Key key) Selects an entity by keyMethod parameters in is.codion.framework.db with type arguments of type Entity.KeyModifier and TypeMethodDescriptionvoidEntityConnection.delete(Collection<Entity.Key> keys) Deletes the entities with the given primary keys.EntityConnection.BatchInsert.Builder.onInsert(Consumer<Collection<Entity.Key>> onInsert) EntityConnection.select(Collection<Entity.Key> keys) Selects entities based on the givenkeys -
Uses of Entity.Key in is.codion.framework.db.rmi
Methods in is.codion.framework.db.rmi that return Entity.KeyModifier and TypeMethodDescriptionInserts the given entity, returning the primary key.Methods in is.codion.framework.db.rmi that return types with arguments of type Entity.KeyModifier and TypeMethodDescriptionRemoteEntityConnection.insert(Collection<Entity> entities) Inserts the given entities, returning the primary keys in the same order as they were received.Methods in is.codion.framework.db.rmi with parameters of type Entity.KeyModifier and TypeMethodDescriptionvoidRemoteEntityConnection.delete(Entity.Key key) Deletes an entity according to the given primary key.RemoteEntityConnection.select(Entity.Key key) Selects an entity by keyMethod parameters in is.codion.framework.db.rmi with type arguments of type Entity.KeyModifier and TypeMethodDescriptionvoidRemoteEntityConnection.delete(Collection<Entity.Key> keys) Deletes the entities with the given primary keys.RemoteEntityConnection.select(Collection<Entity.Key> keys) Selects entities based on the givenkeys -
Uses of Entity.Key in is.codion.framework.domain.entity
Methods in is.codion.framework.domain.entity that return Entity.KeyModifier and TypeMethodDescriptionEntity.Key.Builder.build()Builds the key instanceEntity.key(ForeignKey foreignKey) Returns the key referenced by the givenForeignKey, if the reference is null this method returns null.Entity.originalPrimaryKey()Returns the primary key of this entity, in its original state.<T> Entity.KeyEntities.primaryKey(EntityType entityType, @Nullable T value) Creates a newEntity.Keyinstance of the given entityType, initialised with the given valueEntities entities = domain.entities(); // Create a single-value primary key Entity.Key customerKey = entities.primaryKey(Customer.TYPE, 42); // Use the key to fetch an entity Entity customer = connection.selectSingle(customerKey); // Keys can be compared Entity.Key anotherKey = entities.primaryKey(Customer.TYPE, 42); customerKey.equals(anotherKey); // true // Null values are allowed Entity.Key nullKey = entities.primaryKey(Customer.TYPE, null);Entity.primaryKey()Returns the primary key of this entity.<T> Entity.KeyEntityDefinition.primaryKey(T value) Creates a newEntity.Keyinstance based on this definition, initialised with the given valueMethods in is.codion.framework.domain.entity that return types with arguments of type Entity.KeyModifier and TypeMethodDescriptionstatic LinkedHashMap<EntityType, List<Entity.Key>> Entity.Key.groupByType(Collection<Entity.Key> keys) Returns a LinkedHashMap containing the given entity keys mapped to their entityTypes, respecting the iteration order of the given collectionstatic Collection<Entity.Key> Entity.keys(ForeignKey foreignKey, Collection<Entity> entities) Returns the non-null keys referenced by the givenForeignKeystatic Collection<Entity.Key> Entity.originalPrimaryKeys(Collection<Entity> entities) Returns the primary keys of the given entities with their original values.static Map<Entity.Key, Entity> Entity.primaryKeyMap(Collection<Entity> entities) Maps the given entities to their primary key, assuming each entity appears only once in the given collection.<T> List<Entity.Key> Entities.primaryKeys(EntityType entityType, Collection<T> values) Creates newEntity.Keyinstances of the given entityType, initialised with the given valuesEntities entities = domain.entities(); // Create multiple keys at once List<Entity.Key> customerKeys = entities.primaryKeys(Customer.TYPE, List.of(1, 2, 3, 4, 5));<T> List<Entity.Key> Entities.primaryKeys(EntityType entityType, T... values) Creates newEntity.Keyinstances of the given entityType, initialised with the given valuesEntities entities = domain.entities(); // Create multiple keys at once List<Entity.Key> customerKeys = entities.primaryKeys(Customer.TYPE, 1, 2, 3, 4, 5); // Fetch multiple entities List<Entity> customers = connection.select(customerKeys); // Varargs syntax allows flexible usage List<Entity.Key> keys = entities.primaryKeys(Order.TYPE, "ORD-001", "ORD-002", "ORD-003");static Collection<Entity.Key> Entity.primaryKeys(Collection<Entity> entities) Returns the primary keys of the given entities.Methods in is.codion.framework.domain.entity with parameters of type Entity.KeyModifier and TypeMethodDescriptionstatic Entity.BuilderEntity.builder(Entity.Key key) static EntityEntity.entity(Entity.Key key) Method parameters in is.codion.framework.domain.entity with type arguments of type Entity.KeyModifier and TypeMethodDescriptionstatic LinkedHashMap<EntityType, List<Entity.Key>> Entity.Key.groupByType(Collection<Entity.Key> keys) Returns a LinkedHashMap containing the given entity keys mapped to their entityTypes, respecting the iteration order of the given collectionstatic <T> Collection<@Nullable T> Entity.values(Collection<Entity.Key> keys) Retrieves the values of the given keys, assuming they are single column keys. -
Uses of Entity.Key in is.codion.framework.domain.entity.condition
Methods in is.codion.framework.domain.entity.condition with parameters of type Entity.KeyModifier and TypeMethodDescriptionstatic ConditionCondition.key(Entity.Key key) Creates aConditionbased on the given keyMethod parameters in is.codion.framework.domain.entity.condition with type arguments of type Entity.KeyModifier and TypeMethodDescriptionstatic ConditionCondition.keys(Collection<Entity.Key> keys) Creates aConditionbased on the given keys. -
Uses of Entity.Key in is.codion.framework.json.domain
Fields in is.codion.framework.json.domain with type parameters of type Entity.KeyModifier and TypeFieldDescriptionstatic final com.fasterxml.jackson.core.type.TypeReference<List<Entity.Key>> EntityObjectMapper.KEY_LIST_REFERENCEMethods in is.codion.framework.json.domain that return types with arguments of type Entity.KeyModifier and TypeMethodDescriptionEntityObjectMapper.deserializeKeys(InputStream inputStream) Deserializes the given JSON input stream into a list of Key instancesEntityObjectMapper.deserializeKeys(String jsonString) Deserializes the given JSON string into a list of Key instances -
Uses of Entity.Key in is.codion.framework.model
Method parameters in is.codion.framework.model with type arguments of type Entity.KeyModifier and TypeMethodDescriptionfinal voidAbstractEntityTableModel.refresh(Collection<Entity.Key> keys) voidEntityTableModel.refresh(Collection<Entity.Key> keys) Refreshes the entities with the given keys by re-selecting them from the underlying database.final voidAbstractEntityTableModel.select(Collection<Entity.Key> keys) voidEntityTableModel.select(Collection<Entity.Key> keys) Selects entities according to the primary keys inprimaryKeysprotected voidAbstractEntityEditModel.updated(ForeignKey foreignKey, Map<Entity.Key, Entity> entities) Called when entities of the type referenced by the given foreign key have been updated.protected voidAbstractEntityTableModel.updated(ForeignKey foreignKey, Map<Entity.Key, Entity> entities) Called when entities of the type referenced by the given foreign key are updated -
Uses of Entity.Key in is.codion.swing.framework.model.component
Methods in is.codion.swing.framework.model.component that return types with arguments of type Entity.KeyMethods in is.codion.swing.framework.model.component with parameters of type Entity.KeyModifier and TypeMethodDescriptionEntityComboBoxModel.find(Entity.Key primaryKey) voidEntityComboBoxModel.select(Entity.Key primaryKey) Selects the entity with the given primary key, whether included or filtered.voidEntityComboBoxModel.ForeignKeyFilter.set(Entity.Key key) Filters the combo box model so that only items referencing the given key are included.Method parameters in is.codion.swing.framework.model.component with type arguments of type Entity.KeyModifier and TypeMethodDescriptionvoidEntityComboBoxModel.ForeignKeyFilter.set(Collection<Entity.Key> keys) Filters the combo box model so that only items referencing the given keys are included.