Interface PlatformFile

All Superinterfaces:
ProgressListenable<Long>
All Known Implementing Classes:
AbstractPlatformFile, WebPlatformFile

public interface PlatformFile extends ProgressListenable<Long>
A local file on a platform.
Author:
Garret Wilson
  • Method Details

    • getName

      String getName()
      Returns:
      The name of the file.
    • getSize

      long getSize()
      Returns:
      The size of the file, or -1 if the size is unknown.
    • cancel

      void cancel()
      Cancels the current upload or download.
    • upload

      void upload(URI destinationURI)
      Uploads the file from the platform.
      Parameters:
      destinationURI - The URI representing the destination of the platform file, either absolute or relative to the application.
      Throws:
      NullPointerException - if the given destination URI is null.
      IllegalStateException - the platform file can no longer be uploaded because, for example, other platform files have since been selected.