Class PersistenceClient

java.lang.Object
me.hsgamer.hscore.database.client.jpa.PersistenceClient
All Implemented Interfaces:
Client<jakarta.persistence.EntityManagerFactory>

public class PersistenceClient extends Object implements Client<jakarta.persistence.EntityManagerFactory>
The JPA persistence client
  • Constructor Details

    • PersistenceClient

      public PersistenceClient(String name, Setting setting)
      Create a new persistence client
      Parameters:
      name - The name of the persistence client
      setting - The setting of the persistence client
  • Method Details

    • getSetting

      public Setting getSetting()
      Description copied from interface: Client
      Get the setting
      Specified by:
      getSetting in interface Client<jakarta.persistence.EntityManagerFactory>
      Returns:
      the setting
    • getOriginal

      public jakarta.persistence.EntityManagerFactory getOriginal()
      Description copied from interface: Client
      Get the original
      Specified by:
      getOriginal in interface Client<jakarta.persistence.EntityManagerFactory>
      Returns:
      the original
    • getEntityManager

      public jakarta.persistence.EntityManager getEntityManager()
      Get a new entity manager
      Returns:
      The entity manager