Package: grails.ui.console

## [Groovy] Class GrailsSwingConsole

- grails.ui.console.GrailsSwingConsole

-     @groovy.transform.CompileStatic
      class GrailsSwingConsole
      extends GrailsApp

  The Grails console runs Grails embedded within a Swing console instead of within a container like Tomcat

  Authors:
    Graeme Rocher
  Since:
    3.0

- - Inherited fields
    Fields inherited from class | Fields
    --- | ---
    `class GrailsApp` | `GRAILS_BANNER, SPRING_PROFILES, configuredEnvironment, developmentModeActive, directoryWatcher, enableBeanCreationProfiler`

  - ### Constructor Summary

    Constructors
    Constructor and description
    `GrailsSwingConsole (java.lang.Class<?>[] sources)`
    `GrailsSwingConsole (org.springframework.core.io.ResourceLoader resourceLoader, java.lang.Class<?>[] sources)`

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `static void` | `()`
    `` | `void` | `configureApplicationContextClass()`
    `` | `static void` | `main(java.lang.String[] args)` Main method to run an existing Application class
    `` | `static org.springframework.context.ConfigurableApplicationContext` | `run(java.lang.Class<?> source, java.lang.String[] args)` Static helper that can be used to run a GrailsApp from the specified source using default settings.
    `` | `static org.springframework.context.ConfigurableApplicationContext` | `run(java.lang.Class<?>[] sources, java.lang.String[] args)` Static helper that can be used to run a GrailsApp from the specified sources using default settings and user supplied arguments.

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class GrailsApp` | `compileGroovyFile, configureDirectoryWatcher, configureEnvironment, createApplicationContext, createPluginManagerListener, enableDevelopmentModeWatch, isDevelopmentModeActive, loadPluginConfigurationsToMicronautContext, newMicronautContextBuilder, printRunStatus, recompile, run, run, run, setDevelopmentModeActive`

- - ### Constructor Detail

    - #### GrailsSwingConsole(java.lang.Class<?>[] sources)

    - #### GrailsSwingConsole(org.springframework.core.io.ResourceLoader resourceLoader, java.lang.Class<?>[] sources)

  - ### Method Detail

    - #### static void ()

    - #### void configureApplicationContextClass()

    - #### static void main(java.lang.String[] args)

      Main method to run an existing Application class

      Parameters:
        `args` - The first argument is the Application class name

    - #### static org.springframework.context.ConfigurableApplicationContext run(java.lang.Class<?> source, java.lang.String[] args)

      Static helper that can be used to run a GrailsApp from the specified source using default settings.

      Parameters:
        `source` - the source to load
        `args` - the application arguments (usually passed from a Java main method)
      Returns:
        the running org.springframework.context.ApplicationContext

    - #### static org.springframework.context.ConfigurableApplicationContext run(java.lang.Class<?>[] sources, java.lang.String[] args)

      Static helper that can be used to run a GrailsApp from the specified sources using default settings and user supplied arguments.

      Parameters:
        `sources` - the sources to load
        `args` - the application arguments (usually passed from a Java main method)
      Returns:
        the running org.springframework.context.ApplicationContext