code: private void createSnapshot(final String name, final List<String> types) throws FrameworkException {
  
  		// we want to create a sorted, human-readble, diffable representation of the schema
  		final App app = StructrApp.getInstance();
  
  		// isolate write output
  		try (final Tx tx = app.tx()) {
  
  			final File snapshotFile = locateFile(name, true);
  			try (final Writer writer = new FileWriter(snapshotFile)) {
  
  				final JsonSchema schema = StructrSchema.createFromDatabase(app, types);
  
  				writer.append(schema.toString());
  				writer.append("\n");    // useful newline
  
  				writer.flush();
  			}
  
  			tx.success();
  
  		} catch (IOException | URISyntaxException ioex) {
  			logger.warn("", ioex);
  		}
  	}
docs: ----- private methods -----