• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

project build

 
ben oliver
Ranch Hand
Posts: 375
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In Eclipse,

1. what's the difference between "build" and "clean build". Why doestimes a pj can be built OK using clean build but not with normal "build" ?

2. If I have a few projects (some are ejb, few are java projects). If I click "build" and can build each of them. What does that mean ? does it just mean it generates the .class file properly ? In order to really deploy the whole thing, do I still need to write separate ant script to bundle everything ? The basic question is --- By clicking "build" does not automatically create any .war ot .ear, correct ?

thanks.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34851
369
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ben,
Which IDE are you asking about? Eclipse, NetBeans, IntelliJ, etc?
 
ben oliver
Ranch Hand
Posts: 375
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using eclipse
 
Seetharaman Venkatasamy
Ranch Hand
Posts: 5575
Eclipse IDE Java Windows XP
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Build: generate .class file for your .java file .

Clean : it will remove all the .class file from particular folder

CleanBuild: it will remove all the .class file and then generate .class file for your source file(.java)[i dont see this option in eclipse. but i think it is in Netbean]
 
ben oliver
Ranch Hand
Posts: 375
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
sounds good. but if you choose to do "build", it also creates .class files and it should automatically replace the old .class, right ? so what's the difference of first removing all .class files ?
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Build compiles only changed .java files. This could lead to problems if, for example, class A calls a method on class B, but you change the signature of that method - build then compiles only B.java (assuming you had previously compiled boht A.java and B.java). Now you have a broken app. (This is only one of several things that can go wrong.)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic