Class VFSServlet.JdbcFileDAO

  • All Implemented Interfaces:
    VFSServlet.FileDAO
    Enclosing class:
    VFSServlet

    public static class VFSServlet.JdbcFileDAO
    extends java.lang.Object
    implements VFSServlet.FileDAO
    unfortunately we cant work with DatabaseFileSystem / DatabaseFileObject directly to store data, so we do here lowlevel BLOB handling, works with bcd_virtualFileSystem binding-set NOT THREADSAFE
    • Constructor Summary

      Constructors 
      Constructor Description
      JdbcFileDAO​(javax.sql.DataSource ds)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void commit()
      for implementations with transaction handling
      void delete​(java.util.Collection<java.lang.String> uris)
      deletes uris
      protected java.sql.Connection getConnection()
      connection used, must not be closed, must not change autocommit flag
      java.util.Collection<java.lang.String> getWrittenFiles()
      this method must not be called prior to VFSServlet.FileDAO.commit()
      void write​(java.lang.String uri, java.io.InputStream inputStream)
      writes file
      • Methods inherited from class java.lang.Object

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

      • JdbcFileDAO

        public JdbcFileDAO​(javax.sql.DataSource ds)
    • Method Detail

      • getConnection

        protected java.sql.Connection getConnection()
        connection used, must not be closed, must not change autocommit flag
        Returns:
      • write

        public void write​(java.lang.String uri,
                          java.io.InputStream inputStream)
        Description copied from interface: VFSServlet.FileDAO
        writes file
        Specified by:
        write in interface VFSServlet.FileDAO