Class Utils

java.lang.Object
org.drools.drlonyaml.cli.utils.Utils

public class Utils extends Object
  • Method Details

    • conventionInputStream

      public static InputStream conventionInputStream(File inputFile) throws FileNotFoundException
      Returns an InputStream reading the file content when provided as a parameter, otherwise from STDIN until `\\A` when null.
      Throws:
      FileNotFoundException
    • conventionOutputConsumer

      public static Consumer<String> conventionOutputConsumer(File archive)
      Returns an Consumer which writes content to the file when provided as a parameter, otherwise consumer emits to STDOUT when null.