Class ObjectArgumentFactory

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.Integer sqlType  
      private java.lang.Class<?> type  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private ObjectArgumentFactory​(java.lang.Class<?> type, java.lang.Integer sqlType)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Optional<Argument> build​(java.lang.reflect.Type expectedType, java.lang.Object value, ConfigRegistry config)
      Returns an Argument for the given value if the factory supports it; empty otherwise.
      static ArgumentFactory create​(java.lang.Class<?> type)
      Match the given type and bind as an object without SQL type information.
      static ArgumentFactory create​(java.lang.Class<?> type, java.lang.Integer sqlType)
      Match the given type and bind as an object with the given SQL type information
      java.util.Optional<java.util.function.Function<java.lang.Object,​Argument>> prepare​(java.lang.reflect.Type expectedType, ConfigRegistry config)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • type

        private final java.lang.Class<?> type
      • sqlType

        private final java.lang.Integer sqlType
    • Constructor Detail

      • ObjectArgumentFactory

        private ObjectArgumentFactory​(java.lang.Class<?> type,
                                      java.lang.Integer sqlType)
    • Method Detail

      • create

        public static ArgumentFactory create​(java.lang.Class<?> type)
        Match the given type and bind as an object without SQL type information.
        Parameters:
        type - the Java type to match
        Returns:
        an ArgumentFactory that produces ObjectArguments for values of the supplied type
      • create

        public static ArgumentFactory create​(java.lang.Class<?> type,
                                             java.lang.Integer sqlType)
        Match the given type and bind as an object with the given SQL type information
        Parameters:
        type - the Java type to match
        sqlType - the SQL type to bind
        Returns:
        an ArgumentFactory that produces ObjectArguments for values of the supplied type
        See Also:
        Types