java.lang.Object
ch.tocco.nice2.persist.core.impl.hibernate.dialect.GlobSqlFunction
All Implemented Interfaces:
org.hibernate.dialect.function.SQLFunction

public class GlobSqlFunction extends Object implements org.hibernate.dialect.function.SQLFunction
Implements the functionality of the 'glob' user type. Replaces the '*' and '?' chars with '%' and '_' in the like pattern.
  • Constructor Details

    • GlobSqlFunction

      public GlobSqlFunction()
  • Method Details

    • hasArguments

      public boolean hasArguments()
      Specified by:
      hasArguments in interface org.hibernate.dialect.function.SQLFunction
    • hasParenthesesIfNoArguments

      public boolean hasParenthesesIfNoArguments()
      Specified by:
      hasParenthesesIfNoArguments in interface org.hibernate.dialect.function.SQLFunction
    • getReturnType

      public org.hibernate.type.Type getReturnType(org.hibernate.type.Type firstArgumentType, org.hibernate.engine.spi.Mapping mapping) throws org.hibernate.QueryException
      Specified by:
      getReturnType in interface org.hibernate.dialect.function.SQLFunction
      Throws:
      org.hibernate.QueryException
    • render

      public String render(org.hibernate.type.Type firstArgumentType, List arguments, org.hibernate.engine.spi.SessionFactoryImplementor factory) throws org.hibernate.QueryException
      Specified by:
      render in interface org.hibernate.dialect.function.SQLFunction
      Throws:
      org.hibernate.QueryException