Moved to Java 8. Code cleanup.
[meviz.git] / src / main / java / eu / svjatoslav / meviz / encoder / Encoder.java
index fda023e..2c5d088 100755 (executable)
@@ -19,20 +19,17 @@ import java.util.List;
 
 public class Encoder implements Module {
 
-    public FormatsRegistry encoderRegistry = new FormatsRegistry();
-
-    public EncodingOptions encodingOptions;
-
-    public EncodingPlan encodingPlan;
-
-    CommandlineHandler commandlineHandler = new CommandlineHandler();
+    private final FormatsRegistry encoderRegistry = new FormatsRegistry();
+    private final CommandlineHandler commandlineHandler = new CommandlineHandler();
+    private EncodingOptions encodingOptions;
+    private EncodingPlan encodingPlan;
 
     /**
      * Generate encoding plan
      *
      * @param sourceFile Source directory of file
      */
-    public void compileEncodingPlan(final File sourceFile) {
+    private void compileEncodingPlan(final File sourceFile) {
         if (!sourceFile.exists()) {
             System.out.println("Error: file \"" + sourceFile.getAbsolutePath()
                     + "\" does not exist.");
@@ -106,7 +103,7 @@ public class Encoder implements Module {
      * @param file single file candidate to potentially be encoded
      * @return <code>true</code> if file shall be encoded.
      */
-    public boolean fileMatchesInputPattern(final File file) {
+    private boolean fileMatchesInputPattern(final File file) {
         final String fileName = file.getName().toLowerCase();
 
         for (final String inputPattern : encodingOptions.getInputPatterns())