فهرست منبع

Rename RevealerFacade to Revealer

Armin Schrenk 4 سال پیش
والد
کامیت
8977440697

+ 1 - 1
main/commons/src/main/java/org/cryptomator/common/vaults/DokanyVolume.java

@@ -52,7 +52,7 @@ public class DokanyVolume extends AbstractVolume {
 	}
 
 	@Override
-	public void reveal(RevealerFacade revealer) throws VolumeException {
+	public void reveal(Revealer revealer) throws VolumeException {
 		try {
 			mount.reveal(revealer::reveal);
 		} catch (Exception e) {

+ 1 - 1
main/commons/src/main/java/org/cryptomator/common/vaults/FuseVolume.java

@@ -72,7 +72,7 @@ public class FuseVolume extends AbstractVolume {
 	}
 
 	@Override
-	public void reveal(RevealerFacade revealer) throws VolumeException {
+	public void reveal(Revealer revealer) throws VolumeException {
 		try {
 			mount.reveal(revealer::reveal);
 		} catch (Exception e) {

+ 1 - 1
main/commons/src/main/java/org/cryptomator/common/vaults/Vault.java

@@ -148,7 +148,7 @@ public class Vault {
 		}
 	}
 
-	public void reveal(Volume.RevealerFacade vaultRevealer) throws VolumeException {
+	public void reveal(Volume.Revealer vaultRevealer) throws VolumeException {
 		volume.reveal(vaultRevealer);
 	}
 

+ 2 - 2
main/commons/src/main/java/org/cryptomator/common/vaults/Volume.java

@@ -42,7 +42,7 @@ public interface Volume {
 	 * @param revealer An object capable of revealing the location of the mounted vault to view the content (e.g. in the default file browser).
 	 * @throws VolumeException
 	 */
-	void reveal(RevealerFacade revealer) throws VolumeException;
+	void reveal(Revealer revealer) throws VolumeException;
 
 	void unmount() throws VolumeException;
 
@@ -91,7 +91,7 @@ public interface Volume {
 	 * Hides and unifies the different Revealer implementations in the different nio-adapters.
 	 */
 	@FunctionalInterface
-	interface RevealerFacade {
+	interface Revealer {
 
 		void reveal(Path p) throws VolumeException;
 

+ 1 - 1
main/commons/src/main/java/org/cryptomator/common/vaults/WebDavVolume.java

@@ -73,7 +73,7 @@ public class WebDavVolume implements Volume {
 	}
 
 	@Override
-	public void reveal(RevealerFacade revealer) throws VolumeException {
+	public void reveal(Revealer revealer) throws VolumeException {
 		try {
 			mount.reveal(revealer::reveal);
 		} catch (Exception e) {

+ 4 - 5
main/ui/src/main/java/org/cryptomator/ui/common/VaultService.java

@@ -15,7 +15,6 @@ import java.util.Iterator;
 import java.util.List;
 import java.util.concurrent.ExecutionException;
 import java.util.concurrent.ExecutorService;
-import java.util.concurrent.atomic.AtomicReference;
 import java.util.stream.Collectors;
 
 @FxApplicationScoped
@@ -30,7 +29,7 @@ public class VaultService {
 		this.executorService = executorService;
 	}
 
-	public void reveal(Vault vault, Volume.RevealerFacade vaultRevealCmd) {
+	public void reveal(Vault vault, Volume.Revealer vaultRevealCmd) {
 		executorService.execute(createRevealTask(vault, vaultRevealCmd));
 	}
 
@@ -39,7 +38,7 @@ public class VaultService {
 	 *
 	 * @param vault The vault to reveal
 	 */
-	public Task<Vault> createRevealTask(Vault vault, Volume.RevealerFacade vaultRevealCmd) {
+	public Task<Vault> createRevealTask(Vault vault, Volume.Revealer vaultRevealCmd) {
 		Task<Vault> task = new RevealVaultTask(vault, vaultRevealCmd);
 		task.setOnSucceeded(evt -> LOG.info("Revealed {}", vault.getDisplayName()));
 		task.setOnFailed(evt -> LOG.error("Failed to reveal " + vault.getDisplayName(), evt.getSource().getException()));
@@ -100,13 +99,13 @@ public class VaultService {
 	private static class RevealVaultTask extends Task<Vault> {
 
 		private final Vault vault;
-		private final Volume.RevealerFacade revealer;
+		private final Volume.Revealer revealer;
 
 		/**
 		 * @param vault The vault to lock
 		 * @param revealer The object to use to show the vault content to the user.
 		 */
-		public RevealVaultTask(Vault vault, Volume.RevealerFacade revealer) {
+		public RevealVaultTask(Vault vault, Volume.Revealer revealer) {
 			this.vault = vault;
 			this.revealer = revealer;
 

+ 2 - 2
main/ui/src/main/java/org/cryptomator/ui/traymenu/TrayMenuController.java

@@ -28,11 +28,11 @@ class TrayMenuController {
 	private final AppLifecycleListener appLifecycle;
 	private final FxApplicationStarter fxApplicationStarter;
 	private final ObservableList<Vault> vaults;
-	private final Volume.RevealerFacade revealer;
+	private final Volume.Revealer revealer;
 	private final PopupMenu menu;
 
 	@Inject
-	TrayMenuController(ResourceBundle resourceBundle, AppLifecycleListener appLifecycle, FxApplicationStarter fxApplicationStarter, ObservableList<Vault> vaults, Volume.RevealerFacade revealer) {
+	TrayMenuController(ResourceBundle resourceBundle, AppLifecycleListener appLifecycle, FxApplicationStarter fxApplicationStarter, ObservableList<Vault> vaults, Volume.Revealer revealer) {
 		this.resourceBundle = resourceBundle;
 		this.appLifecycle = appLifecycle;
 		this.fxApplicationStarter = fxApplicationStarter;

+ 1 - 1
main/ui/src/main/java/org/cryptomator/ui/traymenu/TrayMenuModule.java

@@ -11,7 +11,7 @@ import java.io.IOException;
 abstract class TrayMenuModule {
 
 	@Provides
-	static Volume.RevealerFacade provideAwtRevealer(){
+	static Volume.Revealer provideAwtRevealer(){
 		return p -> {
 			if (Desktop.isDesktopSupported() && Desktop.getDesktop().isSupported(Desktop.Action.OPEN)) {
 				try {