On Jan 29, 10:12 am, "Andrew Thompson" <andrewtho...@gmail.com> wrote:
> On Jan 29, 8:04 pm, "Adam Jiang" <Jiang.A...@gmail.com> wrote:
>
> > This is the situation.
> > I got a two .jar files, one of which contained the classes and another
> > one contained the source code related with certain class. When I put
> > them in an eclipse project, and add source code for the class-jar file
> > with source-jar file, I can view the code without modifying.
> > Is this source read-only?
> > How can I modify these code and then recompile this .jar file?I imagine the IDE will *not* be able to edit the
> source files while they are in an *archive*.
>
> If you expand the archive out to 'loose files' on
> the local file system, and check they do not
> have the 'read only' attribute set (it is uncommon),
> the IDE should be able to edit them.
To expand them you can use any program which understand the zip format
cause a jar file is simply a zip archive.
>
> You will probably need to reconfigure the project
> to work with the new arrangement, but that is a
> matter between you and your IDE.
>
> Andrew T.
|