Sample routine uisng JAVA APIs for T24

6k Views Asked by At

Can I have a sample routine (that has been tested) on latest T24/Transact release using Temenos Java APIs? As per Temenos, Infobasic routines cannot be used anymore if EXTENSIBLE.CUSTOMISATION flag is set to Y in SPF.

1

There are 1 best solutions below

0
On

Here is an actual, working sample that works in R20 - it is a sample of ENQUIRY build routine:

package com.bank;

import java.util.List;
import com.temenos.api.TStructure;
import com.temenos.t24.api.complex.eb.enquiryhook.FilterCriteria;
import com.temenos.t24.api.complex.eb.enquiryhook.EnquiryContext;
import com.temenos.t24.api.hook.system.Enquiry;

public class EnqBuildRoutineTest extends Enquiry {


    @Override 
    public List<FilterCriteria> setFilterCriteria(List<FilterCriteria> filterCriteria, EnquiryContext enquiryContext) {

        FilterCriteria criteria = new FilterCriteria();
        criteria.setFieldname("SECTOR.CODE");
        criteria.setOperand("LK");
        criteria.setValue("2...");
        filterCriteria.add(criteria);
        return filterCriteria; 
    }
}

In case you are using maven, you can use these dependencies in pom.xml:

    <dependency>
        <groupId>com.temenos</groupId>
        <artifactId>api</artifactId>
        <scope>system</scope>
        <systemPath>c:/Temenos/R20_MB/TAFJ/lib/TAFJClient.jar</systemPath>
        <version>1</version>
    </dependency>
    <dependency>
        <groupId>com.temenos</groupId>
        <artifactId>EnquiryHook</artifactId>
        <scope>system</scope>
        <systemPath>c:/Temenos/R20_MB/bnk/t24lib/EB_EnquiryHook.jar</systemPath>
        <version>1</version>
    </dependency>

Once you have packaged it inside JAR and placed in your Classpath, you need to create EB.API record with "Source Type = Method" and specify the overriden setFilterCriteria as the method inside EB.API record. You also need to specify Class name (EnqBuildRoutineTest in this case) and package name (com.bank).