diff options
Diffstat (limited to 'jsonrpc')
-rw-r--r-- | jsonrpc/src/main/java/com/orbekk/same/ConnectionManager.java | 10 | ||||
-rw-r--r-- | jsonrpc/src/main/java/com/orbekk/same/ConnectionManagerImpl.java | 16 |
2 files changed, 26 insertions, 0 deletions
diff --git a/jsonrpc/src/main/java/com/orbekk/same/ConnectionManager.java b/jsonrpc/src/main/java/com/orbekk/same/ConnectionManager.java new file mode 100644 index 0000000..985f6f0 --- /dev/null +++ b/jsonrpc/src/main/java/com/orbekk/same/ConnectionManager.java @@ -0,0 +1,10 @@ +package com.orbekk.same; + +/** + * An interface that returns a connection for a participant. + * + * When testing, this interface can be mocked to use local participants only. + */ +public interface ConnectionManager { + SameService getConnection(String url); +} diff --git a/jsonrpc/src/main/java/com/orbekk/same/ConnectionManagerImpl.java b/jsonrpc/src/main/java/com/orbekk/same/ConnectionManagerImpl.java new file mode 100644 index 0000000..e3a6928 --- /dev/null +++ b/jsonrpc/src/main/java/com/orbekk/same/ConnectionManagerImpl.java @@ -0,0 +1,16 @@ +package com.orbekk.same; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +public class ConnectionManagerImpl { + private Logger logger = LoggerFactory.getLogger(getClass()); + + public ConnectionManagerImpl() { + } + + SameService getConnection(String url) { + // TODO: Implement this class. + return null; + } +} |