/*
* Copyright 2011 JBoss Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.jbpm.formbuilder.shared.task;
public class ExternalDataRef {
private String source;
private String method;
private String responseLanguage;
private String xpath;
public ExternalDataRef() {
super();
}
public String getSource() {
return source;
}
public void setSource(String source) {
this.source = source;
}
public String getMethod() {
return method;
}
public void setMethod(String method) {
this.method = method;
}
public String getResponseLanguage() {
return responseLanguage;
}
public void setResponseLanguage(String responseLanguage) {
this.responseLanguage = responseLanguage;
}
public String getXpath() {
return xpath;
}
public void setXpath(String xpath) {
this.xpath = xpath;
}
@Override
public int hashCode() {
final int prime = 31;
int result = 1;
result = prime * result + ((method == null) ? 0 : method.hashCode());
result = prime
* result
+ ((responseLanguage == null) ? 0 : responseLanguage.hashCode());
result = prime * result + ((source == null) ? 0 : source.hashCode());
result = prime * result + ((xpath == null) ? 0 : xpath.hashCode());
return result;
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
ExternalDataRef other = (ExternalDataRef) obj;
if (method == null) {
if (other.method != null)
return false;
} else if (!method.equals(other.method))
return false;
if (responseLanguage == null) {
if (other.responseLanguage != null)
return false;
} else if (!responseLanguage.equals(other.responseLanguage))
return false;
if (source == null) {
if (other.source != null)
return false;
} else if (!source.equals(other.source))
return false;
if (xpath == null) {
if (other.xpath != null)
return false;
} else if (!xpath.equals(other.xpath))
return false;
return true;
}
}