Need method Dialect to apply hibernate type over-rides.
-------------------------------------------------------
Key: HHH-5584
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-5584
Project: Hibernate Core
Issue Type: Improvement
Components: core
Affects Versions: 3.6.0.CR1
Environment: 3.6.0.CR1, postgresql
Reporter: Justin Sands
Priority: Minor
There is currently no way to register hibernate type over-rides simply by extending the
Dialect object.
This forces applications to inject custom bootstrapping code, where a simple property
change (the dialect) would suffice.
This could be easily overcome by having the SessionFactory interrogate the dialect to see
if it contains any substitutions.
public class SessionFactoryImpl {
public SessionFactoryImpl(...) {
if (getDialect().getTypeOverrides() != null) {
for (BasicType overrideType : getDialect().getTypeOverrides())
cfg.registerTypeOverride(overrideType);
}
}
}
public abstract class Dialect {
// basic implementation,
public List<BasicType> getTypeOverrides() {
return null;
}
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira