Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
emmanue1 committed Mar 25, 2015
0 parents commit 44b26e9
Show file tree
Hide file tree
Showing 217 changed files with 13,300 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Java
*.class

# JD-GUI
jd-gui.cfg

# Idea
.idea/
out/
*.ipr
*.iml
*.iws

# Eclipse
.settings/
classes/
.classpath
.project

# Mac
.DS_Store

# Maven
log/
target/

# Gradle
.gradle/
build/
676 changes: 676 additions & 0 deletions LICENSE

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions NOTICE
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
JD-GUI license - GPLv3

Libraries used:

Groovy - Apache License 2.0
Gradle - Apache License 2.0
JD-Core Java Release - GPLv3
RSyntaxTextArea - Modified BSD license

JD-GUI OSX distribution:

universalJavaApplicationStub - MIT License
52 changes: 52 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
#JD-GUI

JD-GUI, a standalone graphical utility that displays Java sources from CLASS files.

![](http://jd.benow.ca/img/screenshot17.png)

- Java Decompiler projects home page: [http://jd.benow.ca](http://jd.benow.ca)
- Java Decompiler Wikipedia page: [http://en.wikipedia.org/wiki/Java_Decompiler](http://en.wikipedia.org/wiki/Java_Decompiler)
- JD-GUI source code: [https://github.com/java-decompiler/jd-gui](https://github.com/java-decompiler/jd-gui)

##Description
JD-GUI is a standalone graphical utility that displays Java source codes of
".class" files. You can browse the reconstructed source code with the JD-GUI
for instant access to methods and fields.

##How to build JD-GUI ?
```
> gradle build
```
generate _"build/libs/jd-gui-x.y.z.jar"_
```
> gradle build installOsxDist
```
generate _"build/install/jd-gui-osx/JD-GUI.app"_

##How to launch JD-GUI ?
- Double-click on _"jd-gui-x.y.z.jar"_
- Double-click on _"JD-GUI"_ application under OSX
- Execute _"java -jar jd-gui-x.y.z.jar"_ or _"java -classpath jd-gui-x.y.z.jar jd.gui.App"_

##How to use JD-GUI ?
- Open a file with menu "File > Open File..."
- Open recent files with menu "File > Recent Files"
- Drag and drop files from your file explorer

##How to extend JD-GUI ?
```
> gradle idea
```
generate Idea Intellij project
```
> gradle eclipse
```
generate Eclipse project
```
> java -classpath jd-gui-x.y.z.jar;myextension1.jar;myextension2.jar jd.gui.App
```
launch JD-GUI with your extensions

##Uninstallation
- Delete "jd-gui-x.y.z.jar" and "jd-gui.cfg".
- Drag and drop "JD-GUI" application into the trash.
1 change: 1 addition & 0 deletions api/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
apply plugin: 'java'
48 changes: 48 additions & 0 deletions api/src/main/java/jd/gui/api/API.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api;

import jd.gui.api.feature.UriGettable;
import jd.gui.api.model.Container;
import jd.gui.api.model.Indexes;
import jd.gui.spi.*;

import javax.swing.*;
import java.io.File;
import java.net.URI;
import java.nio.file.FileSystem;
import java.util.Collection;
import java.util.Map;

public interface API {
public boolean openURI(URI uri);

public boolean openURI(int x, int y, Collection<Container.Entry> entries, String query, String fragment);

public void addURI(URI uri);

public <T extends JComponent & UriGettable> void addPanel(String title, Icon icon, String tip, T component);

public UriLoader getUriLoader(URI uri);

public FileLoader getFileLoader(File file);

public ContainerFactory getContainerFactory(FileSystem fileSystem);

public PanelFactory getMainPanelFactory(Container container);

public TreeNodeFactory getTreeNodeFactory(Container.Entry entry);

public TypeFactory getTypeFactory(Container.Entry entry);

public Indexer getIndexer(Container.Entry entry);

public SourceSaver getSourceSaver(Container.Entry entry);

public Map<String, String> getPreferences();

public Collection<Indexes> getCollectionOfIndexes();
}
12 changes: 12 additions & 0 deletions api/src/main/java/jd/gui/api/feature/ContainerEntryGettable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import jd.gui.api.model.Container;

public interface ContainerEntryGettable {
public Container.Entry getEntry();
}
10 changes: 10 additions & 0 deletions api/src/main/java/jd/gui/api/feature/ContentCopyable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

public interface ContentCopyable {
public void copy();
}
13 changes: 13 additions & 0 deletions api/src/main/java/jd/gui/api/feature/ContentIndexable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import jd.gui.api.API;
import jd.gui.api.model.Indexes;

public interface ContentIndexable {
public Indexes index(API api);
}
16 changes: 16 additions & 0 deletions api/src/main/java/jd/gui/api/feature/ContentSavable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import jd.gui.api.API;

import java.io.OutputStream;

public interface ContentSavable {
public String getFileName();

public void save(API api, OutputStream os);
}
14 changes: 14 additions & 0 deletions api/src/main/java/jd/gui/api/feature/ContentSearchable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

public interface ContentSearchable {
public boolean highlightText(String text, boolean caseSensitive);

public void findNext(String text, boolean caseSensitive);

public void findPrevious(String text, boolean caseSensitive);
}
10 changes: 10 additions & 0 deletions api/src/main/java/jd/gui/api/feature/ContentSelectable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

public interface ContentSelectable {
public void selectAll();
}
10 changes: 10 additions & 0 deletions api/src/main/java/jd/gui/api/feature/FocusedTypeGettable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

public interface FocusedTypeGettable extends ContainerEntryGettable {
public String getFocusedTypeName();
}
14 changes: 14 additions & 0 deletions api/src/main/java/jd/gui/api/feature/IndexesChangeListener.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import jd.gui.api.model.Indexes;

import java.util.Collection;

public interface IndexesChangeListener {
void indexesChanged(Collection<Indexes> collectionOfIndexes);
}
14 changes: 14 additions & 0 deletions api/src/main/java/jd/gui/api/feature/LineNumberNavigable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

public interface LineNumberNavigable {
public int getMaximumLineNumber();

public void goToLineNumber(int lineNumber);

public boolean checkLineNumber(int lineNumber);
}
12 changes: 12 additions & 0 deletions api/src/main/java/jd/gui/api/feature/PageChangeListener.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import javax.swing.*;

public interface PageChangeListener {
public <T extends JComponent & UriGettable> void pageChanged(T page);
}
10 changes: 10 additions & 0 deletions api/src/main/java/jd/gui/api/feature/PageChangeable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

public interface PageChangeable {
public void addPageChangeListener(PageChangeListener listener);
}
10 changes: 10 additions & 0 deletions api/src/main/java/jd/gui/api/feature/PageClosable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

public interface PageClosable {
public boolean closePage();
}
14 changes: 14 additions & 0 deletions api/src/main/java/jd/gui/api/feature/PageCreator.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import jd.gui.api.API;

import javax.swing.*;

public interface PageCreator {
public <T extends JComponent & UriGettable> T createPage(API api);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import java.util.Map;

public interface PreferencesChangeListener {
public void preferencesChanged(Map<String, String> preferences);
}
25 changes: 25 additions & 0 deletions api/src/main/java/jd/gui/api/feature/SourcesSavable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import jd.gui.api.API;
import java.nio.file.Path;

public interface SourcesSavable {
public String getSourceFileName();

public int getFileCount();

public void save(API api, Controller controller, Listener listener, Path path);

public interface Controller {
public boolean isCancelled();
};

public interface Listener {
public void pathSaved(Path path);
};
}
12 changes: 12 additions & 0 deletions api/src/main/java/jd/gui/api/feature/TreeNodeExpandable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import jd.gui.api.API;

public interface TreeNodeExpandable {
public void populateTreeNode(API api);
}
12 changes: 12 additions & 0 deletions api/src/main/java/jd/gui/api/feature/UriGettable.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/*
* Copyright (c) 2008-2015 Emmanuel Dupuy
* This program is made available under the terms of the GPLv3 License.
*/

package jd.gui.api.feature;

import java.net.URI;

public interface UriGettable {
public URI getUri();
}
Loading

0 comments on commit 44b26e9

Please sign in to comment.