summaryrefslogtreecommitdiff
path: root/MyLock.java
diff options
Diffstat (limited to 'MyLock.java')
-rw-r--r--MyLock.java23
1 files changed, 12 insertions, 11 deletions
diff --git a/MyLock.java b/MyLock.java
index b64878d..934971f 100644
--- a/MyLock.java
+++ b/MyLock.java
@@ -1,31 +1,31 @@
-/*
+/*
* MyLock.java - lock management for multiuser sessions
- *
+ *
* Copyright (c) 2025 Stefano Marchetti
- *
+ *
* This file is part of Jedecma - breast ultrasound examinations archiving software
- *
+ *
* Jedecma is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
- *
+ *
* Jedecma is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with Jedecma. If not, see <http://www.gnu.org/licenses/>.
- *
+ *
*/
/*
* Nota bene: nata per l'uso multiutente, e' comunque operativa anche in monoutenza.
* Si tratta di una gestione rudimentale basata su registrazioni
* su una tabella apposita del database.
- * *** Non e' mai stata testata in un contesto d'uso reale. ***
- * In caso di interruzione della sessione, i lock restano attivi e vanno
+ * *** Non e' mai stata testata in un contesto d'uso reale. ***
+ * In caso di interruzione della sessione, i lock restano attivi e vanno
* eliminati riavviando e terminando immediatamente il programma con lo
* stesso utente.
*/
@@ -34,13 +34,14 @@
* Notice: designed for a multiuser mode, is used even in single user mode.
* It is a rudimentary system based on records on a dedicated database table.
* *** Never tested in real use ***
- * In case of incorrect termination of the session, locks are left active:
+ * In case of incorrect termination of the session, locks are left active:
* to erase them restart the program with same user and terminate it immediately.
*/
package jedecma;
-import java.sql.*;
+import java.sql.ResultSet;
+import java.sql.SQLException;
public class MyLock {
final static boolean EXCL = true;