Class ProjectElement

java.lang.Object
org.praxislive.project.ProjectElement
Direct Known Subclasses:
ProjectElement.File, ProjectElement.Line

public abstract sealed class ProjectElement extends Object permits ProjectElement.File, ProjectElement.Line
Elements of a project.
  • Constructor Details

    • ProjectElement

      public ProjectElement()
  • Method Details

    • file

      public static ProjectElement.File file(URI file)
      Create a file element wrapping the given file URI.
      Parameters:
      file - address of file
      Returns:
      file element
    • file

      public static ProjectElement.File file(Path file)
      Create a file element wrapping the URI of the given file path.
      Parameters:
      file - path of file
      Returns:
      file element
    • line

      public static ProjectElement.Line line(String script)
      Create a line element wrapping the given script line. The line must be a single line of script with a plain first token.
      Parameters:
      script - line of script
      Returns:
      line element
      Throws:
      IllegalArgumentException - if the line fails to parse according to the rules