code: public static void dumpStoreDefsToFile(String outputDirName,
                                             String fileName,
                                             List<StoreDefinition> storeDefs) {
  
          if(outputDirName != null) {
              File outputDir = new File(outputDirName);
              if(!outputDir.exists()) {
                  Utils.mkdirs(outputDir);
              }
  
              try {
                  FileUtils.writeStringToFile(new File(outputDirName, fileName),
                                              new StoreDefinitionsMapper().writeStoreList(storeDefs));
              } catch(IOException e) {
                  logger.error("IOException during dumpStoreDefsToFile: " + e);
              }
          }
      }
docs: Prints a stores xml to a file.
  
  @param outputDirName
  @param fileName
  @param list of storeDefs