Enum CommunityDatabase

  • All Implemented Interfaces:
    Serializable, Comparable<CommunityDatabase>

    public enum CommunityDatabase
    extends Enum<CommunityDatabase>
    A list of community maintained relational database systems for which Hibernate can resolve a Dialect. However, Hibernate can work with other database systems that are not listed by the Database enumeration, as long as a Dialect implementation class is provided via the hibernate.dialect configuration property.
    • Method Detail

      • values

        public static CommunityDatabase[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (CommunityDatabase c : CommunityDatabase.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static CommunityDatabase valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • matchesResolutionInfo

        public boolean matchesResolutionInfo​(org.hibernate.engine.jdbc.dialect.spi.DialectResolutionInfo info)
        Does this database match the given metadata?
      • productNameMatches

        public abstract boolean productNameMatches​(String productName)
        Does this database have the given product name?
      • createDialect

        public abstract org.hibernate.dialect.Dialect createDialect​(org.hibernate.engine.jdbc.dialect.spi.DialectResolutionInfo info)
        Create a Dialect for the given metadata.
      • getDriverClassName

        public String getDriverClassName​(String jdbcUrl)
        Get the name of the JDBC driver class for this database, or null if we're not too sure what it should be.
      • getUrlPrefix

        public String getUrlPrefix()
        Get the JDBC URL prefix used by this database.
      • matchesUrl

        public boolean matchesUrl​(String jdbcUrl)
        Does the given JDBC URL connect to this database?