code: private synchronized Map<String, JsonObject> getAssetMap() throws IOException {
          if (!file.canRead()) {
              throw new IOException("Cannot read repository file: " + file.getAbsolutePath());
          } else if (assets == null || file.lastModified() != fileLastModified || file.length() != fileLastSize) {
              // Re-read the file if either we've never read it or it's changed length since we last read it
              assets = null;
              fileLastModified = file.lastModified();
              fileLastSize = file.length();
  
              idCounter = new AtomicInteger(1);
              assets = new HashMap<String, JsonObject>();
              try (JsonReader reader = Json.createReader(new FileInputStream(file))) {
                  JsonArray assetList = reader.readArray();
                  for (JsonValue val : assetList) {
                      String id = Integer.toString(idCounter.getAndIncrement());
                      if (val.getValueType() == ValueType.OBJECT) {
                          assets.put(id, (JsonObject) val);
                      }
                  }
              }
          }
  
          return assets;
  
      }
docs: Return a map from id to JsonObject representing an Asset
  <p>
  This method will re-read the json file if it has not yet been read, or if it has changed since we last read it.