Class JWebAssemblyEmulator


  • public class JWebAssemblyEmulator
    extends java.lang.Object
    The main class start point for the emulator.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      (package private) static void hide()
      Hide the emulator window
      private static void launch​(java.lang.String htmlPageURL, java.lang.String content, java.lang.Runnable main)
      Start the emulator.
      static void launchContent​(java.lang.String content, java.lang.Runnable main)
      Start the emulator from a URL, load the html page and call the given main method.
      static void launchResource​(java.lang.String htmlPage, java.lang.Runnable main)
      Start the emulator from a resource file, load the html page and call the given main method.
      static void launchURL​(java.net.URL htmlPageURL, java.lang.Runnable main)
      Start the emulator from a URL, load the html page and call the given main method.
      (package private) static <E extends java.lang.Throwable>
      void
      throwAny​(java.lang.Throwable e)
      Throws any (checked) exception without in signature
      • Methods inherited from class java.lang.Object

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

      • JWebAssemblyEmulator

        public JWebAssemblyEmulator()
    • Method Detail

      • launchResource

        public static void launchResource​(@Nonnull
                                          java.lang.String htmlPage,
                                          @Nonnull
                                          java.lang.Runnable main)
        Start the emulator from a resource file, load the html page and call the given main method.
        Parameters:
        htmlPage - The resource of the html page that the WebAssembly contains.
        main - the executable with the main function
      • launchURL

        public static void launchURL​(@Nonnull
                                     java.net.URL htmlPageURL,
                                     @Nonnull
                                     java.lang.Runnable main)
        Start the emulator from a URL, load the html page and call the given main method.
        Parameters:
        htmlPageURL - The URL of the html page that the WebAssembly contains.
        main - the executable with the main function
      • launchContent

        public static void launchContent​(@Nonnull
                                         java.lang.String content,
                                         @Nonnull
                                         java.lang.Runnable main)
        Start the emulator from a URL, load the html page and call the given main method.
        Parameters:
        content - The content of the html page that the WebAssembly contains.
        main - the executable with the main function
      • launch

        private static void launch​(java.lang.String htmlPageURL,
                                   java.lang.String content,
                                   @Nonnull
                                   java.lang.Runnable main)
        Start the emulator.
        Parameters:
        htmlPageURL - The URL of the html page that the WebAssembly contains.
        content - The content of the html page that the WebAssembly contains.
        main - the executable with the main function
      • hide

        static void hide()
        Hide the emulator window
      • throwAny

        static <E extends java.lang.Throwable> void throwAny​(java.lang.Throwable e)
                                                      throws E extends java.lang.Throwable
        Throws any (checked) exception without in signature
        Type Parameters:
        E - any Throwable
        Parameters:
        e - the exception
        Throws:
        E - any Throwable
        E extends java.lang.Throwable