Package

scala.tools

cmd

Permalink

package cmd

Source
package.scala
Linear Supertypes
Content Hierarchy
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. cmd
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. class CommandLine extends CommandLineConfig

    Permalink

    An instance of a command line, parsed according to a Spec.

  2. trait CommandLineConfig extends AnyRef

    Permalink
  3. abstract class FromString[+T] extends PartialFunction[String, T]

    Permalink

    A general mechanism for defining how a command line argument (always a String) is transformed into an arbitrary type.

    A general mechanism for defining how a command line argument (always a String) is transformed into an arbitrary type. A few example instances are in the companion object, but in general either IntFromString will suffice or you'll want custom transformers.

  4. trait Instance extends Spec

    Permalink

    The trait mixed into each instance of a specification.

    The trait mixed into each instance of a specification.

    See also

    Reference

  5. trait Interpolation extends AnyRef

    Permalink

    Interpolation logic for generated files.

    Interpolation logic for generated files. The idea is to be able to write in terms of @@THIS@@ and @@THAT@@ and the reference specification knows enough to perform the substitutions. Warrants expansion.

  6. trait Property extends Reference

    Permalink
  7. class PropertyMapper extends ((String, String)) ⇒ List[String]

    Permalink

    Contains logic for translating a property key/value pair into equivalent command line arguments.

    Contains logic for translating a property key/value pair into equivalent command line arguments. The default settings will translate, given programInfo.runner == "foo" :

    foo.bar=true to --bar // if --bar is unary foo.bar=quux to --bar quux // if --bar is binary

  8. trait Reference extends Spec

    Permalink

    Mixes in the specification trait and uses the vals therein to side-effect private accumulators.

    Mixes in the specification trait and uses the vals therein to side-effect private accumulators. From this emerges formatted help, lists of unary and binary arguments, an apply which can creates instances of the specification, and etc.

    See also

    Instance

  9. trait Spec extends AnyRef

    Permalink

    This trait works together with others in scala.tools.cmd to allow declaratively specifying a command line program, with many attendant benefits.

    This trait works together with others in scala.tools.cmd to allow declaratively specifying a command line program, with many attendant benefits. See scala.tools.cmd.DemoSpec for an example.

Value Members

  1. object CommandLineParser

    Permalink

    A simple (overly so) command line parser.

    A simple (overly so) command line parser. !!! This needs a thorough test suite to make sure quoting is done correctly and portably.

  2. object FromString

    Permalink
  3. object Interpolation

    Permalink
  4. object Meta

    Permalink

    Meta-options for command line tools.

    Meta-options for command line tools. We could have all kinds of additional goodness here, but for now it's completion and script generation. See Demo for example usage.

  5. object Opt

    Permalink

    Machinery for what amounts to a command line specification DSL.

    Machinery for what amounts to a command line specification DSL. It is designed so the same specification trait can be used for two different purposes: generating a singleton specification object (trait Reference) and providing well typed vals for every configurable option in response to any given set of arguments (trait Instance).

  6. object Reference

    Permalink
  7. object Spec

    Permalink
  8. def fromArgs(args: List[String]): String

    Permalink
  9. def fromOpt(s: String): String

    Permalink
  10. package gen

    Permalink
  11. implicit def implicitConversions: implicitConversions

    Permalink
  12. implicit def postfixOps: postfixOps

    Permalink
  13. def returning[T](x: T)(f: (T) ⇒ Unit): T

    Permalink
  14. def runAndExit(body: ⇒ Unit): Nothing

    Permalink
  15. def stripQuotes(s: String): String

    Permalink
  16. def toArgs(line: String): List[String]

    Permalink
  17. def toOpt(s: String): String

    Permalink

Inherited from AnyRef

Inherited from Any

Ungrouped