Tabnine Logo
org.h2.message
Code IndexAdd Tabnine to your IDE (free)

How to use org.h2.message

Best Java code snippets using org.h2.message (Showing top 20 results out of 315)

origin: com.h2database/h2

/**
 * Write a message with trace level DEBUG to the trace system.
 *
 * @param s the message
 */
public void debug(String s) {
  if (isEnabled(TraceSystem.DEBUG)) {
    traceWriter.write(TraceSystem.DEBUG, module, s, null);
  }
}
origin: com.h2database/h2

/**
 * Write trace information in the form objectName.text.
 *
 * @param text the trace text
 */
protected void debugCode(String text) {
  if (trace.isDebugEnabled()) {
    trace.debugCode(getTraceObjectName() + "." + text);
  }
}
origin: com.h2database/h2

/**
 * Get a SQL exception meaning this feature is not supported.
 *
 * @param message the message
 * @return the SQL exception
 */
protected SQLException unsupported(String message) {
  try {
    throw DbException.getUnsupportedException(message);
  } catch (Exception e) {
    return logAndConvert(e);
  }
}
origin: com.h2database/h2

@Override
public int readLob(long lobId, byte[] hmac, long offset, byte[] buff,
    int off, int length) {
  throw DbException.throwInternalError();
}
origin: com.h2database/h2

/**
 * [Not supported] Checks if unwrap can return an object of this class.
 *
 * @param iface the class
 */
@Override
public boolean isWrapperFor(Class<?> iface) throws SQLException {
  throw DbException.getUnsupportedException("isWrapperFor");
}
origin: com.h2database/h2

@Override
public void checkWritingAllowed() {
  if (readOnly) {
    throw DbException.get(ErrorCode.DATABASE_IS_READ_ONLY);
  }
  if (fileLockMethod == FileLockMethod.SERIALIZED) {
    if (!reconnectChangePending) {
      throw DbException.get(ErrorCode.DATABASE_IS_READ_ONLY);
    }
  }
}
origin: com.h2database/h2

/**
 * Check if the trace level is equal or higher than INFO.
 *
 * @return true if it is
 */
public boolean isInfoEnabled() {
  return isEnabled(TraceSystem.INFO);
}
origin: com.h2database/h2

public Rownum(Prepared prepared) {
  if (prepared == null) {
    throw DbException.throwInternalError();
  }
  this.prepared = prepared;
}
origin: com.h2database/h2

/**
 * Write a message with trace level INFO to the trace system.
 *
 * @param s the message
 */
public void info(String s) {
  if (isEnabled(TraceSystem.INFO)) {
    traceWriter.write(TraceSystem.INFO, module, s, null);
  }
}
origin: com.h2database/h2

/**
 * Write trace information as a method call in the form
 * objectName.methodName().
 *
 * @param methodName the method name
 */
protected void debugCodeCall(String methodName) {
  if (trace.isDebugEnabled()) {
    trace.debugCode(getTraceObjectName() + "." + methodName + "();");
  }
}
origin: com.h2database/h2

private static JdbcSavepoint convertSavepoint(Savepoint savepoint) {
  if (!(savepoint instanceof JdbcSavepoint)) {
    throw DbException.get(ErrorCode.SAVEPOINT_IS_INVALID_1,
        "" + savepoint);
  }
  return (JdbcSavepoint) savepoint;
}
origin: com.h2database/h2

/**
 * Check if the trace level is equal or higher than DEBUG.
 *
 * @return true if it is
 */
public boolean isDebugEnabled() {
  return isEnabled(TraceSystem.DEBUG);
}
origin: com.h2database/h2

private void removeFromLinkedList(CacheObject rec) {
  if (SysProperties.CHECK && rec == head) {
    DbException.throwInternalError("try to remove head");
  }
  rec.cachePrevious.cacheNext = rec.cacheNext;
  rec.cacheNext.cachePrevious = rec.cachePrevious;
  // TODO cache: mystery: why is this required? needs more memory if we
  // don't do this
  rec.cacheNext = null;
  rec.cachePrevious = null;
}
origin: com.h2database/h2

/**
 * Write Java source code with trace level DEBUG to the trace system.
 *
 * @param java the source code
 */
void debugCode(String java) {
  if (isEnabled(TraceSystem.DEBUG)) {
    traceWriter.write(TraceSystem.DEBUG, module, lineSeparator +
        "/**/" + java, null);
  }
}
origin: com.h2database/h2

/**
 * Gets a SQL exception meaning this feature is not supported.
 *
 * @param message what exactly is not supported
 * @return the exception
 */
public static DbException getUnsupportedException(String message) {
  return get(ErrorCode.FEATURE_NOT_SUPPORTED_1, message);
}
origin: com.h2database/h2

public ConditionAndOr(int andOrType, Expression left, Expression right) {
  this.andOrType = andOrType;
  this.left = left;
  this.right = right;
  if (SysProperties.CHECK && (left == null || right == null)) {
    DbException.throwInternalError(left + " " + right);
  }
}
origin: com.h2database/h2

/**
 * Write a message with trace level ERROR to the trace system.
 *
 * @param t the exception
 * @param s the message
 */
public void error(Throwable t, String s) {
  if (isEnabled(TraceSystem.ERROR)) {
    traceWriter.write(TraceSystem.ERROR, module, s, t);
  }
}
origin: com.h2database/h2

/**
 * Write a message with trace level INFO to the trace system.
 *
 * @param t the exception
 * @param s the message
 */
void info(Throwable t, String s) {
  if (isEnabled(TraceSystem.INFO)) {
    traceWriter.write(TraceSystem.INFO, module, s, t);
  }
}
origin: com.h2database/h2

/**
 * Write a message with trace level DEBUG to the trace system.
 * @param t the exception
 * @param s the message
 */
public void debug(Throwable t, String s) {
  if (isEnabled(TraceSystem.DEBUG)) {
    traceWriter.write(TraceSystem.DEBUG, module, s, t);
  }
}
origin: com.h2database/h2

/**
 * Write Java source code with trace level INFO to the trace system.
 *
 * @param java the source code
 */
public void infoCode(String java) {
  if (isEnabled(TraceSystem.INFO)) {
    traceWriter.write(TraceSystem.INFO, module, lineSeparator +
        "/**/" + java, null);
  }
}
org.h2.message

Most used classes

  • DbException
    This exception wraps a checked exception. It is used in methods where checked exceptions are not sup
  • Trace
    This class represents a trace module.
  • TraceObject
    The base class for objects that can print trace information about themselves.
  • TraceSystem
    The trace mechanism is the logging facility of this database. There is usually one trace system per
  • TraceWriter
    The backend of the trace system must implement this interface. Two implementations are supported: th
  • InternalException,
  • Message
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now