Package org

Class UNCFileLocationCheck

java.lang.Object
org.UNCFileLocationCheck

public class UNCFileLocationCheck
extends Object
Author:
matthiak
  • Field Details

    • CONFIRM

      public static int CONFIRM
    • DECLINE

      public static int DECLINE
  • Constructor Details

    • UNCFileLocationCheck

      public UNCFileLocationCheck()
  • Method Details

    • isUNCFilePath

      public static boolean isUNCFilePath​(File file)
    • isUNCFilePath

      public static boolean isUNCFilePath​(String path)
    • showUNCPathConfirmDialogForPath

      public static int showUNCPathConfirmDialogForPath​(File file)
      Checks, if the given file is to be stored at a UNC network path. If not, it returns JOptionPane.OK_OPTION If yes, it opens a dialog and let the user decide, if the UNC location is ok.
      Parameters:
      file - The File to check
      Returns:
      UNCFileLocationCheck.CONFIRM if UNC location is accepted UNCFileLocationCheck.DECLINE if UNC location is declined
    • showUNCPathConfirmDialogForPath

      public static int showUNCPathConfirmDialogForPath​(String path)
      Checks, if the given path is a UNC network path. If not, it returns JOptionPane.OK_OPTION If yes, it opens a dialog and let the user decide, if the UNC location is ok.
      Parameters:
      path - The path to check
      Returns:
      UNCFileLocationCheck.CONFIRM if UNC location is accepted UNCFileLocationCheck.DECLINE if UNC location is declined