Build Path Mess

S

Sahil Dave

Hi

I have been away from java for quite a long time, and certainly away
from Eclipse.
I have two applications, one of which uses the other. The problem here
is that i am trying to import classes from app2 into app1, but its not
able to find them.

How do i get around this? I know that it has to do something with the
build path. I am using Eclipse.

Thanks

Sahil Dave
 
L

Lew

Hi

I have been away from java for quite a long time, and certainly away
from Eclipse.
I have two applications, one of which uses the other. The problem here
is that i am trying to import classes from app2 into app1, but its not
able to find them.

How do i get around this? I know that it has to do something with the
build path. I am using Eclipse.

Read about packages and classpaths in the tutorial on java.sun.com.
 
T

Tom Anderson

I have been away from java for quite a long time, and certainly away
from Eclipse. I have two applications, one of which uses the other. The
problem here is that i am trying to import classes from app2 into app1,
but its not able to find them.

How do i get around this? I know that it has to do something with the
build path. I am using Eclipse.

Right click on app2 > Build Path > Configure Build Path > Order and
Export. The source folders defining those classes need ticks in their
tickyboxes - that means they're exported to other projects.

If they do have ticks, ask again and i'll see what i can think of.

tom
 
T

Tom Anderson

Read about packages and classpaths in the tutorial on java.sun.com.

Did you see the bit where he says "I am using Eclipse"? It's on the last
line of the second paragraph.

tom
 
L

Lew

Did you see the bit where he says "I am using Eclipse"? It's on the last
line of the second paragraph.

Did you read the thread wherein people discuss that knowing the
underlying concepts is essential to effective use of an IDE?

I believe you even participated in that thread, as you may recall.
 
S

Sahil Dave

Right click on app2 > Build Path > Configure Build Path > Order and
Export. The source folders defining those classes need ticks in their
tickyboxes - that means they're exported to other projects.

If they do have ticks, ask again and i'll see what i can think of.

yeah, those are ticked!
 
S

Sahil Dave

Read about packages and classpaths in the tutorial on java.sun.com.

I know about packages and classpaths. I am a bit rusty on the Eclipse
way of managing those things.

Thanks,
Sahil
 
T

Tom Anderson

Did you read the thread wherein people discuss that knowing the
underlying concepts is essential to effective use of an IDE?

I don't see any evidence that he doesn't know the underlying concepts. He
was quite specific in that the problem was configuring Eclipse. It doesn't
matter if you know every last comma of the rules about classpaths if you
don't know where the Configure Build Path dialogue box is.
I believe you even participated in that thread, as you may recall.

I don't remember things, that's what google is for.

tom

--
There was this one time we were talking about [...] that if you fill a
bucket with water and spin it around, some of the force acting to hold
the water back comes from the edge of the Universe. We were on tour in the
Netherlands, and when we got to the venue, backstage someone said, 'let's
try it out'. So we yelled, 'Oi, bring us a bucket and some rope!' They
did and we made an awful mess. -- Billy Bragg, feat. Ernst Mach
 
T

Tom Anderson

yeah, those are ticked!

Tick 'em harder!

And app2 is definitely on the build path of app1?

Would you care to post the .classpath files from both projects?

Sometimes things do just get fucked up. The usual dead chickens to wave
are, in ascending order of mana:

1. Select all projects, refresh.
2. Project > Clean ... > all projects
3. Quit and restart Eclipse
4. Quit and restart Eclipse with the -clean flag
5. Close the projects, then reopen them (then clean)
6. Delete the workspace, check out the projects from version control again
7. Switch to IntelliJ

I did a pass mucking out all our dev VMs today. One had a build error, i
forget what but it was something nonspecific like 'project XYZ could not
be built due to build errors', which was resistant to levels 1 to 3 of the
above (i didn't try 4), but was cured by level 5. There was absolutely
nothing actually wrong with the projects, Eclipse just had its knickers in
a twist.

tom

--
There was this one time we were talking about [...] that if you fill a
bucket with water and spin it around, some of the force acting to hold
the water back comes from the edge of the Universe. We were on tour in the
Netherlands, and when we got to the venue, backstage someone said, 'let's
try it out'. So we yelled, 'Oi, bring us a bucket and some rope!' They
did and we made an awful mess. -- Billy Bragg, feat. Ernst Mach
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,983
Messages
2,570,187
Members
46,747
Latest member
jojoBizaroo

Latest Threads

Top