package com.jware.apps.scheduler.web.struts.definition;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionMapping;

import com.jware.base.web.struts.jWareBaseForm;


public final class JobDefinitionEditForm extends jWareBaseForm implements Serializable {

	private String name;
	private String description;
	private String className;
	private String parameterName;
	private String parameterDescription;
	private boolean required;
	
	private List parameters = new ArrayList(); 

	/**
	 * 
	 */
	public JobDefinitionEditForm() {
		super();
		// TODO Auto-generated constructor stub
	}

	/**
	 * @return
	 */
	public String getClassName() {
		return className;
	}

	/**
	 * @return
	 */
	public String getDescription() {
		return description;
	}

	/**
	 * @return
	 */
	public String getName() {
		return name;
	}

	/**
	 * @return
	 */
	public List getParameters() {
		return parameters;
	}

	/**
	 * @param string
	 */
	public void setClassName(String string) {
		className = string;
	}

	/**
	 * @param string
	 */
	public void setDescription(String string) {
		description = string;
	}

	/**
	 * @param string
	 */
	public void setName(String string) {
		name = string;
	}

	/**
	 * @param list
	 */
	public void setParameters(List list) {
		parameters = list;
	}

	/**
	 * Reset all properties to their default values.
	 *
	 * @param mapping The mapping used to select this instance
	 * @param request The servlet request we are processing
	 */
	public void reset(ActionMapping mapping, HttpServletRequest request) {
		/**
    	 * This will set LoginUserId From Session  
    	 */
    	super.reset(mapping, request);		
    	
    	/**
    	 * Reset all properties to their default values.
    	 */
		this.name = null;
		this.description = null;
		this.className = null;
		this.parameters = null;
		this.parameterName = null;
		this.parameterDescription = null;
		this.required = false;
		
	}

	/**
	 * @return Returns the parameterDescription.
	 */
	public String getParameterDescription() {
		return parameterDescription;
	}
	/**
	 * @param parameterDescription The parameterDescription to set.
	 */
	public void setParameterDescription(String parameterDescription) {
		this.parameterDescription = parameterDescription;
	}
	/**
	 * @return Returns the parameterName.
	 */
	public String getParameterName() {
		return parameterName;
	}
	/**
	 * @param parameterName The parameterName to set.
	 */
	public void setParameterName(String parameterName) {
		this.parameterName = parameterName;
	}
	/**
	 * @return Returns the required.
	 */
	public boolean isRequired() {
		return required;
	}
	/**
	 * @param required The required to set.
	 */
	public void setRequired(boolean required) {
		this.required = required;
	}
}
