refactor the plugin xml name
This commit is contained in:
parent
d035288cfa
commit
f03bd61207
|
@ -2,11 +2,10 @@ package org.bench4q.share.models.master.plugin;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlElementWrapper;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class BehaviorInfoModel {
|
||||
|
||||
|
@ -16,13 +15,12 @@ public class BehaviorInfoModel {
|
|||
private String name;
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name = "paramInfoModel", type = ParamInfoModel.class)
|
||||
public List<ParamInfoModel> getParamInfoModels() {
|
||||
return paramInfoModels;
|
||||
}
|
||||
|
||||
public void setParamInfoModels(
|
||||
List<ParamInfoModel> paramInfoModels) {
|
||||
public void setParamInfoModels(List<ParamInfoModel> paramInfoModels) {
|
||||
this.paramInfoModels = paramInfoModels;
|
||||
}
|
||||
|
||||
|
|
|
@ -2,17 +2,17 @@ package org.bench4q.share.models.master.plugin;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlElementWrapper;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class CheckBoxModel extends ParamTypeModel {
|
||||
|
||||
private List<ChoiceModel> choiceModels;
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name = "choiceModel", type = ChoiceModel.class)
|
||||
public List<ChoiceModel> getChoiceModels() {
|
||||
return choiceModels;
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
package org.bench4q.share.models.master.plugin;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class ChoiceModel {
|
||||
|
|
|
@ -2,17 +2,16 @@ package org.bench4q.share.models.master.plugin;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlElementWrapper;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class ComboModel extends ParamTypeModel {
|
||||
private List<ChoiceModel> choiceModels;
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name="choiceModel",type=ChoiceModel.class)
|
||||
public List<ChoiceModel> getChoiceModels() {
|
||||
return choiceModels;
|
||||
}
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
package org.bench4q.share.models.master.plugin;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class FieldModel extends ParamTypeModel {
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
package org.bench4q.share.models.master.plugin;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class NFieldModel extends ParamTypeModel {
|
||||
|
|
|
@ -4,24 +4,14 @@ import javax.xml.bind.annotation.XmlElement;
|
|||
import javax.xml.bind.annotation.XmlElements;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
|
||||
@XmlRootElement
|
||||
public class ParamInfoModel {
|
||||
|
||||
private String name;
|
||||
private String lable;
|
||||
private String type;
|
||||
// private ParamTypeClassAndContnet paramTypeClassAndContnet;
|
||||
|
||||
private ParamTypeModel paramTypeModel;
|
||||
|
||||
// public ParamTypeModel createParamTypeModel() throws JAXBException {
|
||||
// ParamTypeModel paramTypeModel = (ParamTypeModel) MarshalHelper
|
||||
// .unmarshal(paramTypeClassAndContnet.getParamTypeClass(),
|
||||
// paramTypeClassAndContnet.getContent());
|
||||
// return paramTypeModel;
|
||||
// }
|
||||
|
||||
@XmlElement
|
||||
public String getName() {
|
||||
return name;
|
||||
|
@ -40,16 +30,6 @@ public class ParamInfoModel {
|
|||
this.lable = lable;
|
||||
}
|
||||
|
||||
// @XmlElement
|
||||
// public ParamTypeClassAndContnet getParamTypeClassAndContnet() {
|
||||
// return paramTypeClassAndContnet;
|
||||
// }
|
||||
//
|
||||
// public void setParamTypeClassAndContnet(
|
||||
// ParamTypeClassAndContnet paramTypeClassAndContnet) {
|
||||
// this.paramTypeClassAndContnet = paramTypeClassAndContnet;
|
||||
// }
|
||||
|
||||
@XmlElement
|
||||
public String getType() {
|
||||
return type;
|
||||
|
@ -62,7 +42,9 @@ public class ParamInfoModel {
|
|||
@XmlElements({ @XmlElement(name = "field", type = FieldModel.class),
|
||||
@XmlElement(name = "table", type = TableModel.class),
|
||||
@XmlElement(name = "checkbox", type = CheckBoxModel.class),
|
||||
@XmlElement(name = "nfield", type = NFieldModel.class) })
|
||||
@XmlElement(name = "nfield", type = NFieldModel.class),
|
||||
@XmlElement(name = "combo", type = ComboModel.class),
|
||||
@XmlElement(name = "radio", type = RadioButtonModel.class) })
|
||||
public ParamTypeModel getParamTypeModel() {
|
||||
return paramTypeModel;
|
||||
}
|
||||
|
|
|
@ -1,40 +0,0 @@
|
|||
package org.bench4q.share.models.master.plugin;
|
||||
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class ParamTypeClassAndContnet {
|
||||
|
||||
private Class<?> paramTypeClass;
|
||||
private String content;
|
||||
|
||||
public ParamTypeClassAndContnet() {
|
||||
|
||||
}
|
||||
|
||||
public ParamTypeClassAndContnet(Class<?> paramTyClass, String content) {
|
||||
this.paramTypeClass = paramTyClass;
|
||||
this.content = content;
|
||||
}
|
||||
|
||||
@XmlElement
|
||||
public Class<?> getParamTypeClass() {
|
||||
return paramTypeClass;
|
||||
}
|
||||
|
||||
public void setParamTypeClass(Class<?> paramTypeClass) {
|
||||
this.paramTypeClass = paramTypeClass;
|
||||
}
|
||||
|
||||
@XmlElement
|
||||
public String getContent() {
|
||||
return content;
|
||||
}
|
||||
|
||||
public void setContent(String content) {
|
||||
this.content = content;
|
||||
}
|
||||
|
||||
}
|
|
@ -2,11 +2,9 @@ package org.bench4q.share.models.master.plugin;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlElementWrapper;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class PluginInfoModel {
|
||||
|
||||
|
@ -23,7 +21,7 @@ public class PluginInfoModel {
|
|||
}
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name="paramInfoModel",type=ParamInfoModel.class)
|
||||
public List<ParamInfoModel> getParamInfoModels() {
|
||||
return paramInfoModels;
|
||||
}
|
||||
|
|
|
@ -47,7 +47,7 @@ public class PluginResponseModel {
|
|||
}
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name = "behaviroInfoModel", type = BehaviorInfoModel.class)
|
||||
public List<BehaviorInfoModel> getBehaviorInfoModels() {
|
||||
return behaviorInfoModels;
|
||||
}
|
||||
|
@ -57,7 +57,7 @@ public class PluginResponseModel {
|
|||
}
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name = "pluginUIModel", type = PluginUIModel.class)
|
||||
public List<PluginUIModel> getPluginUIModels() {
|
||||
return pluginUIModels;
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ import javax.xml.bind.annotation.XmlRootElement;
|
|||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement(name = "ui")
|
||||
public class PluginUIModel{
|
||||
public class PluginUIModel {
|
||||
private PluginInfoModel pluginInfoModel;
|
||||
private List<BehaviorInfoModel> behaviorInfos;
|
||||
private Date createTimeDate;
|
||||
|
@ -23,7 +23,7 @@ public class PluginUIModel{
|
|||
}
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name = "behaviorInfoModel", type = BehaviorInfoModel.class)
|
||||
public List<BehaviorInfoModel> getBehaviorInfos() {
|
||||
return behaviorInfos;
|
||||
}
|
||||
|
|
|
@ -2,17 +2,17 @@ package org.bench4q.share.models.master.plugin;
|
|||
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlElementWrapper;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class RadioButtonModel extends ParamTypeModel {
|
||||
private List<ChoiceModel> choiceModels;
|
||||
|
||||
@XmlElementWrapper
|
||||
@XmlElement
|
||||
@XmlElement(name="choiceModel",type=ChoiceModel.class)
|
||||
public List<ChoiceModel> getChoiceModels() {
|
||||
return choiceModels;
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
package org.bench4q.share.models.master.plugin;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlRootElement;
|
||||
|
||||
import com.sun.xml.internal.txw2.annotation.XmlElement;
|
||||
|
||||
@XmlRootElement
|
||||
public class TableModel extends ParamTypeModel {
|
||||
|
|
Loading…
Reference in New Issue