code: private void setNameSpaceID(File storage, String nsid)
        throws InconsistentFSStateException {
      if (nsid == null || nsid.equals("")) {
        throw new InconsistentFSStateException(storage, "file "
            + STORAGE_FILE_VERSION + " is invalid.");
      }
      int newNsId = Integer.parseInt(nsid);
      if (namespaceID > 0 && namespaceID != newNsId) {
        throw new InconsistentFSStateException(storage,
            "Unexepcted namespaceID " + nsid + " . Expected " + namespaceID);
      }
      namespaceID = newNsId;
    }
docs: Validate and set namespace ID