use of org.apache.cxf.ws.rm.feature.RMFeature in project cxf by apache.
the class WSRM12ServerCycleTest method wsrm.
public static RMFeature wsrm(long brtxInterval, long ackInterval) {
RMAssertion.BaseRetransmissionInterval baseRetransmissionInterval = new RMAssertion.BaseRetransmissionInterval();
baseRetransmissionInterval.setMilliseconds(Long.valueOf(brtxInterval));
RMAssertion.AcknowledgementInterval acknowledgementInterval = new RMAssertion.AcknowledgementInterval();
acknowledgementInterval.setMilliseconds(Long.valueOf(ackInterval));
RMAssertion rmAssertion = new RMAssertion();
rmAssertion.setAcknowledgementInterval(acknowledgementInterval);
rmAssertion.setBaseRetransmissionInterval(baseRetransmissionInterval);
AcksPolicyType acksPolicy = new AcksPolicyType();
acksPolicy.setIntraMessageThreshold(0);
DestinationPolicyType destinationPolicy = new DestinationPolicyType();
destinationPolicy.setAcksPolicy(acksPolicy);
RMFeature feature = new RMFeature();
feature.setRMAssertion(rmAssertion);
feature.setDestinationPolicy(destinationPolicy);
feature.setRMNamespace(RM11Constants.NAMESPACE_URI);
return feature;
}
Aggregations