File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
src/main/java/org/aarboard/nextcloud/api Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change 3939import org .aarboard .nextcloud .api .webdav .pathresolver .WebDavPathResolver ;
4040import org .aarboard .nextcloud .api .webdav .pathresolver .WebDavPathResolverBuilder ;
4141
42- public class NextcloudConnector {
42+ public class NextcloudConnector implements AutoCloseable {
4343
4444 private final ServerConfig serverConfig ;
4545 private final ProvisionConnector pc ;
@@ -188,6 +188,16 @@ public void shutdown() throws IOException {
188188 ConnectorCommon .shutdown ();
189189 }
190190
191+ /**
192+ * Close the HTTP client. Perform this to cleanly shut down this
193+ * application.
194+ *
195+ * @throws Exception In case of errors
196+ */
197+ public void close () throws Exception {
198+ shutdown ();
199+ }
200+
191201 /**
192202 * Trust all HTTPS certificates presented by the server. This is e.g. used
193203 * to work against a Nextcloud instance with a self-signed certificate.
You can’t perform that action at this time.
0 commit comments