Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Lightweight Bartering Grid
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## lbg.simulator.tools.generator
Class ScenarioSetGenerator

    java.lang.Object
      lbg.simulator.tools.generator.ScenarioSetGenerator

Direct Known Subclasses:
  PolicyEnumerator, ScenarioRandomizer

    public abstract class ScenarioSetGenerator

extends java.lang.Object

Author:
  Cyril Briquet

Constructor Summary
`protected` | `ScenarioSetGenerator(java.lang.String[] args)`

Method Summary
`abstract void` | `checkArgs(java.lang.String[] args)`
`protected void` | `generateBucketJDF(int b, java.util.ArrayList<java.util.Set<java.lang.String>> sc_buckets)`
`void` | `generateJDF()`
`protected static java.util.ArrayList<java.util.Set<java.lang.String>>` | `generateScenariiBuckets(java.util.Iterator<java.lang.String> it_sc_all, int generated_sc_count, int bucket_count)`
`protected void` | `generateScenario(int idx, ScenarioPayload sc_payload)`
`protected java.lang.String` | `generateScenarioFileName(int idx)`
`abstract void` | `generateScenarios()` Enumerates scenarios.
`abstract Scenario` | `getBaseScenario()`
`abstract int` | `getBucketCount()`
`abstract int` | `getExpectedScenariiCount()`
`abstract int` | `getGeneratedScenariiCount()`
`abstract java.util.Set<java.lang.String>` | `getGeneratedScenariiFileNames()`
`abstract java.lang.String` | `getJarCompleteFileName()`
`abstract JDFWriterFactory` | `getJDFWriterFactory()`
`abstract java.lang.String` | `getMainClass()`
`abstract java.lang.String` | `getScenarioBaseName()`
`abstract java.lang.String` | `getScenarioCompleteFileName()`
`abstract java.lang.String` | `getScenarioFileName()`
`static void` | `run(ScenarioSetGenerator sse)`
`protected static void` | `storeScenario(Scenario sc, java.lang.String scenario_filename)`
`protected abstract void` | `updateScenario(Scenario sc, ScenarioPayload sc_payload)` Updates target scenario with target payload.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ScenarioSetGenerator

    protected ScenarioSetGenerator(java.lang.String[] args)
                            throws GridException

Throws:
  `GridException`

Method Detail

### getExpectedScenariiCount

    public abstract int getExpectedScenariiCount()

### getGeneratedScenariiCount

    public abstract int getGeneratedScenariiCount()

### getJDFWriterFactory

    public abstract JDFWriterFactory getJDFWriterFactory()

### getBaseScenario

    public abstract Scenario getBaseScenario()

### getScenarioCompleteFileName

    public abstract java.lang.String getScenarioCompleteFileName()

### getScenarioFileName

    public abstract java.lang.String getScenarioFileName()

### getScenarioBaseName

    public abstract java.lang.String getScenarioBaseName()

### getJarCompleteFileName

    public abstract java.lang.String getJarCompleteFileName()

### getBucketCount

    public abstract int getBucketCount()

### getMainClass

    public abstract java.lang.String getMainClass()

### getGeneratedScenariiFileNames

    public abstract java.util.Set<java.lang.String> getGeneratedScenariiFileNames()

### checkArgs

    public abstract void checkArgs(java.lang.String[] args)
                            throws GridException

  Throws:
    `GridException`

### generateScenarios

    public abstract void generateScenarios()
                                    throws GridException

  Enumerates scenarios. For each scenario, calls generateScenario() and passes the scenario index and payload.

  Throws:
    `GridException`

### generateJDF

    public void generateJDF()
                     throws GridException

  Throws:
    `GridException`

### generateScenario

    protected void generateScenario(int idx,
                                    ScenarioPayload sc_payload)
                             throws GridException

  Throws:
    `GridException`

### updateScenario

    protected abstract void updateScenario(Scenario sc,
                                           ScenarioPayload sc_payload)
                                    throws GridException

  Updates target scenario with target payload. For maximum efficiency, should not be synchronized.

  Throws:
    `GridException`

### generateScenarioFileName

    protected java.lang.String generateScenarioFileName(int idx)
                                                 throws GridException

  Parameters:
    `idx` - Scenario index, in [0..expected scenarii-1]
  Throws:
    `GridException`

### generateBucketJDF

    protected void generateBucketJDF(int b,
                                     java.util.ArrayList<java.util.Set<java.lang.String>> sc_buckets)
                              throws GridException

  Throws:
    `GridException`

### run

    public static void run(ScenarioSetGenerator sse)
                    throws GridException

  Throws:
    `GridException`

### storeScenario

    protected static void storeScenario(Scenario sc,
                                        java.lang.String scenario_filename)
                                 throws GridException

  Throws:
    `GridException`

### generateScenariiBuckets

    protected static java.util.ArrayList<java.util.Set<java.lang.String>> generateScenariiBuckets(java.util.Iterator<java.lang.String> it_sc_all,
                                                                                                  int generated_sc_count,
                                                                                                  int bucket_count)
                                                                                           throws GridException

  Throws:
    `GridException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Lightweight Bartering Grid
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

> Copyright (c) 2005-2008, Cyril Briquet, parts Xavier Dalem.