本文整理了Java中org.hibernate.HibernateException.setStackTrace()
方法的一些代码示例,展示了HibernateException.setStackTrace()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。HibernateException.setStackTrace()
方法的具体详情如下:
包路径:org.hibernate.HibernateException
类名称:HibernateException
方法名:setStackTrace
暂无
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException externalizersNotRegistered(final Integer externalizerId, final Class<?> aClass) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), externalizersNotRegistered$str(), externalizerId, aClass));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String registeredExternalizerNotLoadedFromOGMClassloader = "OGM001104: Infinispan Externalizer '%s' was registered but apparently loaded from the wrong module. Aborting as a version mismatch could corrupt stored data.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException externalizerIdNotMatchingType(final Integer externalizerId, final AdvancedExternalizer<?> registeredExternalizer, final AdvancedExternalizer expectedExternalizer) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), externalizerIdNotMatchingType$str(), externalizerId, registeredExternalizer, expectedExternalizer));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String missingCacheConfiguration = "OGM001106: Missing configuration for cache '%1$s' and a default configuration was not provided";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException exceptionGeneratingValueForCounter(final String counterName) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), exceptionGeneratingValueForCounter$str(), counterName));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String cannotInstantiateStoredProcedure = "OGM001111: Cannot instantiate stored procedure '%s' with resolved name '%s'.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException cannotInstantiateStoredProcedure(final String storedProcedureName, final String className, final Exception e) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), cannotInstantiateStoredProcedure$str(), storedProcedureName, className), e);
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
@Override
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException illegalDiscrimantorType(final String arg0) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), illegalDiscrimantorType$str(), arg0));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String unableToConvertStringToDiscriminator = "OGM000027: Could not convert string to discriminator object";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException missingConfigurationProperty(final String arg0) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), missingConfigurationProperty$str(), arg0));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String unsupportedPropertyType = "OGM000053: Value of unsupported type given for configuration property '%1$s': '%2$s'";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException invalidConfigurationUrl(final String arg0, final String arg1) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), invalidConfigurationUrl$str(), arg0, arg1));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String couldNotRetrieveEntityForRetrievalOfGeneratedProperties = "OGM000056: Unable to load record for retrieval of generated properties; Entity type: %1$s, id: %2$s";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException errorOnEntityBatchLoad(final String arg0, final Exception arg1) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), errorOnEntityBatchLoad$str(), arg0), arg1);
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String notALong = "OGM000081: The value set for the configuration property '%1$s' must be a long number. Found '%2$s'.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException multipleEntitiesOutputNotSupported(final String arg0, final java.util.Collection<?> arg1) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), multipleEntitiesOutputNotSupported$str(), arg0, arg1));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String addEntityNotAllowedInNativeQueriesUsingProjection = "OGM000091: Projection and addEntity are not allowed in the same query on <%1$s> %2$s";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException cannotExtractStoredProcedureResultSet(final String arg0, final Object arg1, final Exception arg2) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), cannotExtractStoredProcedureResultSet$str(), arg0, arg1), arg2);
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String cannotExtractTupleFromObject = "OGM000097: Cannot extract tuple from value '%s'.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException errorOnFetchJndiClientProperty(final String arg0) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), errorOnFetchJndiClientProperty$str(), arg0));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String unableToParseOrderByFragment = "OGM000099: Unable to parse order-by fragment: '%s'.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException getPropertyDoesNotExistException(final String typeName, final String property, final ElementType elementType) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), getPropertyDoesNotExistException$str(), typeName, property, elementType));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String getUnsupportedElementTypeException = "OGM000042: The given element type %1$s is neither FIELD nor METHOD.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException unsupportedPropertyType(final String propertyName, final String value) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), unsupportedPropertyType$str(), propertyName, value));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String closedOperationQueue = "OGM000054: It is not possible to add or poll operations from a closed queue";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException entityTupleNotFound(final String collectionRole, final EntityKey entityKey) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), entityTupleNotFound$str(), collectionRole, entityKey));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String failureWhenUsingAttributeConverter = "OGM000083: Failure when using JPA AttributeConverter [%1$s]. Is the datastore type of the converter a supported type for your datastore?";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException addEntityNotAllowedInNativeQueriesUsingProjection(final String table, final String query) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), addEntityNotAllowedInNativeQueriesUsingProjection$str(), table, query));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String cannotExecuteStoredProcedure = "OGM000092: Cannot execute stored procedure '%s'.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException unableToRenderOrderByFragment(final String queryFragment, final Exception e) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), unableToRenderOrderByFragment$str(), queryFragment), e);
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String errorIntrospectingObject = "OGM000101: Error introspecting an object instance.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException unsupportedLockMode(final Class<? extends org.hibernate.ogm.dialect.spi.GridDialect> arg0, final LockMode arg1) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), unsupportedLockMode$str(), new org.hibernate.ogm.util.impl.ClassObjectFormatter(arg0), arg1));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
@Override
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException dialectDoesNotSupportPositionalParametersForStoredProcedures(final Class<?> arg0) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), dialectDoesNotSupportPositionalParametersForStoredProcedures$str(), new org.hibernate.ogm.util.impl.ClassObjectFormatter(arg0)));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String cannotSetStoredProcedureParameter = "OGM000095: Cannot set stored procedure '%s' parameter '%s' with value '%s'.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException unexpectedInstanceType(final String arg0, final String arg1, final Class<?> arg2, final Class<?> arg3) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), unexpectedInstanceType$str(), arg0, arg1, new org.hibernate.ogm.util.impl.ClassObjectFormatter(arg2), new org.hibernate.ogm.util.impl.ClassObjectFormatter(arg3)));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String ambigiousOptionConfiguration = "OGM000047: Either an option configurator may be specified via configuration property '%1$s' or OgmConfiguration#configureOptions() may be called, but not both at the same time.";
代码示例来源:origin: hibernate/hibernate-ogm
@Override
public final HibernateException unexpectedInstanceType(final String propertyName, final String instance, final Class<?> actualClass, final Class<?> expectedClass) {
final HibernateException result = new HibernateException(String.format(getLoggingLocale(), unexpectedInstanceType$str(), propertyName, instance, new ClassObjectFormatter(actualClass), new ClassObjectFormatter(expectedClass)));
final StackTraceElement[] st = result.getStackTrace();
result.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
return result;
}
private static final String ambigiousOptionConfiguration = "OGM000047: Either an option configurator may be specified via configuration property '%1$s' or OgmConfiguration#configureOptions() may be called, but not both at the same time.";
内容来源于网络,如有侵权,请联系作者删除!