Class GeneratorSqlObjectFactory

    • Constructor Detail

      • GeneratorSqlObjectFactory

        GeneratorSqlObjectFactory()
    • Method Detail

      • accepts

        public boolean accepts​(java.lang.Class<?> extensionType)
        Description copied from interface: ExtensionFactory
        Returns true if the factory can process the given extension type.
        Specified by:
        accepts in interface ExtensionFactory
        Parameters:
        extensionType - the extension type
        Returns:
        whether the factory can produce an extension of the given type
      • attach

        public <E> E attach​(java.lang.Class<E> extensionType,
                            HandleSupplier handleSupplier)
        Attach a sql object from a jdbi generator created class.
        Specified by:
        attach in interface ExtensionFactory
        Type Parameters:
        E - the extension type
        Parameters:
        extensionType - the type of sql object to create.
        handleSupplier - the Handle instance to attach this sql object to.
        Returns:
        the new sql object bound to this handle.
        See Also:
        Jdbi.onDemand(Class)
      • onDemand

        public java.util.Optional<java.lang.Object> onDemand​(Jdbi jdbi,
                                                             java.lang.Class<?> extensionType,
                                                             java.lang.Class<?>... extraTypes)
        Specified by:
        onDemand in interface OnDemandExtensions.Factory
      • getGeneratedClassName

        private java.lang.String getGeneratedClassName​(java.lang.Class<?> extensionType)
      • getOnDemandClassName

        private java.lang.String getOnDemandClassName​(java.lang.Class<?> extensionType)