Package org.antlr.gunit.swingui.model

## Class TestSuiteFactory

- java.lang.Object
- - org.antlr.gunit.swingui.model.TestSuiteFactory

    public class TestSuiteFactory
    extends java.lang.Object

### Field Summary

Fields
`static java.lang.String` `GRAMMAR_EXT`
`static java.lang.String` `TEST_SUITE_EXT`

### Constructor Summary

Constructors
`TestSuiteFactory​()`

### Method Summary

All Methods Static Methods Concrete Methods
`static TestSuite` `createTestSuite​(java.io.File grammarFile)` Factory method: create a testsuite from ANTLR grammar.
`static java.lang.String` `getScript​(TestSuite testSuite)` Get the text script from the testSuite.
`static TestSuite` `loadTestSuite​(java.io.File file)` From textual script to program model.
`static boolean` `saveTestSuite​(TestSuite testSuite)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### TEST_SUITE_EXT

    public static final java.lang.String TEST_SUITE_EXT

See Also:
  Constant Field Values

#### GRAMMAR_EXT

    public static final java.lang.String GRAMMAR_EXT

See Also:
  Constant Field Values

### Constructor Detail

#### TestSuiteFactory

    public TestSuiteFactory​()

### Method Detail

#### createTestSuite

    public static TestSuite createTestSuite​(java.io.File grammarFile)

Factory method: create a testsuite from ANTLR grammar. Save the test suite file in the same directory of the grammar file.

Parameters:
  `grammarFile` - ANTLRv3 grammar file.
Returns:
  test suite object

#### saveTestSuite

    public static boolean saveTestSuite​(TestSuite testSuite)

#### getScript

    public static java.lang.String getScript​(TestSuite testSuite)

Get the text script from the testSuite.

Parameters:
  `testSuite` -
Returns:
  test script

#### loadTestSuite

    public static TestSuite loadTestSuite​(java.io.File file)

From textual script to program model.

Parameters:
  `file` - testsuite file (.gunit)
Returns:
  test suite object