Permalink
Browse files

Formatting: Disallow whitespaces.

- Replaced leading 4-wide whitespaces with tabs.
- Removed/replaced remaining leading whitespaces to maintain consistency.
- Added *'s to multiline docs where they were missing.
  • Loading branch information...
Pieter12345 committed Apr 30, 2018
1 parent d74d315 commit 232db3a2ac594d2c879925a371a327b448684f16
Showing with 4,048 additions and 4,052 deletions.
  1. +1,133 −1,133 src/main/java/com/laytonsmith/PureUtilities/ArgumentParser.java
  2. +602 −602 src/main/java/com/laytonsmith/PureUtilities/ClassLoading/ClassMirror/ClassMirror.java
  3. +4 −4 src/main/java/com/laytonsmith/PureUtilities/Color.java
  4. +10 −10 src/main/java/com/laytonsmith/PureUtilities/Common/FileUtil.java
  5. +28 −28 src/main/java/com/laytonsmith/PureUtilities/ConcurrentSingletonHashMap.java
  6. +15 −15 src/main/java/com/laytonsmith/PureUtilities/ExhaustiveVisitor.java
  7. +6 −6 src/main/java/com/laytonsmith/PureUtilities/PropertiesManager.java
  8. +4 −4 src/main/java/com/laytonsmith/PureUtilities/TermColors.java
  9. +62 −62 src/main/java/com/laytonsmith/PureUtilities/UI/TextDialog.java
  10. +38 −38 src/main/java/com/laytonsmith/PureUtilities/VirtualFS/FileSystemLayer.java
  11. +2 −2 src/main/java/com/laytonsmith/PureUtilities/ZipReader.java
  12. +2 −2 src/main/java/com/laytonsmith/PureUtilities/rParser.java
  13. +1 −1 src/main/java/com/laytonsmith/abstraction/MCInventoryHolder.java
  14. +99 −99 src/main/java/com/laytonsmith/abstraction/MCItemMeta.java
  15. +25 −25 src/main/java/com/laytonsmith/abstraction/bukkit/BukkitConvertor.java
  16. +143 −143 src/main/java/com/laytonsmith/commandhelper/BukkitDirtyRegisteredListener.java
  17. +10 −10 src/main/java/com/laytonsmith/core/CoreProfile.java
  18. +4 −4 src/main/java/com/laytonsmith/core/GenericTree.java
  19. +2 −2 src/main/java/com/laytonsmith/core/GenericTreeNode.java
  20. +2 −2 src/main/java/com/laytonsmith/core/GenericTreeTraversalOrderEnum.java
  21. +1 −1 src/main/java/com/laytonsmith/core/MethodScriptCompiler.java
  22. +1 −1 src/main/java/com/laytonsmith/core/compiler/FileOptions.java
  23. +18 −18 src/main/java/com/laytonsmith/core/constructs/CSymbol.java
  24. +9 −9 src/main/java/com/laytonsmith/core/constructs/Token.java
  25. +4 −4 src/main/java/com/laytonsmith/core/events/AbstractEvent.java
  26. +20 −20 src/main/java/com/laytonsmith/core/events/BoundEvent.java
  27. +3 −3 src/main/java/com/laytonsmith/core/events/EventBuilder.java
  28. +6 −6 src/main/java/com/laytonsmith/core/exceptions/ConfigRuntimeException.java
  29. +11 −11 src/main/java/com/laytonsmith/core/functions/DataHandling.java
  30. +337 −337 src/main/java/com/laytonsmith/core/functions/Debug.java
  31. +31 −31 src/main/java/com/laytonsmith/core/functions/Enchantments.java
  32. +4 −4 src/main/java/com/laytonsmith/core/functions/EventBinding.java
  33. +45 −45 src/main/java/com/laytonsmith/core/functions/InventoryManagement.java
  34. +4 −4 src/main/java/com/laytonsmith/core/functions/Regex.java
  35. +68 −68 src/main/java/com/laytonsmith/tools/UILauncher.java
  36. +184 −184 src/main/java/com/laytonsmith/tools/docgen/DocGenUI.java
  37. +55 −55 src/main/java/com/laytonsmith/tools/docgen/SingleFunctionDialog.java
  38. +9 −9 src/main/java/com/laytonsmith/tools/docgen/sitedeploy/SiteDeploy.java
  39. +148 −148 src/main/java/com/laytonsmith/tools/pnviewer/ConfigurationLoaderDialog.java
  40. +159 −159 src/main/java/com/laytonsmith/tools/pnviewer/ManageBookmarksDialog.java
  41. +238 −238 src/main/java/com/laytonsmith/tools/pnviewer/PNViewer.java
  42. +5 −7 src/test/java/com/laytonsmith/PureUtilities/ClassLoading/GeneralTest.java
  43. +9 −9 src/test/java/com/laytonsmith/PureUtilities/ZipMakerTest.java
  44. +6 −6 src/test/java/com/laytonsmith/PureUtilities/ZipReaderTest.java
  45. +104 −104 src/test/java/com/laytonsmith/core/MethodScriptCompilerTest.java
  46. +1 −1 src/test/java/com/laytonsmith/core/NewExceptionHandlingTest.java
  47. +36 −36 src/test/java/com/laytonsmith/core/OptimizationTest.java
  48. +87 −87 src/test/java/com/laytonsmith/core/ScriptTest.java
  49. +27 −27 src/test/java/com/laytonsmith/core/TypeHintingTest.java
  50. +38 −38 src/test/java/com/laytonsmith/core/events/GeneralTest.java
  51. +15 −15 src/test/java/com/laytonsmith/core/functions/BasicLogicTest.java
  52. +10 −10 src/test/java/com/laytonsmith/core/functions/DataHandlingTest.java
  53. +11 −11 src/test/java/com/laytonsmith/core/functions/EchoesTest.java
  54. +17 −17 src/test/java/com/laytonsmith/core/functions/MinecraftTest.java
  55. +56 −56 src/test/java/com/laytonsmith/core/functions/PermissionsTest.java
  56. +31 −31 src/test/java/com/laytonsmith/core/functions/PlayerManangementTest.java
  57. +11 −11 src/test/java/com/laytonsmith/core/functions/bash/BashCompilerBasicTest.java
  58. +4 −4 src/test/java/com/laytonsmith/persistence/TestPersistence.java
  59. +2 −2 src/test/java/com/laytonsmith/testing/ArrayTest.java
  60. +6 −6 src/test/java/com/laytonsmith/testing/RandomTests.java
  61. +25 −27 src/test/java/com/laytonsmith/testing/StaticTest.java

Large diffs are not rendered by default.

Oops, something went wrong.

Large diffs are not rendered by default.

Oops, something went wrong.
@@ -118,7 +118,7 @@
private float falpha = 0.0f;
/*
* JDK 1.1 serialVersionUID
* JDK 1.1 serialVersionUID
*/
private static final long serialVersionUID = 118526816881161077L;
@@ -403,9 +403,9 @@ public Color brighter() {
int alpha = getAlpha();
/* From 2D group:
* 1. black.brighter() should return grey
* 2. applying brighter to blue will always return blue, brighter
* 3. non pure color (non zero rgb) will eventually return white
* 1. black.brighter() should return grey
* 2. applying brighter to blue will always return blue, brighter
* 3. non pure color (non zero rgb) will eventually return white
*/
int i = (int) (1.0 / (1.0 - FACTOR));
if(r == 0 && g == 0 && b == 0) {
@@ -118,14 +118,14 @@ public static InputStream readAsStream(File file) throws IOException {
// } finally {
// freeLock(file);
// }
// FileInputStream fis = new FileInputStream(f);
// try{
// FileInputStream fis = new FileInputStream(f);
// try{
// return StreamUtils.GetString(fis, charset);
// } finally {
// fis.close();
// fis = null;
// System.gc();
// }
// } finally {
// fis.close();
// fis = null;
// System.gc();
// }
}
/**
@@ -221,9 +221,9 @@ public static void write(byte[] data, File file, int mode, boolean create) throw
// } finally {
// freeLock(file);
// }
// FileWriter fw = new FileWriter(f, append);
// fw.write(s);
// fw.close();
// FileWriter fw = new FileWriter(f, append);
// fw.write(s);
// fw.close();
}
/**
@@ -21,34 +21,34 @@
public class ConcurrentSingletonHashMap<T, V> implements Map<T, V> {
/*
* You might notice that no fields in this class are volatile. Normally, when you double lock, you must do
* something like this to be totally correct:
*
* <pre>
* volatile Object value = null; // Note the volatility
* construct() {
* Object result = value;
* if(result == null) {
* synchronized(result) {
* if(result == null) {
* result = new Object();
* value = result;
* }
* }
* }
* return result;
* }
* </pre>
*
* Note that we are doing the double locking per usual, but the value is volatile. The local result value seems
* unnecessary at first, but the effect of this is that in cases where value is already initialized
* (i.e., most of the time), the volatile field is only accessed once (due to "return result;" instead of
* "return value;"), which can improve the method's overall performance by as much as 25 percent.
*
* However, in the case that we have before us, the ConcurrentHashMap handles this for us, by guaranteeing that
* we never get a value that is partially constructed in the get() method.
*
*
* You might notice that no fields in this class are volatile. Normally, when you double lock, you must do
* something like this to be totally correct:
*
* <pre>
* volatile Object value = null; // Note the volatility
* construct() {
* Object result = value;
* if(result == null) {
* synchronized(result) {
* if(result == null) {
* result = new Object();
* value = result;
* }
* }
* }
* return result;
* }
* </pre>
*
* Note that we are doing the double locking per usual, but the value is volatile. The local result value seems
* unnecessary at first, but the effect of this is that in cases where value is already initialized
* (i.e., most of the time), the volatile field is only accessed once (due to "return result;" instead of
* "return value;"), which can improve the method's overall performance by as much as 25 percent.
*
* However, in the case that we have before us, the ConcurrentHashMap handles this for us, by guaranteeing that
* we never get a value that is partially constructed in the get() method.
*
*
*/
private final Map<T, V> map = new ConcurrentHashMap<>();
private final ValueGenerator<T, V> generator;
@@ -56,20 +56,20 @@
* public static class PhoneNumber implements UserID {
* {@code @Override}
* public void accept(UserIDVisitor visitor) {
* visitor.handle(this);
* visitor.handle(this);
* }
* }
* public static abstract class GeneratedID implements UserID {}
* public static class GeneratedIDV1 extends GeneratedID {
* {@code @Override}
* public void accept(UserIDVisitor visitor) {
* visitor.handle(this);
* visitor.handle(this);
* }
* }
* public static class GeneratedIDV2 extends GeneratedID {
* {@code @Override}
* public void accept(UserIDVisitor visitor) {
* visitor.handle(this);
* visitor.handle(this);
* }
* }
*
@@ -78,17 +78,17 @@
*
* {@code @Override}
* public void handle(PhoneNumber m) {
* System.out.println("Canadian PhoneNumber");
* System.out.println("Canadian PhoneNumber");
* }
*
* {@code @Override}
* public void handle(GeneratedIDV1 c) {
* System.out.println("Canadian GeneratedIDV1");
* System.out.println("Canadian GeneratedIDV1");
* }
*
* {@code @Override}
* public void handle(GeneratedIDV2 c) {
* System.out.println("Canadian GeneratedIDV2");
* System.out.println("Canadian GeneratedIDV2");
* }
*
* }
@@ -97,17 +97,17 @@
*
* {@code @Override}
* public void handle(PhoneNumber m) {
* System.out.println("American PhoneNumber");
* System.out.println("American PhoneNumber");
* }
*
* {@code @Override}
* public void handle(GeneratedIDV1 c) {
* System.out.println("American GeneratedIDV1");
* System.out.println("American GeneratedIDV1");
* }
*
* {@code @Override}
* public void handle(GeneratedIDV2 c) {
* System.out.println("American GeneratedIDV2");
* System.out.println("American GeneratedIDV2");
* }
*
* }
@@ -141,30 +141,30 @@
* {@code @ExhaustiveVisitor.VisitorInfo(baseClass = UserID.class, directSubclassOnly = false)}
* public static class CanadianVisitor extends ExhaustiveVisitor<UserID> {
* public void visit(PhoneNumber n) {
* System.out.println("Canadian PhoneNumber");
* System.out.println("Canadian PhoneNumber");
* }
*
* public void visit(GeneratedIDV1 id) {
* System.out.println("Canadian GeneratedIDV1");
* System.out.println("Canadian GeneratedIDV1");
* }
*
* public void visit(GeneratedIDV2 id) {
* System.out.println("Canadian GeneratedIDV1");
* System.out.println("Canadian GeneratedIDV1");
* }
* }
*
* {@code @ExhaustiveVisitor.VisitorInfo(baseClass = UserID.class, directSubclassOnly = false)}
* public static class AmericanVisitor extends ExhaustiveVisitor<UserID> {
* public void visit(PhoneNumber n) {
* System.out.println("American PhoneNumber");
* System.out.println("American PhoneNumber");
* }
*
* public void visit(GeneratedIDV1 id) {
* System.out.println("American GeneratedIDV1");
* System.out.println("American GeneratedIDV1");
* }
*
* public void visit(GeneratedIDV2 id) {
* System.out.println("American GeneratedIDV1");
* System.out.println("American GeneratedIDV1");
* }
* }
*
@@ -185,10 +185,10 @@ private void load(LineReader lr) throws IOException {
}
/* Read in a "logical line" from an InputStream/Reader, skip all comment
* and blank lines and filter out those leading whitespace characters
* (\u0020, \u0009 and \u000c) from the beginning of a "natural line".
* Method returns the char length of the "logical line" and stores
* the line in "lineBuf".
* and blank lines and filter out those leading whitespace characters
* (\u0020, \u0009 and \u000c) from the beginning of a "natural line".
* Method returns the char length of the "logical line" and stores
* the line in "lineBuf".
*/
class LineReader {
@@ -317,8 +317,8 @@ int readLine() throws IOException {
}
/*
* Converts encoded &#92;uxxxx to unicode chars
* and changes special saved chars to their original forms
* Converts encoded &#92;uxxxx to unicode chars
* and changes special saved chars to their original forms
*/
private String loadConvert(char[] in, int off, int len, char[] convtBuf) {
if(convtBuf.length < len) {
@@ -57,7 +57,7 @@ public static void cls() {
}
/*
* Standard foreground colors
* Standard foreground colors
*/
@color
public static String RED = color(Color.RED);
@@ -77,7 +77,7 @@ public static void cls() {
public static String WHITE = color(Color.WHITE);
/*
* Bright foreground colors
* Bright foreground colors
*/
@color
public static String BRIGHT_RED = color(Color.RED, true, true, true);
@@ -97,7 +97,7 @@ public static void cls() {
public static String BRIGHT_WHITE = color(Color.WHITE, true, true, true);
/*
* Standard background colors
* Standard background colors
*/
@color
public static String BG_RED = color(Color.RED, false, false, false);
@@ -117,7 +117,7 @@ public static void cls() {
public static String BG_WHITE = color(Color.WHITE, false, false, false);
/*
* Bright background colors
* Bright background colors
*/
@color
public static String BG_BRIGHT_RED = color(Color.RED, true, false, false);
Oops, something went wrong.

0 comments on commit 232db3a

Please sign in to comment.