/*
* Copyright 2001-2006 C:1 Financial Services GmbH
*
* This software is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License Version 2.1, as published by the Free Software Foundation.
*
* This software is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA
*/
package de.finix.contelligent.render;
import java.io.Serializable;
final public class ParameterDescription implements Serializable {
public static final boolean REQUIRED = true;
public static final boolean OPTIONAL = false;
public static final boolean CONSTRAINED = true;
public static final boolean UNCONSTRAINED = false;
final private String name;
final private String description;
final private boolean required;
final private boolean constrained;
final private String[] allowedValues;
public ParameterDescription(String name) {
this(name, "");
}
public ParameterDescription(String name, String description) {
this(name, description, false);
}
public ParameterDescription(String name, String description, boolean required) {
this(name, description, required, false, null);
}
public ParameterDescription(String name, String description, boolean required, boolean constrained,
String[] allowedValues) {
this.name = name;
this.description = description;
this.required = required;
this.constrained = constrained;
this.allowedValues = allowedValues;
}
public String getName() {
return name;
}
public String getDescription() {
return description;
}
public boolean isRequired() {
return required;
}
public boolean isConstrained() {
return constrained;
}
public String[] getAllowedValues() {
return allowedValues;
}
}
|