Loading Java library to validate email addresses - 6.5

Talend Job Script Reference Guide

Talend Big Data
Talend Big Data Platform
Talend Data Fabric
Talend Data Integration
Talend Data Management Platform
Talend Data Services Platform
Talend ESB
Talend MDM Platform
Talend Real-Time Big Data Platform
Talend CommandLine
Talend Studio
Design and Development > Designing Jobs

The Java code defined in the first tJavaRow component requires a Java library to be loaded before it can work. Follow the procedure below to add and configure a tLibraryLoad component to load that Java library and import the relevant classes at the time of Job execution.


  1. Next to the second tJavaRow component, add a new component, tLibraryLoad.
    addComponent {
    	setComponentDefinition {
    		TYPE: "tLibraryLoad",
    		NAME: "tLibraryLoad_1",
    		POSITION: 256, 64
  2. Next to the setComponentDefinition {} function, use the setSettings {} function to load the Java library and import the needed classes.
    	setSettings {
    		LIBRARY : "\"jakarta-oro-2.0.8.jar\"",
    		IMPORT : "import org.apache.oro.text.regex.Perl5Matcher;
    import org.apache.oro.text.regex.Perl5Compiler;
    import org.apache.oro.text.regex.Pattern;"