sruehl commented on code in PR #747:
URL: https://github.com/apache/plc4x/pull/747#discussion_r1072115260


##########
plc4j/api/src/main/java/org/apache/plc4x/java/api/PlcDriverManager.java:
##########
@@ -16,17 +16,25 @@
  * specific language governing permissions and limitations
  * under the License.
  */
-package org.apache.plc4x.java.utils.connectionpool2;
+package org.apache.plc4x.java.api;
 
-import org.apache.plc4x.java.api.PlcConnection;
+import org.apache.plc4x.java.DefaultPlcDriverManager;
 import org.apache.plc4x.java.api.exceptions.PlcConnectionException;
 
-/**
- * Simple Factory Method which creates a new PlcConnection
- */
-@FunctionalInterface
-public interface PlcConnectionFactory {
+import java.util.Set;
+
+public interface PlcDriverManager {
+
+    static PlcDriverManager getDefault() {
+        return new DefaultPlcDriverManager();
+    }
+
+    Set<String> listDrivers();
+
+    PlcDriver getDriver(String protocolCode) throws PlcConnectionException;
+
+    PlcDriver getDriverForUrl(String url) throws PlcConnectionException;
 
-    PlcConnection create() throws PlcConnectionException;

Review Comment:
   I wonder if we should leave the create method as deprecated default 
implementation:
   ```
   default PlcConnection create() {
       return getConnectionManager().create();
   }
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to