. Java code activity does not compile in Java 1.5. The error is similar to the following: Note: /temp/javaCode/PublishAllBalancesJavaEventSource.java uses unchecked or unsafe operations.Note: Recompile with -Xlint:unchecked for details.

. Java code activity does not compile in Java 1.5. The error is similar to the following: Note: /temp/javaCode/PublishAllBalancesJavaEventSource.java uses unchecked or unsafe operations.Note: Recompile with -Xlint:unchecked for details.

book

Article ID: KB0091261

calendar_today

Updated On:

Products Versions
TIBCO ActiveMatrix BusinessWorks -
Not Applicable -

Description

Resolution:
Some Java code that is compiled in Java 1.4 fails compiling in Java 1.5. The above error means that you need to recompile the Java code using the -Xlint:unchecked flag. In standalone JDK, the syntax should:

javac -Xlint:unchecked myclass.java

However, BW does not recognize the -Xlint:unchecked flag. The equivalent flag used in BW Java code:

@SuppressWarnings("unchecked")

Add it before the class declaration and recompile the code. For example,

@SuppressWarnings("unchecked")
public class BusinessCenters2JavaCode{
}
public class BusinessJavaCode{
}

Issue/Introduction

. Java code activity does not compile in Java 1.5. The error is similar to the following: Note: /temp/javaCode/PublishAllBalancesJavaEventSource.java uses unchecked or unsafe operations.Note: Recompile with -Xlint:unchecked for details.