Ron Wheeler wrote:
> 
> Your internal service can extend your external objects to add the 
> additional info.
> The call from external to internal is not redundant.
> Avoiding copy and paste is a good idea and you should not have any of 
> that if you organize the classes in the right way.
> 
> We do this frequently to create a hierarchy of services that avoids 
> duplication of services and classes.
> 
> Ron
> 

Let me give a code eaxmple... CustomerID appears in the WSDL, despite the
annotation:
@XmlType(propOrder = {})
@XmlAccessorType(XmlAccessType.PROPERTY)
public class MemberPK implements Serializable {
private static final long serialVersionUID = 5L;

private Integer customerId;
private String customerName;
...other fields

/**
* @return the customerId
*/
public Integer getCustomerId() {
return customerId;
}

/**
* @param customerId
* the customerId to set
*/
public void setCustomerId(Integer customerId) {
this.customerId = customerId;
}
}

@XmlType(propOrder = {})
@XmlAccessorType(XmlAccessType.PROPERTY)
public class ExternalMemberPK extends MemberPK {
private static final long serialVersionUID = 5L;

/**
* {...@inheritdoc}
*/
@Override
@XmlTransient
public Integer getCustomerId() {
return customerId;
}
}
-- 
View this message in context: 
http://cxf.547215.n5.nabble.com/Overriding-JAXB-annotations-tp3320779p3322540.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to