Interface UserLogger
Java interface defines the necessary methods invoked by the Import/Export Connector (IEC) application
when processing a Log Action component configured in the executed scenario; You
develop a Java class implementing this interface to customize the
behavior of the IEC application in your SAP CC system landscape.
Implementation in Your IEC Application
When you need to add and customize a Log Action component in a
scenario configured
with the CAT Tool user interface of SAP Convergent Charging,
you develop a Java class that implements the functions expected by your business requirements.
Design and develop the behavior of the methods invoked by the running IEC application when starting, processing a Log Action component configured in the exectued scenario:
- filtered(..)
- rejected(..)
- terminated(..)
Note
If you want that the running IEC application is able to initialize some properties, make sure
you extend your customized Java class with the JavaTask abstract class.
Design and develop the JavaTask.setProperties(..) method.
Customizing Sequence
Your customized Java class must implement this UserLogger Java interface.
To implement this interface, you develop its five methods depending on your business requirements:
init()close()terminated(DataCollection, String)rejected(DataCollection, String, String[], String)filtered(DataCollection, String, String[], String)
To compile this Java class you need the iec.jar file in your Java compiler classpath.
Once developed, you specify your Java class in the relevant customized scenario and component:
Set up a Log Action component with CAT Tool.
Code Snippet
Refer to the tutorial: Implementing a console logger
This example shows you how to develop a class that implements the UserLogger interface.
The example defines the ConsoleLogger class that is used to print each event on a console.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Invoked by a running IEC application when the execution of the UserLogger is complete.voidfiltered(DataCollection dc, String reasonCode, String[] args, String actionUid) Invoked by an action when the processing of thedata collectionis complete and filtered.voidinit()Invoked by a running IEC application to initialize the UserLogger at the time of its creation.voidrejected(DataCollection dc, String reasonCode, String[] args, String actionUid) Invoked by an action when the processing of thedata collectionis complete but failed.voidterminated(DataCollection dc, String actionUid) Invoked by an action when the processing of thedata collectionis complete and successful.
-
Method Details
-
init
void init()Invoked by a running IEC application to initialize the UserLogger at the time of its creation. -
close
void close()Invoked by a running IEC application when the execution of the UserLogger is complete. -
terminated
Invoked by an action when the processing of thedata collectionis complete and successful.- Parameters:
dc- Thedata collectionactionUid- The ID of the action
-
rejected
Invoked by an action when the processing of thedata collectionis complete but failed. Two parameters specify more details about the failure: the reason code and the array of parameters related to the reason code.- Parameters:
dc- Thedata collectionreasonCode- The reason code of the rejectionargs- The parameter array relating to the reason codeactionUid- The ID of the action
-
filtered
Invoked by an action when the processing of thedata collectionis complete and filtered.- Parameters:
dc- Thedata collectionreasonCode- The reason code of the filteringargs- The parameter array relating to the reason codeactionUid- The ID of the action
-