public class ModifySubscriptionOp extends Object implements MessageOperation
subscription master data to the SAP CC system.
The system compares the new subscription against the old one (stored in the database).
During the modification, root subscription, all sub-subscriptions and included charge activations are compared thanks to:
Example
If the same counter is part of both subscriptions, then it will be modified according to its value from new subscription. If a counter is only part of new subscription then it will be created. Finally, if a counter is part of the old subscription but not present in the new one then it will be removed.
When a subscription (or a charge activation) contains some counters, inconsistencies may occur since counters are also modified through the charging process ("lost update" problem).
A safe way to modify a subscription without modifying its counters (partially or completely) is to use
the ignoreCounters. This parameter has 3 different values:
ANY_COUNTERS (default): Any counters from the new subscription are ignored.
This is the default and current behavior described above.
UNSPECIFIED_COUNTERS: Only unspecified counters in the new subscription are ignored.
This allows modifying some without touching the others.
ALL_COUNTERS: All counters from the new subscription are ignored.
Counter modifications are not possible in that case.
Note
Counter removal is only possible with the option ignoreCounters set to ANY_COUNTERS.
This operation is not compliant with the rerating services.
This operation may conflict with the prerating services (deprecated since version 1.0). This may lead to inconsistency if the modification
is done in the past since the post-rating could have a result that differs from the one of the related prerating.
To prevent from that, the user is warned when he/she tries to modify a subscription containing unresolved preratings.
But if you consider the modification as safe regarding prerating, you can force it (see ignorePrerating).
Note
When you using the create or modify operations, only the directly held subscription context is taken into account.
The SAP CC system ignores the data set in the context chronology.
ModifySubscriptionResult The XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="modifySubscription">
<xs:complexType>
<xs:sequence>
<xs:element ref="subscription" minOccurs="1" maxOccurs="1"/>
</xs:sequence>
<xs:attribute name="modificationDate" type="xs:dateTime"/>
<xs:attribute name="ignorePreRating" type="xs:boolean" default="false"/>
<xs:attribute name="ignorePendingSession" type="xs:boolean" default="false"/>
<xs:attribute name="ignoreCounters" type="IgnoreCountersType" default="any"/>
</xs:complexType>
</xs:element>
<xs:simpleType name="IgnoreCountersType">
<xs:restriction base="xs:string">
<xs:enumeration value="any"/>
<xs:enumeration value="unspecified"/>
<xs:enumeration value="all"/>
</xs:restriction>
</xs:simpleType>
You can send this operation request in HCI messages to the following final target types of instances in the connected SAP CC system:
| Edition | Final Target Instances | |||||
| rater | updater | guider | bulkLoader | taxer | dispatcher | |
| charge | No | Yes | No | No | No | No |
This operation is audited as part of the audit domain CUSTOMER
| Modifier and Type | Field and Description |
|---|---|
static int |
ALL_COUNTERS |
static int |
ANY_COUNTERS |
static String |
OPERATION_NAME |
static int |
UNSPECIFIED_COUNTERS |
| Constructor and Description |
|---|
ModifySubscriptionOp()
Builds an empty operation
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCharacterData(String cData)
Adds character data to the content element.
|
void |
addChild(String tagName,
XMLMarshallable child)
Adds a child to the object, the
child representing
the marshallable object which must be added to the element. |
int |
getIgnoreCounters()
Gets the ignoreCounters attribute
|
Date |
getModificationDate()
Gets the modification date
|
String |
getName()
Returns the XML name of the operation: "modifySubscription"
|
SubscriptionModel |
getSubscription()
Gets the new subscription definition
|
boolean |
isIgnorePendingSession()
Gets the ignorePendingSession attribute
|
boolean |
isIgnorePreRating()
Gets the ignorePreRating attribute
|
void |
marshal(XMLOutputter output)
Gives an XML representation of this object, including its children.
|
void |
setAttributes(XMLAttributes atts)
Sets the attributes of the XML representation of the element being
processed.
|
void |
setIgnoreCounters(int ignoreCounters)
Sets the ignoreCounters attribute
|
void |
setIgnorePendingSession(boolean ignorePendingSession)
Sets the ignorePendingSession attribute
|
void |
setIgnorePreRating(boolean ignorePreRating)
Sets the ignorePreRating attribute
|
void |
setModificationDate(Date modificationDate)
Sets the modification date
|
void |
setSubscription(SubscriptionModel s)
Sets the new subscription definition
|
public static final String OPERATION_NAME
public static final int ANY_COUNTERS
public static final int UNSPECIFIED_COUNTERS
public static final int ALL_COUNTERS
public Date getModificationDate()
public void setModificationDate(Date modificationDate)
modificationDate - The modification datepublic String getName()
getName in interface MessageOperationpublic SubscriptionModel getSubscription()
public void setSubscription(SubscriptionModel s)
s - The new subscription definitionpublic boolean isIgnorePreRating()
public void setIgnorePreRating(boolean ignorePreRating)
ignorePreRating - public boolean isIgnorePendingSession()
public void setIgnorePendingSession(boolean ignorePendingSession)
ignorePendingSession - public int getIgnoreCounters()
public void setIgnoreCounters(int ignoreCounters)
ignoreCounters - public void setAttributes(XMLAttributes atts)
XMLMarshallablesetAttributes in interface XMLMarshallableatts - The XML attributes of the current elementpublic void addCharacterData(String cData)
XMLMarshallableaddCharacterData in interface XMLMarshallablecData - The character data to be addedpublic void addChild(String tagName, XMLMarshallable child)
XMLMarshallablechild representing
the marshallable object which must be added to the element.addChild in interface XMLMarshallabletagName - The name of tag for the childchild - The child to be addedpublic void marshal(XMLOutputter output)
XMLMarshallablemarshal in interface XMLMarshallableoutput - The XML output to marshal the object into