Class TestResult

  • All Implemented Interfaces:

    @Serializable() 
    public final class TestResult
    
                        

    Class for managing the results of an Adapter Instance 'connection' test

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private final JsonElement json
    • Constructor Summary

      Constructors 
      Constructor Description
      TestResult()
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final JsonElement getJson()
      final Boolean isSuccess()
      final TestResult withError(String errorMessage) Set the adapter instance connection test to failed, and display the given error message.
      final Unit sendResults(String outputPipe) Opens the output pipe and sends result directly back to the serverThis method can only be called once per collection.
      final Unit sendResults() Opens the output pipe and sends result directly back to the serverThis method can only be called once per collection.
      • Methods inherited from class java.lang.Object

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

      • TestResult

        TestResult()
    • Method Detail

      • getJson

         final JsonElement getJson()
      • isSuccess

         final Boolean isSuccess()
        Returns:

        true if the TestResult represents a successful test

      • withError

         final TestResult withError(String errorMessage)

        Set the adapter instance connection test to failed, and display the given error message.

        If this method is called multiple times, only the most recent error message will be recorded. If errorMessage is set, the test is considered failed.

        Parameters:
        errorMessage - The error message to present to the user.
      • sendResults

         final Unit sendResults(String outputPipe)

        Opens the output pipe and sends result directly back to the server

        This method can only be called once per collection.

        Parameters:
        outputPipe - The path to the output pipe.
      • sendResults

         final Unit sendResults()

        Opens the output pipe and sends result directly back to the server

        This method can only be called once per collection.