Apama 10.3 | Apama Documentation | Connecting Apama Applications to External Components | Working with IAF Plug-ins | Java Codec Plug-in Development | The codec plug-in development specification for Java
The codec plug-in development specification for Java
Java codec functions to implement
Communication with other layers
Java codec exceptions
Semantic Mapper exceptions
Working with normalized events
A Java codec layer plug-in is implemented as a Java class extending AbstractEventCodec. Typically this class would be packaged up, together with any supporting classes, as a Java Archive (.jar) file.
To comply with Apama's codec plug-in development specification, an event codec class must satisfy two conditions:
1. It must have a constructor with the signature:
public AbstractEventCodec(
String name,
    EventCodecProperty[] properties,
    TimestampConfig timestampConfig)
throws CodecException
This will be used by the IAF to instantiate the plug-in.
2. It must extend the com.apama.iaf.plugin.AbstractEventCodec class, correctly implementing all of its abstract methods.
(These methods are mostly directly equivalent to the functions with the same names in the C/C++ codec plug-in development specification.)
Note that all Java plug-ins are dependent on classes in ap-iaf-extension-api.jar, so this file must always be on the classpath during plug-in development. It is located in the Apama installation's lib directory.
Unless otherwise stated, Java classes referred to in this chapter are members of the com.apama.iaf.plugin package, whose classes and interfaces are contained in this .jar.

Copyright © 2013-2018 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.