You are here

Compiling java - NewIconEvaluator.java

Submitted by SKerstiens on Wed, 07/22/2009 - 14:17

I have followed the step outlined in the Luminis SDK / User Interface Customization Guide /4.1 in order to add a webct icon to the nested tables and at the step of compile, I enter $JAVA_HOME/bin/javac NewIconEvaluator.java and I get the output of

"error: cannot read: NewIconEvaluator.java
1 error"

How do I fix this?

Thanks,

SKerstiens

Luminis Version:

How-To:

Modification:

Comments

Try running this command inside the directory you are compiling NewIconEvaluator.java : 

". cpclasspath"

(note the dot at the beginning and the space in between - [dot][space]cpclasspath

Once you run this command try compiling again.

 

Once section that was in the part about "Conditionalize icons based on role" said the following:

"This declaration assumes that the CustomIconEvaluator class file will be stored under the
following Luminis Platform path, which if not present must be created:
$CP_ROOT/webapps/luminis/WEB-INF/classes/com/sungardhe/cpicons"

That section was not repeated in the adding an icon that I was looking at for steps. I added that folder directory and the compile worked. but it gave the output of:

"Note: NewIconEvaluator.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details"

BUT when I ran the ". cpclasspath" it does nothing. no output for the command at all. Is that command executed in the same directory in Cygwin or do I need to change to the luminis/bin directory?

Thanks,

Stephen

 

I get these warnings, and the evaluator does not work.  Do these warning a problem?

 

warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/${build.jar.manifest.class-path}": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imqxm.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_ja.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_zh_CN.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_fr.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_de.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_es.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_it.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_sw.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_ko.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_zh_TW.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/imq_lang1.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/xsdlib.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/xsdlib.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/opt/sun/private/share/lib/xsdlib.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/usr/share/lib/xsdlib.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/xsdlib.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/relaxngDatatype.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/opt/sun/private/share/lib/relaxngDatatype.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/usr/share/lib/relaxngDatatype.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/relaxngDatatype.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/jax-qname.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/jax-qname.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/opt/sun/share/lib/jax-qname.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/usr/share/lib/jax-qname.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/jax-qname.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/namespace.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/namespace.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/opt/sun/share/lib/namespace.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/usr/share/lib/namespace.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/namespace.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/jaxp-api.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jaxp/lib/jaxp-api.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jaxp/lib/endorsed/sax.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jaxp/lib/endorsed/dom.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jaxp/lib/endorsed/xercesImpl.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/opt/sun/share/lib/xercesImpl.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/usr/share/lib/xercesImpl.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/xercesImpl.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jaxp/lib/endorsed/xalan.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/opt/sun/share/lib/xalan.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/usr/share/lib/xalan.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/xalan.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/dom4j.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../jwsdp-shared/lib/dom4j.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../private/share/lib/jaxrpc-spi.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/saaj-api.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/saaj-impl.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/jax-qname.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/namespace.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../private/share/lib/relaxngDatatype.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/xsdlib.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/../../private/share/lib/xsdlib.jar": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/${build.jar.manifest.class-path}": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/${build.jar.manifest.class-path}": no such file or directory
warning: [path] bad path element "/opt/luminis/webapps/luminis/WEB-INF/lib/${build.jar.manifest.class-path}": no such file or directory
/opt/luminis/products/sdk/ui-sdk/samples/com/sungardhe/cpicons/CustomIconEvaluator.java:45: warning: [unchecked] unchecked call to put(K,V) as a member of the raw type java.util.Map
                icons.put( IconEvaluator.CALENDAR_ICON,   "" + calEnabled );
                         ^
57 warnings
 

These are the steps we use to compile our custom Icons on 4.2.1.87

 # create a "working" directory
[lumusr@mytest ~]$ mkdir ~/work
[lumusr@mytest ~]$ mkdir ~/work/customicons
[lumusr@mytest ~]$ cd ~/work/customicons

 # copy over uportal.jar
[lumusr@mytest customicons]$ ls $CP_ROOT/webapps/luminis/WEB-INF/lib/
[lumusr@mytest customicons]$ ls -l /opt/luminis/webapps/luminis/WEB-INF/lib/uportal.jar
[lumusr@mytest customicons]$ cp /opt/luminis/webapps/luminis/WEB-INF/lib/uportal.jar .

 # expand uportal.jar
[lumusr@mytest customicons]$ jar xf uportal.jar

 # create our directory tree
[lumusr@mytest customicons]$ mkdir -p com/sungardhe/cpicons/

 # create our java file
[lumusr@mytest customicons]$ vi CustomIconEvaluator.java

 # make sure our environment settings are set
[lumusr@mytest customicons]$ which cpclasspath
[lumusr@mytest customicons]$ . cpclasspath

 # compile CustomIconEvaluator
[lumusr@mytest customicons]$ echo $JAVA_HOME
[lumusr@mytest customicons]$ $JAVA_HOME/bin/javac CustomIconEvaluator.java
[lumusr@mytest customicons]$ $JAVA_HOME/bin/javac -Xlint:unchecked CustomIconEvaluator.java
 # okay, it recreated the class

 # create the directory tree where the class will reside
[lumusr@mytest customicons]$ mkdir -p $CP_ROOT/webapps/luminis/WEB-INF/classes/com/sungardhe/cpicons/

 # put the class in its location
[lumusr@mytest customicons]$ cp CustomIconEvaluator.class $CP_ROOT/webapps/luminis/WEB-INF/classes/com/sungardhe/cpicons/

 

I know this is an old post, but we're one of the last 15 or so Lum3 schools to migrate to Lum4... this might help someone else...

After building your NewIconEvaluator.java (or MultipleIconEvaluator.java or whatever) file, do the following:

. cpclasspath
javac -Xlint:unchecked NewIconEvaluator.java

Note the space between the dot and cpclasspath. (The SunGard docs are a little sparse on the instructions.)

I found this answer in other posts, but my custom icons still don't work... I get rendering errors. ...more post browsing for ideas why I get rendering errors.

--Ginny
Colorado School of Mines