kawigi.problem
Class ClassDeclFactory

java.lang.Object
  extended by kawigi.problem.ClassDeclFactory

public class ClassDeclFactory
extends java.lang.Object

This class takes some set of parameters and generates a ClassDecl from it.


Constructor Summary
ClassDeclFactory()
           
 
Method Summary
static ClassDecl getClassDecl(java.lang.Object... params)
          Generates a ClassDecl given some parameters.
static ClassDeclGenerator getGenerator()
          Determines the type of ClassDeclGenerator that should be used according to the current application mode.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClassDeclFactory

public ClassDeclFactory()
Method Detail

getGenerator

public static ClassDeclGenerator getGenerator()
Determines the type of ClassDeclGenerator that should be used according to the current application mode. If we are in standalone mode, this returns the problem parser. If we are in plugin mode, this returns an object that converts TopCoder's ProblemComponent into a ClassDecl.


getClassDecl

public static ClassDecl getClassDecl(java.lang.Object... params)
Generates a ClassDecl given some parameters. This calls getClassDecl on the ClassDeclGenerator returned by getGenerator. If the application is in standalone mode, the parameters will be ignored. If we are in plugin mode, the first parameter needs to be a TopCoder ProblemComponent and the second parameter needs to be a TopCoder Language. If either is not the right type or there are fewer than two parameters, things will crash and be generally unhappy.