Write the Java source file

When you code the parameters for each method, make sure you use the Java datatype that corresponds to the datatype you defined in the EAServer Manager.

NoteIf you have an IDL interface If you are starting with an IDL interface rather than an existing class file, you can use EAServer Manager to create a class that contains the necessary method declarations. See “Generate stub, skeleton, and implementation files” for more information.

StepsImplementing the component

  1. Generate stub, skeleton, and implementation files – Generate the files required to run the component. If you are starting development with an IDL interface, and not an existing Java class or interface, EAServer Manager will generate a sample implementation with all the required method signatures.

  2. Add package import statements – Import the packages that contain the classes that you need to use in your Java class.

  3. Code the constructor – Provide a default constructor to be called when EAServer loads the implementation class.

  4. Implement control interface methods – Implement the control interface methods to respond to changes in the instance lifecycle.

  5. Add error handling code – Add code that gracefully handles errors by logging status messages and sending meaningful messages to the client.

  6. To finish up, you can use these advanced technique to polish your component implementation:

    1. Manage database connections – Connect to databases through connection caches using the Connection Management API.

    2. Return result sets – Return result sets using the EAServer Result Sets API.

    3. Issue intercomponent calls – Instantiate a Java stub to make intercomponent calls.