| Method from net.sourceforge.harness.xml.jaxb.Param Detail: |
public boolean equals(Object ob) {
if (this == ob) {
return true;
}
if (!(ob instanceof Param)) {
return false;
}
Param tob = ((Param) ob);
if (_Name != null) {
if (tob._Name == null) {
return false;
}
if (!_Name.equals(tob._Name)) {
return false;
}
} else {
if (tob._Name != null) {
return false;
}
}
if (_Value != null) {
if (tob._Value == null) {
return false;
}
if (!_Value.equals(tob._Value)) {
return false;
}
} else {
if (tob._Value != null) {
return false;
}
}
return true;
}
|
public String getName() {
return _Name;
}
|
public String getValue() {
return _Value;
}
|
public int hashCode() {
int h = 0;
h = ((127 * h) + ((_Name != null) ? _Name.hashCode() : 0));
h = ((127 * h) + ((_Value != null) ? _Value.hashCode() : 0));
return h;
}
|
public void marshal(Marshaller m) throws IOException {
XMLWriter w = m.writer();
w.start("param");
w.attribute("name", _Name.toString());
w.attribute("value", _Value.toString());
w.end("param");
}
|
public static Dispatcher newDispatcher() {
return Author.newDispatcher();
}
|
public void setName(String _Name) {
this._Name = _Name;
if (_Name == null) {
invalidate();
}
}
|
public void setValue(String _Value) {
this._Value = _Value;
if (_Value == null) {
invalidate();
}
}
|
public String toString() {
StringBuffer sb = new StringBuffer("< < param");
if (_Name != null) {
sb.append(" name=");
sb.append(_Name.toString());
}
if (_Value != null) {
sb.append(" value=");
sb.append(_Value.toString());
}
sb.append(" > >");
return sb.toString();
}
|
public void unmarshal(Unmarshaller u) throws UnmarshalException {
XMLScanner xs = u.scanner();
Validator v = u.validator();
xs.takeStart("param");
while (xs.atAttribute()) {
String an = xs.takeAttributeName();
if (an.equals("name")) {
if (_Name != null) {
throw new DuplicateAttributeException(an);
}
_Name = xs.takeAttributeValue();
continue;
}
if (an.equals("value")) {
if (_Value != null) {
throw new DuplicateAttributeException(an);
}
_Value = xs.takeAttributeValue();
continue;
}
throw new InvalidAttributeException(an);
}
xs.takeEnd("param");
}
|
public static Param unmarshal(InputStream in) throws UnmarshalException {
return unmarshal(XMLScanner.open(in));
}
|
public static Param unmarshal(XMLScanner xs) throws UnmarshalException {
return unmarshal(xs, newDispatcher());
}
|
public static Param unmarshal(XMLScanner xs,
Dispatcher d) throws UnmarshalException {
return ((Param) d.unmarshal(xs, (Param.class)));
}
|
public void validate(Validator v) throws StructureValidationException {
}
|
public void validateThis() throws LocalValidationException {
if (_Name == null) {
throw new MissingAttributeException("name");
}
if (_Value == null) {
throw new MissingAttributeException("value");
}
}
|