java.lang.Object
org.klomp.snark.web.I2PSnarkServlet.BaseFileValidationResult
Enclosing class:
I2PSnarkServlet

static class I2PSnarkServlet.BaseFileValidationResultextends Object
Result of validating a base file for torrent creation. Package-visible for testing.
  • Field Details

    • baseFile

      final File baseFile
      The resolved absolute base file; null when validation failed.
    • errorMessage

      final String errorMessage
      Human-readable failure reason; null if valid.
  • Constructor Details

    • BaseFileValidationResult

      BaseFileValidationResult(File baseFile, String errorMessage)
      Records the resolved base file, or why it was rejected.
      Parameters:
      baseFile - the resolved absolute base file, null when validation failed
      errorMessage - human-readable failure reason, null if valid
  • Method Details

    • isValid

      boolean isValid()
      Tells whether the base file passed validation.
      Returns:
      true if no error message was recorded