Search code examples
java-melwuitnetbeans6.8midppreverify

Error preverifying class NetBeans 6.8 using lwuit api


I'm trying to develop a portable J2ME appli, but Netbeans do a class preverification of LWUIT library that uses optional APIs that some configurations don't have, so I get this error when I try to compile on a configuration without JSR-184 (M3G Optional API):

Error preverifying class com.sun.lwuit.animations.Transition3D VERIFIER ERROR com/sun/lwuit/animations/Transition3D.initTransition()V: Cannot find class javax/microedition/m3g/Node

I don't want to remove the classes from the LWUIT API because that classes works on other configurations compatibles with JSR-184

What I want is that NetBeans do not preverify the library, It is posible?

Here are some code:

//#ifdef JSR184
//# import com.sun.lwuit.animations.Transition3D;
//#else
import com.sun.lwuit.animations.CommonTransitions;
//#endif

        Transition out;
//#ifdef JSR184
//#         out = Transition3D.createRotation(500, true);
//#else
        out = CommonTransitions.createSlide(CommonTransitions.SLIDE_HORIZONTAL, true, 500);
//#endif
        setTransitionOutAnimator(out);

Thanks


Solution

  • We had the similar problems, as I remember BlackBerry handsets are problematic (?) for this JSR-184. What I did to solve this problem, I created different configurations for different targets and removed this problematic classes from LWUIT library, rebuild library for that target, and also modified project settings of related configuration accordingly. Hope it helps.