// Path: src/main/java/generator/extenders/RandomiserInstance.java
// public class RandomiserInstance
// {
//     //the name of the randomiser type to load
//     private String randomiserType; 
//     
//     //name and description are standard fields for all the user-defined cases.
//     private String name;       
//     private String description;
//     
//     //any object can be stored in the properties hashmap, however, it will be
//     //its String representation that will be saved in the XML file.
//     private LinkedHashMap properties;
//     
//     
//     public RandomiserInstance()
//     {        
//     }
//     
// 
//     public RandomiserInstance( String randomiserType,
//                                String name,
//                                String description,
//                                LinkedHashMap properties)
//     {
//         this.randomiserType = randomiserType;
//         this.name = name;
//         this.description = description;
//         this.properties = properties;
//     }
//     
//     
//     public String getRandomiserType()
//     {
//         return randomiserType;
//     }
// 
//     public void setRandomiserType(String randomiserType)
//     {
//         this.randomiserType = randomiserType;
//     }
// 
//     public String getName()
//     {
//         return name;
//     }
// 
//     public void setName(String name)
//     {
//         this.name = name;
//     }
// 
//     public String getDescription()
//     {
//         return description;
//     }
// 
//     public void setDescription(String description)
//     {
//         this.description = description;
//     }
// 
//     public LinkedHashMap getProperties()
//     {
//         return properties;
//     }
// 
//     public void setProperties(LinkedHashMap properties)
//     {
//         this.properties = properties;
//     }
// 
//     public String toString()
//     {
//         return name;        
//     }
// }


import java.util.LinkedHashMap;
import java.util.Vector;
import org.apache.log4j.Logger;
import generator.extenders.RandomiserInstance;
import org.xml.sax.Attributes;
import org.xml.sax.SAXException;

/*
 * dgMaster: A versatile, open source data generator.
 *(c) 2007 M. Michalakopoulos, mmichalak@gmail.com
 */


package generator.misc;


/**
 *
 * Handles the input of an XML file which represents the definitions
 * for a user defined random instnace (RandomiserInstance).
 * Data are loaded in the initial loading of the application.
 */
public class RandomInstanceSAXHandler extends SAXDataHandler
{
    private Logger logger = Logger.getLogger(RandomInstanceSAXHandler.class);

// Path: src/main/java/generator/extenders/RandomiserInstance.java
// public class RandomiserInstance
// {
//     //the name of the randomiser type to load
//     private String randomiserType; 
//     
//     //name and description are standard fields for all the user-defined cases.
//     private String name;       
//     private String description;
//     
//     //any object can be stored in the properties hashmap, however, it will be
//     //its String representation that will be saved in the XML file.
//     private LinkedHashMap properties;
//     
//     
//     public RandomiserInstance()
//     {        
//     }
//     
// 
//     public RandomiserInstance( String randomiserType,
//                                String name,
//                                String description,
//                                LinkedHashMap properties)
//     {
//         this.randomiserType = randomiserType;
//         this.name = name;
//         this.description = description;
//         this.properties = properties;
//     }
//     
//     
//     public String getRandomiserType()
//     {
//         return randomiserType;
//     }
// 
//     public void setRandomiserType(String randomiserType)
//     {
//         this.randomiserType = randomiserType;
//     }
// 
//     public String getName()
//     {
//         return name;
//     }
// 
//     public void setName(String name)
//     {
//         this.name = name;
//     }
// 
//     public String getDescription()
//     {
//         return description;
//     }
// 
//     public void setDescription(String description)
//     {
//         this.description = description;
//     }
// 
//     public LinkedHashMap getProperties()
//     {
//         return properties;
//     }
// 
//     public void setProperties(LinkedHashMap properties)
//     {
//         this.properties = properties;
//     }
// 
//     public String toString()
//     {
//         return name;        
//     }
// }


// Path: src/main/java/generator/misc/RandomInstanceSAXHandler.java
import java.util.LinkedHashMap;
import java.util.Vector;
import org.apache.log4j.Logger;
import generator.extenders.RandomiserInstance;
import org.xml.sax.Attributes;
import org.xml.sax.SAXException;

/*
 * dgMaster: A versatile, open source data generator.
 *(c) 2007 M. Michalakopoulos, mmichalak@gmail.com
 */


package generator.misc;


/**
 *
 * Handles the input of an XML file which represents the definitions
 * for a user defined random instnace (RandomiserInstance).
 * Data are loaded in the initial loading of the application.
 */
public class RandomInstanceSAXHandler extends SAXDataHandler
{
    private Logger logger = Logger.getLogger(RandomInstanceSAXHandler.class);

    private Vector<RandomiserInstance> vRandomInstances;
