code: int unlock(final DeviceProxy deviceProxy) throws DevFailed {
          deviceProxy.import_admin_device("unlock");
          final DevVarLongStringArray lsa = new DevVarLongStringArray();
          lsa.svalue = new String[1];
          lsa.lvalue = new int[1];
          lsa.svalue[0] = deviceProxy.get_name();
          lsa.lvalue[0] = 0; // Do not force
          final DeviceData argin = new DeviceData();
          argin.insert(lsa);
          final DeviceData argout = deviceProxy.getAdm_dev().command_inout("UnlockDevice", argin);
          // Check lock counter for the device itself (not the proxy)
          final int nb = argout.extractLong();
          if (nb == 0) {
              removeToRelockList(deviceProxy);
          }
          return nb;
      }
docs: ==========================================================================