Java反编译去掉语法糖工具

反编译class文件后,去掉语法糖反编译工具:XJad

Java文件:

public enum Color {
    RED, BLUE, GREEN;
}

IDEA反编译:

public enum Color {
    RED,
    BLUE,
    GREEN;

    private Color() {
    }
}

XJad反编译:

public final class Color extends Enum
{

	public static final Color RED;
	public static final Color BLUE;
	public static final Color GREEN;
	private static final Color $VALUES[];

	public static Color[] values()
	{
		return (Color[])$VALUES.clone();
	}

	public static Color valueOf(String name)
	{
		return (Color)Enum.valueOf(Color, name);
	}

	private Color(String s, int i)
	{
		super(s, i);
	}

	static 
	{
		RED = new Color("RED", 0);
		BLUE = new Color("BLUE", 1);
		GREEN = new Color("GREEN", 2);
		$VALUES = (new Color[] {
			RED, BLUE, GREEN
		});
	}
}

你可能感兴趣的:(Java)