CharacterType.nullSafeSet
Code IndexAdd Codota to your IDE (free)

Best Java code snippets using org.hibernate.type.CharacterType.nullSafeSet (Showing top 2 results out of 315)

origin: OpenNMS/opennms

@Override
public void nullSafeSet(final PreparedStatement st, final Object value, final int index) throws HibernateException, SQLException {
  if (value == null) {
    StringType.INSTANCE.nullSafeSet(st, null, index);
  } else if (value instanceof NodeLabelSource){
    CharacterType.INSTANCE.nullSafeSet(st, ((NodeLabelSource)value).toString().charAt(0), index);
  } else if (value instanceof String){
    for (NodeLabelSource type : NodeLabelSource.values()) {
      if (type.toString().equals(value)) {
        CharacterType.INSTANCE.nullSafeSet(st, type.toString().charAt(0), index);
      }
    }
  }
}
origin: OpenNMS/opennms

@Override
public void nullSafeSet(final PreparedStatement st, final Object value, final int index) throws HibernateException, SQLException {
  if (value == null) {
    StringType.INSTANCE.nullSafeSet(st, null, index);
  } else if (value instanceof NodeType){
    CharacterType.INSTANCE.nullSafeSet(st, ((NodeType)value).toString().charAt(0), index);
  } else if (value instanceof String){
    for (NodeType type : NodeType.values()) {
      if (type.toString().equals(value)) {
        CharacterType.INSTANCE.nullSafeSet(st, type.toString().charAt(0), index);
      }
    }
  }
}
org.hibernate.typeCharacterTypenullSafeSet

Popular methods of CharacterType

  • getName
  • fromString
  • toString
  • <init>
  • nullSafeGet

Popular in Java

  • Start an intent from android
  • getApplicationContext (Context)
  • getSharedPreferences (Context)
  • orElseThrow (Optional)
  • RandomAccessFile (java.io)
    Allows reading from and writing to a file in a random-access manner. This is different from the uni-
  • BigDecimal (java.math)
    An immutable arbitrary-precision signed decimal.A value is represented by an arbitrary-precision "un
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin

For IntelliJ IDEA,
Android Studio or Eclipse

  • Search for JavaScript code betaCodota IntelliJ IDEA pluginCodota Android Studio pluginCode IndexSign in
  • EnterpriseFAQAboutBlogContact Us
  • Plugin user guideTerms of usePrivacy policyCodeboxFind Usages
Add Codota to your IDE (free)