package org.jboss.services.deployment.metadata;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
public class ConfigInfo
implements Serializable
{
private static final long serialVersionUID = 3455531161586923775L;
private String name;
private String copydir;
private String template;
private String extension;
private String description;
private List propertyList = new ArrayList();
private List templateList = new ArrayList();
public ConfigInfo()
{
}
public ConfigInfo(String name, String copydir,
String template, String extension, String description)
{
this.name = name;
this.copydir = copydir;
this.template = template;
this.extension = extension;
this.description = description;
}
public String getExtension()
{
return extension;
}
public void setExtension(String extension)
{
this.extension = extension;
}
public String getName()
{
return name;
}
public void setName(String name)
{
this.name = name;
}
public String getTemplate()
{
return template;
}
public void setTemplate(String template)
{
this.template = template;
}
public String getDescription()
{
return description;
}
public void setDescription(String description)
{
this.description = description;
}
public String getCopydir()
{
return copydir;
}
public void setCopydir(String copydir)
{
this.copydir = copydir;
}
public List getPropertyInfoList()
{
return propertyList;
}
public void setPropertyInfoList(List propertyList)
{
this.propertyList = propertyList;
}
public void addPropertyInfo(PropertyInfo propertyInfo)
{
this.propertyList.add(propertyInfo);
}
public List getTemplateInfoList()
{
return templateList;
}
public void setTemplateInfoList(List templateList)
{
this.templateList = templateList;
}
public void addTemplateInfo(TemplateInfo templateInfo)
{
this.templateList.add(templateInfo);
}
public String toString()
{
StringBuffer sb = new StringBuffer(1024);
sb.append('[')
.append("name=").append(name)
.append(", copydir=").append(copydir)
.append(", template=").append(template)
.append(", extension=").append(extension)
.append(", description=").append(description)
.append(", propertyList=").append(propertyList)
.append(", templateList=").append(templateList)
.append(']');
return sb.toString();
}
public boolean equals(Object other)
{
if(this == other) return true;
if(!(other instanceof ConfigInfo)) return false;
if (name != null && name.equals(((ConfigInfo)other).name))
return true;
else
return false;
}
public int hashCode()
{
if (name != null)
return name.hashCode();
else
return 0;
}
}