From e53602c98b492d3ad3b2fefab5c8fc63298ccf09 Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Thu, 25 May 2017 11:21:04 +0800 Subject: [PATCH] Remove useless singletons --- source/net/filebot/ui/rename/PhotoFileMatcher.java | 2 -- source/net/filebot/ui/rename/PlainFileMatcher.java | 2 -- source/net/filebot/ui/rename/Preset.java | 2 +- source/net/filebot/ui/rename/XattrFileMatcher.java | 2 -- 4 files changed, 1 insertion(+), 7 deletions(-) diff --git a/source/net/filebot/ui/rename/PhotoFileMatcher.java b/source/net/filebot/ui/rename/PhotoFileMatcher.java index 1a13aac1..76034744 100644 --- a/source/net/filebot/ui/rename/PhotoFileMatcher.java +++ b/source/net/filebot/ui/rename/PhotoFileMatcher.java @@ -20,8 +20,6 @@ import net.filebot.web.SortOrder; public class PhotoFileMatcher implements Datasource, AutoCompleteMatcher { - public static final PhotoFileMatcher INSTANCE = new PhotoFileMatcher(); - @Override public String getIdentifier() { return "exif"; diff --git a/source/net/filebot/ui/rename/PlainFileMatcher.java b/source/net/filebot/ui/rename/PlainFileMatcher.java index 4addf231..68ec530e 100644 --- a/source/net/filebot/ui/rename/PlainFileMatcher.java +++ b/source/net/filebot/ui/rename/PlainFileMatcher.java @@ -17,8 +17,6 @@ import net.filebot.web.SortOrder; public class PlainFileMatcher implements Datasource, AutoCompleteMatcher { - public static final PlainFileMatcher INSTANCE = new PlainFileMatcher(); - @Override public String getIdentifier() { return "file"; diff --git a/source/net/filebot/ui/rename/Preset.java b/source/net/filebot/ui/rename/Preset.java index 3f32613a..da9c416c 100644 --- a/source/net/filebot/ui/rename/Preset.java +++ b/source/net/filebot/ui/rename/Preset.java @@ -143,7 +143,7 @@ public class Preset { } public static Datasource[] getGenericFileMatcherServices() { - return new Datasource[] { PhotoFileMatcher.INSTANCE, XattrFileMatcher.INSTANCE, PlainFileMatcher.INSTANCE }; + return new Datasource[] { new PhotoFileMatcher(), new XattrFileMatcher(), new PlainFileMatcher() }; } public static StandardRenameAction[] getSupportedActions() { diff --git a/source/net/filebot/ui/rename/XattrFileMatcher.java b/source/net/filebot/ui/rename/XattrFileMatcher.java index 26c3edc4..dbb093bb 100644 --- a/source/net/filebot/ui/rename/XattrFileMatcher.java +++ b/source/net/filebot/ui/rename/XattrFileMatcher.java @@ -13,8 +13,6 @@ import net.filebot.web.SortOrder; public class XattrFileMatcher extends XattrMetaInfoProvider implements AutoCompleteMatcher { - public static final XattrFileMatcher INSTANCE = new XattrFileMatcher(); - @Override public List> match(Collection files, boolean strict, SortOrder order, Locale locale, boolean autodetection, Component parent) throws Exception { List> matches = new ArrayList>();