Results 1 to 3 of 3
  1. #1
    KamikadZee is offline Member
    Join Date
    Oct 2011
    Posts
    9
    Rep Power
    0

    Default Compiling(Building) Changes(fixes) .class while I don't need that.

    So basically I'm new to java,(Well i came from C# so its almost the same),
    I started working on some emulated server files,
    In this case :
    I decompile whole .jar , file full of .class files,
    In eclipse started new project (around the folder where i extracted source)
    And new project was made perfectly (Ofcorse lot of errors where in there, but just because i decompile and use just one .jar file out of package and that shouldn't be the problem) The main problem for me, is when i try to build project it compiles .java files to .class files perfectly, Just the thing java compiler dose is
    Fixes errors...
    for example I had :
    config.java(Not compiled yet)
    .java file (before building project)
    Java Code:
     import gnu.trove.TIntIntHashMap;
    import gnu.trove.TIntObjectHashMap;
    import java.io.File;
    import java.io.FileInputStream;
    import java.io.FileOutputStream;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.math.BigInteger;
    import java.util.Arrays;
    import java.util.List;
    import java.util.Properties;
    import java.util.StringTokenizer;
    import java.util.logging.Logger;
    import javolution.util.FastList;
    import net.sf.l2j.gameserver.util.FloodProtectorConfig;
    import net.sf.l2j.util.StringUtil;
    And after fixing and cleaning It results me with .class files like it :

    .class file (after building project)
    Java Code:
     package net.sf.l2j;
    
    import FastList;
    import TIntIntHashMap;
    import TIntObjectHashMap;
    import java.io.File;
    import java.util.List;
    import java.util.Properties;
    import java.util.logging.Logger;
    import net.sf.l2j.gameserver.util.FloodProtectorConfig;
    Since i wanna same old file just with my custom edits without any fixes with all errors kept,
    How can i achieve that? Maybe i should download any other builder/compiler for eclipse as plugin or something?
    Thank you for help.

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,005
    Blog Entries
    7
    Rep Power
    20

    Default Re: Compiling(Building) Changes(fixes) .class while I don't need that.

    You have allowed Eclipse to automatically fix your code; go to Project>Properties and (de)select everything you like; especially the Java Code Style>Organize Imports part and the Java Compiler>Building part have a lot of settings that can be dis- or enabled.

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

  3. #3
    KamikadZee is offline Member
    Join Date
    Oct 2011
    Posts
    9
    Rep Power
    0

    Default Re: Compiling(Building) Changes(fixes) .class while I don't need that.

    I already did that I changed every setting tried everything don't even know what to try next...
    I think it's about javac compiler not even about eclipse... cuz when i try compile in cmd i get errors and file don't compiles...
    How can I just compile .java files to .class skiping all errors ? ;/ Cuz in eclipse settings nothing help's / works.
    And It's so frustrating...
    Maybe someone can offer any Guide or at last some other compiler that would Ignore Errors in code, (Cuz for me they are expected errors and should be kept)
    Any suggestion would help, thank you.

Similar Threads

  1. compiling .java into .class
    By khp in forum Advanced Java
    Replies: 4
    Last Post: 06-29-2009, 02:52 PM
  2. not compiling a copy of class -
    By itaipee in forum Eclipse
    Replies: 0
    Last Post: 01-07-2009, 09:47 AM
  3. Compiling a single class
    By ROSOBORONEXPORTCORP in forum New To Java
    Replies: 2
    Last Post: 01-28-2008, 12:27 PM
  4. Compiling a class in a package from cmd
    By Java Tip in forum Java Tip
    Replies: 0
    Last Post: 12-17-2007, 10:27 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •