code: @Override
    public void export(ITextNode[] nodes, String masterLanguage, String language, Status[] states)
        throws ExportException {
      LOG.info("Exporting JSON file...");
      SortedMap<String, String> props = getProperties(nodes, language, states);
      String jsonString = toJsonString(props);
      try (OutputStream outputStream = outputStreamFactory.createOutputStream(outputFile)) {
        outputStream.write(jsonString.getBytes(UTF_8));
      } catch (IOException e) {
        throw new ExportException("Could not write json:" + e.getMessage());
      }
      LOG.info("Exporting of JSON file finished.");
    }
docs: {@inheritDoc}
  Write the translation for the desired language and states into a JSON file in the format:
  <pre>
  {
  &lt;key&gt;: '&lt;value&gt;',
  ...
  }
  </pre>
  @param nodes the nodes to export
  @param masterLanguage the master language
  @param language the language to export
  @param states the states to export (all if null)
  @throws ExportException thrown if export fails