接口 JSqlClient

所有超级接口:
SubQueryProvider
所有已知子接口:
JSqlClientImplementor
所有已知实现类:
AbstractJSqlClientDelegate, JLazyInitializationSqlClient

public interface JSqlClient extends SubQueryProvider
  • 方法详细资料

    • newBuilder

      static JSqlClient.Builder newBuilder()
    • createQuery

      <T extends TableProxy<?>> MutableRootQuery<T> createQuery(T table)
    • createUpdate

      MutableUpdate createUpdate(TableProxy<?> table)
    • createDelete

      MutableDelete createDelete(TableProxy<?> table)
    • createAssociationQuery

      <SE, ST extends Table<SE>, TE, TT extends Table<TE>> MutableRootQuery<AssociationTable<SE,ST,TE,TT>> createAssociationQuery(AssociationTable<SE,ST,TE,TT> table)
    • getEntities

      Entities getEntities()
    • getTriggers

      Triggers getTriggers()
      This method is equivalent to `getTriggers(false)`
      返回:
    • getTriggers

      Triggers getTriggers(boolean transaction)
      • If trigger type is 'BINLOG_ONLY'
        • If `transaction` is true, throws exception
        • If `transaction` is false, return binlog trigger
      • If trigger type is 'TRANSACTION_ONLY', returns transaction trigger no matter what the `transaction` is
      • If trigger type is 'BOTH'
        • If `transaction` is true, return transaction trigger
        • If `transaction` is false, return binlog trigger
        Note that the objects returned by different parameters are independent of each other.
      参数:
      transaction -
      返回:
      Trigger
    • getAssociations

      Associations getAssociations(org.babyfish.jimmer.meta.TypedProp.Association<?,?> prop)
    • getAssociations

      Associations getAssociations(org.babyfish.jimmer.meta.ImmutableProp immutableProp)
    • getAssociations

      Associations getAssociations(AssociationType associationType)
    • getCaches

      Caches getCaches()
    • getFilters

      Filters getFilters()
    • getBinLog

      BinLog getBinLog()
    • caches

      @NewChain JSqlClient caches(Consumer<CacheDisableConfig> block)
    • filters

      @NewChain JSqlClient filters(Consumer<FilterConfig> block)
    • disableSlaveConnectionManager

      @NewChain JSqlClient disableSlaveConnectionManager()
    • executor

      @NewChain JSqlClient executor(Executor executor)
    • findById

      @Nullable default <T> T findById(Class<T> type, Object id)
      类型参数:
      T - Entity type or output DTO type
    • findById

      @Nullable default <E> E findById(Fetcher<E> fetcher, Object id)
    • findOneById

      @NotNull default <T> T findOneById(Class<T> type, Object id)
      类型参数:
      T - Entity type or output DTO type
    • findOneById

      @NotNull default <E> E findOneById(Fetcher<E> fetcher, Object id)
    • findByIds

      @NotNull default <T> @NotNull List<T> findByIds(Class<T> type, Iterable<?> ids)
      类型参数:
      T - Entity type or output DTO type
    • findByIds

      @NotNull default <E> @NotNull List<E> findByIds(Fetcher<E> fetcher, Iterable<?> ids)
    • findMapByIds

      @NotNull default <K, T> @NotNull Map<K,T> findMapByIds(Class<T> type, Iterable<K> ids)
      类型参数:
      T - Entity type or output DTO type
    • findMapByIds

      @NotNull default <K, V> @NotNull Map<K,V> findMapByIds(Fetcher<V> fetcher, Iterable<K> ids)
    • save

      default <E> SimpleSaveResult<E> save(E entity, SaveMode mode, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Save an entity object
      类型参数:
      E - The type of saved entity
      参数:
      entity - The saved entity object.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      mode - The save mode of aggregate-root
      associatedMode - The save mode of associated-objects
      返回:
      The saved result for single object
    • save

      default <E> SimpleSaveResult<E> save(E entity, SaveMode mode)
      Save an entity object
      类型参数:
      E - The type of saved entity
      参数:
      entity - The saved entity object.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      mode - The save mode of aggregate-root

      The associated save mode of associated objects is AssociatedSaveMode.REPLACE

      返回:
      The saved result for single object
    • save

      default <E> SimpleSaveResult<E> save(E entity, AssociatedSaveMode associatedMode)
      Save an entity object
      类型参数:
      E - The type of saved entity
      参数:
      entity - The saved entity object.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      associatedMode - The save mode of associated-objects

      The save mode of aggregate-root is SaveMode.UPSERT

      返回:
      The saved result for single object
    • save

      default <E> SimpleSaveResult<E> save(E entity)
      Save an entity object
      类型参数:
      E - The type of saved entity
      参数:
      entity - The saved entity object.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.UPSERT

      The associated save mode of associated objects is AssociatedSaveMode.REPLACE

      返回:
      The saved result for single object
    • save

      default <E> SimpleSaveResult<E> save(org.babyfish.jimmer.Input<E> input, SaveMode mode, AssociatedSaveMode associatedMode)
      Save an input DTO
      类型参数:
      E - The type of saved entity
      参数:
      input - The saved input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      mode - The save mode of aggregate-root
      associatedMode - The save mode of associated-objects
      返回:
      The saved result for single object
    • save

      default <E> SimpleSaveResult<E> save(org.babyfish.jimmer.Input<E> input, SaveMode mode)
      Save an input DTO
      类型参数:
      E - The type of saved entity
      参数:
      input - The saved input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      mode - The save mode of aggregate-root

      The associated save mode of associated objects is AssociatedSaveMode.REPLACE

      返回:
      The saved result for single object
    • save

      default <E> SimpleSaveResult<E> save(org.babyfish.jimmer.Input<E> input, AssociatedSaveMode associatedMode)
      Save an input DTO
      类型参数:
      E - The type of saved entity
      参数:
      input - The saved input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      associatedMode - The save mode of associated-objects

      The save mode of aggregate-root is SaveMode.UPSERT

      返回:
      The saved result for single object
    • save

      default <E> SimpleSaveResult<E> save(org.babyfish.jimmer.Input<E> input)
      Save an input DTO
      类型参数:
      E - The type of saved entity
      参数:
      input - The saved input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.UPSERT

      The associated save mode of associated objects is AssociatedSaveMode.REPLACE

      返回:
      The saved result for single object
    • insert

      default <E> SimpleSaveResult<E> insert(@NotNull E entity)
      Insert an entity object
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The inserted entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • insert

      default <E> SimpleSaveResult<E> insert(@NotNull E entity, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Insert an entity object
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The inserted entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.INSERT_ONLY

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • insertIfAbsent

      default <E> SimpleSaveResult<E> insertIfAbsent(@NotNull E entity)
      Insert an entity object if necessary, if the entity object exists in database, ignore it.
      • If the value of id property decorated by Id is specified, use id value to check whether the entity object exists in database
      • otherwise, if the values of key properties decorated by Key is specified use key values to check whether the entity object exists in database
      • If neither value of id property nor values of key properties is specified, exception will be raised.
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The inserted entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • insertIfAbsent

      default <E> SimpleSaveResult<E> insertIfAbsent(@NotNull E entity, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Insert an entity object if necessary, if the entity object exists in database, ignore it.
      • If the value of id property decorated by Id is specified, use id value to check whether the entity object exists in database
      • otherwise, if the values of key properties decorated by Key is specified use key values to check whether the entity object exists in database
      • If neither value of id property nor values of key properties is specified, exception will be raised.
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The inserted entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.INSERT_IF_ABSENT

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • update

      default <E> SimpleSaveResult<E> update(@NotNull E entity)
      Update an entity object
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The updated entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • update

      default <E> SimpleSaveResult<E> update(@NotNull E entity, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Update an entity object
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The updated entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.UPDATE_ONLY

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • merge

      default <E> SimpleSaveResult<E> merge(@NotNull E entity)
      Merge an entity object
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The merged entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • merge

      default <E> SimpleSaveResult<E> merge(@NotNull E entity, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Merge an entity object
      类型参数:
      E - The type of inserted entity
      参数:
      entity - The merged entity object

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.UPSERT

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • insert

      default <E> SimpleSaveResult<E> insert(@NotNull @NotNull org.babyfish.jimmer.Input<E> input)
      Insert an input DTO
      类型参数:
      E - The type of inserted entity
      参数:
      input - The inserted input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • insert

      default <E> SimpleSaveResult<E> insert(@NotNull @NotNull org.babyfish.jimmer.Input<E> input, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Insert an input DTO
      类型参数:
      E - The type of inserted entity
      参数:
      input - The inserted input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.INSERT_ONLY

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • insertIfAbsent

      default <E> SimpleSaveResult<E> insertIfAbsent(@NotNull @NotNull org.babyfish.jimmer.Input<E> input)
      Insert an input DTO if necessary, that means to convert the input DTO to entity object and save it. If the entity object exists in database, ignore it.
      • If the value of id property decorated by Id is specified, use id value to check whether the entity object exists in database
      • otherwise, if the values of key properties decorated by Key is specified use key values to check whether the entity object exists in database
      • If neither value of id property nor values of key properties is specified, exception will be raised.
      类型参数:
      E - The type of inserted entity
      参数:
      input - The inserted input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • insertIfAbsent

      default <E> SimpleSaveResult<E> insertIfAbsent(@NotNull @NotNull org.babyfish.jimmer.Input<E> input, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Insert an input DTO if necessary, that means to convert the input DTO to entity object and save it. If the entity object exists in database, ignore it.
      • If the value of id property decorated by Id is specified, use id value to check whether the entity object exists in database
      • otherwise, if the values of key properties decorated by Key is specified use key values to check whether the entity object exists in database
      • If neither value of id property nor values of key properties is specified, exception will be raised.
      类型参数:
      E - The type of inserted entity
      参数:
      input - The inserted input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.INSERT_IF_ABSENT

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • update

      default <E> SimpleSaveResult<E> update(@NotNull @NotNull org.babyfish.jimmer.Input<E> input)
      Update an input DTO
      类型参数:
      E - The type of inserted entity
      参数:
      input - The updated input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • update

      default <E> SimpleSaveResult<E> update(@NotNull @NotNull org.babyfish.jimmer.Input<E> input, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Update an input DTO
      类型参数:
      E - The type of inserted entity
      参数:
      input - The updated input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.UPDATE_ONLY

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • merge

      default <E> SimpleSaveResult<E> merge(@NotNull @NotNull org.babyfish.jimmer.Input<E> input)
      Merge an input DTO
      类型参数:
      E - The type of inserted entity
      参数:
      input - The merged input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The save result for single object
    • merge

      default <E> SimpleSaveResult<E> merge(@NotNull @NotNull org.babyfish.jimmer.Input<E> input, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Merge an input DTO
      类型参数:
      E - The type of inserted entity
      参数:
      input - The merged input DTO

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-root is SaveMode.UPSERT

      associatedMode - The associated save mode of associated objects.
      返回:
      The save result for single object
    • saveEntities

      default <E> BatchSaveResult<E> saveEntities(@NotNull @NotNull Iterable<E> entities, @NotNull @NotNull SaveMode mode, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Save some entities objects
      类型参数:
      E - The type of saved entities
      参数:
      entities - The saved entity objects.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      mode - The save mode of aggregate-roots
      associatedMode - The save mode of associated-objects
      返回:
      The saved result for multiple objects
    • saveEntities

      default <E> BatchSaveResult<E> saveEntities(@NotNull @NotNull Iterable<E> entities, @NotNull @NotNull SaveMode mode)
      Save some entities objects
      类型参数:
      E - The type of saved entities
      参数:
      entities - The saved entity objects.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The associated save mode of associated objects is AssociatedSaveMode.REPLACE

      mode - The save mode of aggregate-roots
      返回:
      The saved result for multiple objects
    • saveEntities

      default <E> BatchSaveResult<E> saveEntities(@NotNull @NotNull Iterable<E> entities, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Save some entities objects
      类型参数:
      E - The type of saved entities
      参数:
      entities - The saved entity objects.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-roots is SaveMode.UPSERT

      associatedMode - The save mode of associated-objects
      返回:
      The saved result for multiple objects
    • saveEntities

      default <E> BatchSaveResult<E> saveEntities(@NotNull @NotNull Iterable<E> entities)
      Save some entities objects
      类型参数:
      E - The type of saved entities
      参数:
      entities - The saved entity objects.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The saved result for multiple objects
    • saveInputs

      default <E> BatchSaveResult<E> saveInputs(@NotNull @NotNull Iterable<org.babyfish.jimmer.Input<E>> inputs, @NotNull @NotNull SaveMode mode, @NotNull @NotNull AssociatedSaveMode associatedMode)
      Save some input DTOs
      类型参数:
      E - The type of saved entities
      参数:
      inputs - The saved input DTOs.

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      mode - The save mode of aggregate-roots
      associatedMode - The save mode of associated-objects
      返回:
      The saved result for multiple objects
    • saveInputs

      default <E> BatchSaveResult<E> saveInputs(@NotNull @NotNull Iterable<org.babyfish.jimmer.Input<E>> inputs, @NotNull @NotNull SaveMode mode)
      Save some input DTOs
      类型参数:
      E - The type of saved entities
      参数:
      inputs - The saved input DTOs.

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The associated save mode of associated objects is AssociatedSaveMode.REPLACE

      mode - The save mode of aggregate-roots
      返回:
      The saved result for multiple objects
    • saveInputs

      default <E> BatchSaveResult<E> saveInputs(@NotNull @NotNull Iterable<org.babyfish.jimmer.Input<E>> inputs, AssociatedSaveMode associatedMode)
      Save some input DTOs
      类型参数:
      E - The type of saved entities
      参数:
      inputs - The saved input DTOs.

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      The save mode of aggregate-roots is SaveMode.UPSERT

      associatedMode - The save mode of associated-objects
      返回:
      The saved result for multiple objects
    • saveInputs

      default <E> BatchSaveResult<E> saveInputs(@NotNull @NotNull Iterable<org.babyfish.jimmer.Input<E>> inputs)
      Save some input DTOs
      类型参数:
      E - The type of saved entities
      参数:
      inputs - The saved input DTOs.

      In terms of internal mechanisms, any type of Input DTO is automatically converted into an entity object of the same type.

      Note: The jimmer entity is not POJO, it can easily express data structures of arbitrary shape, you can use it to save data structures of arbitrary shape.

      Unlike most JVM ORMs, Jimmer does not sepcified the shape of the saved data structure by using configuration such as `insertable`, `updatable` or `cascade`; instead, it uses the dynamic nature of entity object itself to describe the shape of saved data structure, without prior design

      Unspecified properties will be ignored, only the specified properties (whether null or not) will be saved. In addition to objects with only id property, any associated objects will result in deeper recursive saves.

      返回:
      The saved result for multiple objects
    • deleteById

      default DeleteResult deleteById(@NotNull @NotNull Class<?> type, @NotNull @NotNull Object id, @NotNull @NotNull DeleteMode mode)
    • deleteById

      default DeleteResult deleteById(Class<?> type, Object id)
    • deleteByIds

      default DeleteResult deleteByIds(Class<?> type, Iterable<?> ids, DeleteMode mode)
    • deleteByIds

      default DeleteResult deleteByIds(Class<?> type, Iterable<?> ids)