Package creation with Sun One studio and MIDP

Package creation with Sun One studio and MIDP

Post by Brandon Ro » Thu, 14 Aug 2003 04:38:54


Am I the only one that feels that some things in the Nokia integration with
Sun One studio seem magical? I'm still relatively new to Java and J2ME, and
am not as familiar with the Sun One IDE, so this is probably the source of
my frustration. But hopefully one the talented individuals here can answer
a few questions.

If I create a class using File/New, I can't import the javax.microedition
packages, but when I use the Tools/Nokia/New Class, it works fine. I
imagine it's setting some variable somewhere, but I have no idea what or
where. Does anyone know how this works. Similarly, I couldn't get the
microedition stuff working in Eclipse, so I assume that there is some
project settings that I'm missing.

My latest problem is this:

I created two new packages, an events package to store the events for my
game, and a tasks package for TimerTasks for my game. I created these
packages the way I created all my other packages. I then added a few .java
files (using Nokia new class) to each package. I added the .class files to
the classes tab of tools/nokia/new application package.

Here's the kicker. When I click generate, I get an error that says something
like this,

Unable to create Application Package.
java.io.FileNotFoundException:
C:\Java\Projects\Game\..\preverified-temp\gameevents\SomeClass.class (The
system cannot find the file specified)

Does anyone have a clue what's going on here? I can't even find a further
subdirectory under my Game directory.

I moved the files in these rogue packages to some packages I had created
that already worked, and everything compiles fine. So it must be something
I'm doing when I create the packages. Has anyone had this problem?

Brandon