@XmlElementWrapper
@XmlElements({ @XmlElement(name = "sampleBean", type = SampleBean.class) })
/*
* If SampleBean is generic, use this sintax
*
@XmlElements({ @XmlElement(name = "ledger", type = SampleBean.class),
@XmlElement(name = "settlement", type = SettlementDTO.class),
@XmlElement(name = "inventory", type = InventoryDTO.class),
@XmlElement(name = "statement", type = ClientDocumentDTO.class) })
*/
public List<SampleBean> getData() {
return data;
}
java类javax.xml.bind.annotation.XmlElements的实例源码
Page.java 文件源码
项目:appverse-server
阅读 28
收藏 0
点赞 0
评论 0
LSLibraryItem.java 文件源码
项目:grafikon
阅读 23
收藏 0
点赞 0
评论 0
@XmlElements({
@XmlElement(name = "node", type = LSNode.class),
@XmlElement(name = "output_template", type = LSOutputTemplate.class),
@XmlElement(name = "engine_class", type = LSEngineClass.class),
@XmlElement(name = "train_type", type = LSTrainType.class),
@XmlElement(name = "line_class", type = LSLineClass.class),
@XmlElement(name = "train_type_category", type = LSTrainTypeCategory.class)
})
public Object getObject() {
return object;
}
LSTrain.java 文件源码
项目:grafikon
阅读 29
收藏 0
点赞 0
评论 0
@XmlElementWrapper
@XmlElements({
@XmlElement(name = "node", type = LSTrainRoutePartNode.class),
@XmlElement(name = "line", type = LSTrainRoutePartLine.class)
})
public List<Object> getRoute() {
return route;
}
LSTrain.java 文件源码
项目:grafikon
阅读 30
收藏 0
点赞 0
评论 0
@XmlElementWrapper
@XmlElements({
@XmlElement(name = "node", type = LSTrainRoutePartNode.class),
@XmlElement(name = "line", type = LSTrainRoutePartLine.class)
})
public List<Object> getRoute() {
return route;
}
ReportJobModel.java 文件源码
项目:jrs-rest-java-client
阅读 21
收藏 0
点赞 0
评论 0
@Override
@XmlElements({
@XmlElement(name = "simpleTriggerModel", type = ReportJobSimpleTriggerModel.class),
@XmlElement(name = "calendarTriggerModel", type = ReportJobCalendarTriggerModel.class)})
public JobTrigger getTrigger() {
JobTrigger model = super.getTrigger();
if (model == null) return null;
if ((model instanceof ReportJobSimpleTriggerModel) || (model instanceof ReportJobCalendarTriggerModel))
return model;
else
throw new JSClientException("Please useReportJobTriggerModel instead of JobTrigger in ReportJobModel class.");
}
OrganizationContact.java 文件源码
项目:modules
阅读 22
收藏 0
点赞 0
评论 0
@XmlElements(value = {
@XmlElement(name = "provider", type = UniqueID.class),
@XmlElement(name = "person", type = Person.class),
})
public Object getContact() {
if (contact != null) {
return contact;
} else {
if (providerEntityID != null && !providerEntityID.isEmpty()) {
return new UniqueID(providerEntityID);
} else {
return person;
}
}
}
Job.java 文件源码
项目:hyperjaxb3
阅读 24
收藏 0
点赞 0
评论 0
@XmlElementWrapper(name = "tasks", namespace = "urn:test")
@XmlElements( {
@XmlElement(name = "usertask", namespace = "urn:test", type = UserTask.class),
@XmlElement(name = "autotask", namespace = "urn:test", type = AutoTask.class) })
public Collection<Node> getNodes() {
return nodes;
}
PowerInfo.java 文件源码
项目:cats
阅读 22
收藏 0
点赞 0
评论 0
@XmlElementWrapper(name="PowerStatsList")
@XmlElements({
@XmlElement(name="PowerStats", type=PowerStatistics.class)
})
public List<PowerStatistics> getPowerStatistics() {
return powerStatistics;
}
RESTBatchOperation.java 文件源码
项目:geofence
阅读 22
收藏 0
点赞 0
评论 0
@XmlElements({
@XmlElement(name="user", type=RESTInputUser.class),
@XmlElement(name="userGroup", type=RESTInputGroup.class),
@XmlElement(name="instance", type=RESTInputInstance.class),
@XmlElement(name="rule", type=RESTInputRule.class)
})
public AbstractRESTPayload getPayload() {
return payload;
}
ClassDiscoverer.java 文件源码
项目:jaxb-visitor
阅读 23
收藏 0
点赞 0
评论 0
/**
* Parse the annotations on the field to see if there is an XmlElements
* annotation on it. If so, we'll check this annotation to see if it
* refers to any classes that are external from our code schema compile.
* If we find any, then we'll add them to our visitor.
* @param outline root of the generated code
* @param field parses the xml annotations looking for an external class
* @param directClasses set of direct classes to append to
* @throws IllegalAccessException throw if there's an error introspecting the annotations
*/
private static void parseXmlAnnotations(Outline outline, FieldOutline field, Set<String> directClasses) throws IllegalAccessException {
if (field instanceof UntypedListField) {
JFieldVar jfv = (JFieldVar) FieldHack.listField.get(field);
for(JAnnotationUse jau : jfv.annotations()) {
JClass jc = jau.getAnnotationClass();
if (jc.fullName().equals(XmlElements.class.getName())) {
JAnnotationArrayMember value = (JAnnotationArrayMember) jau.getAnnotationMembers().get("value");
for(JAnnotationUse anno : value.annotations()) {
handleXmlElement(outline, directClasses, anno.getAnnotationMembers().get("type"));
}
}
}
}
}