Class FileUploder

  • All Implemented Interfaces:
    com.vaadin.ui.Upload.FinishedListener, com.vaadin.ui.Upload.ProgressListener, com.vaadin.ui.Upload.Receiver, com.vaadin.ui.Upload.StartedListener, com.vaadin.ui.Upload.SucceededListener, java.io.Serializable

    public class FileUploder
    extends pl.edu.icm.unity.webui.common.AbstractUploadReceiver
    Allows for uploading file. Show error popup if problem occurs.
    Author:
    P.Piernik
    See Also:
    Serialized Form
    • Field Summary

      • Fields inherited from class pl.edu.icm.unity.webui.common.AbstractUploadReceiver

        upload
    • Constructor Summary

      Constructors 
      Constructor Description
      FileUploder​(com.vaadin.ui.Upload upload, com.vaadin.ui.ProgressBar progress, com.vaadin.ui.Label info, pl.edu.icm.unity.MessageSource msg, java.io.File tempDir)  
      FileUploder​(com.vaadin.ui.Upload upload, com.vaadin.ui.ProgressBar progress, com.vaadin.ui.Label info, pl.edu.icm.unity.MessageSource msg, java.io.File tempDir, java.lang.Runnable callback)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()  
      java.io.File getFile()  
      boolean isOverflow()  
      boolean isUploading()  
      java.io.OutputStream receiveUpload​(java.lang.String filename, java.lang.String mimeType)  
      void unblock()  
      void uploadSucceeded​(com.vaadin.ui.Upload.SucceededEvent event)  
      • Methods inherited from class pl.edu.icm.unity.webui.common.AbstractUploadReceiver

        register, updateProgress, uploadFinished, uploadStarted
      • Methods inherited from class java.lang.Object

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

      • FileUploder

        public FileUploder​(com.vaadin.ui.Upload upload,
                           com.vaadin.ui.ProgressBar progress,
                           com.vaadin.ui.Label info,
                           pl.edu.icm.unity.MessageSource msg,
                           java.io.File tempDir,
                           java.lang.Runnable callback)
      • FileUploder

        public FileUploder​(com.vaadin.ui.Upload upload,
                           com.vaadin.ui.ProgressBar progress,
                           com.vaadin.ui.Label info,
                           pl.edu.icm.unity.MessageSource msg,
                           java.io.File tempDir)
    • Method Detail

      • uploadSucceeded

        public void uploadSucceeded​(com.vaadin.ui.Upload.SucceededEvent event)
        Specified by:
        uploadSucceeded in interface com.vaadin.ui.Upload.SucceededListener
        Overrides:
        uploadSucceeded in class pl.edu.icm.unity.webui.common.AbstractUploadReceiver
      • receiveUpload

        public java.io.OutputStream receiveUpload​(java.lang.String filename,
                                                  java.lang.String mimeType)
      • isUploading

        public boolean isUploading()
      • getFile

        public java.io.File getFile()
      • unblock

        public void unblock()
      • isOverflow

        public boolean isOverflow()
      • clear

        public void clear()