Packages

case class CmdScript(name: String = "cmd", description: Option[String] = None, winCmd: Option[String] = None, linuxCmd: Option[String] = None) extends CmdScriptBase with Product with Serializable

Execute a command on the command line and get its std output Command can be different for windows and linux operating systems, but it must be defined for at least one of them.

If return value is not zero an exception is thrown.

Note about internal implementation: on execution value of parameter map entries where key starts with - 'param' will be added as parameter after the docker run command, sorted by key. This allows to customize execution behaviour through Actions or DataObjects using CmdScript.

name

name of the transformer

description

Optional description of the transformer

winCmd

Cmd to execute on windows operating systems - note that it is executed with "cmd /C" prefixed

linuxCmd

Cmd to execute on linux operating systems - note that it is executed with "sh -c" prefixed.

Annotations
@Scaladoc()
Linear Supertypes
Serializable, Serializable, Product, Equals, CmdScriptBase, SmartDataLakeLogger, ParsableScriptDef, ParsableFromConfig[ParsableScriptDef], ScriptDef, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CmdScript
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. CmdScriptBase
  7. SmartDataLakeLogger
  8. ParsableScriptDef
  9. ParsableFromConfig
  10. ScriptDef
  11. AnyRef
  12. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new CmdScript(name: String = "cmd", description: Option[String] = None, winCmd: Option[String] = None, linuxCmd: Option[String] = None)

    name

    name of the transformer

    description

    Optional description of the transformer

    winCmd

    Cmd to execute on windows operating systems - note that it is executed with "cmd /C" prefixed

    linuxCmd

    Cmd to execute on linux operating systems - note that it is executed with "sh -c" prefixed.

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @HotSpotIntrinsicCandidate()
  6. val description: Option[String]
    Definition Classes
    CmdScriptScriptDef
  7. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  8. def execStdOutStream(configObjectId: ConfigObjectId, partitionValues: Seq[PartitionValues], parameters: Map[String, String], errors: Buffer[String] = mutable.Buffer())(implicit context: ActionPipelineContext): Stream[String]

    Function to be implemented to execute command and return stdout as Stream of lines.

    Function to be implemented to execute command and return stdout as Stream of lines.

    configObjectId

    id of the action which executes this transformation. This is mainly used to prefix error messages.

    partitionValues

    partition values to transform

    parameters

    key-value parameters

    errors

    an optional Buffer to collect stdErr messages

    returns

    standard output of script as Stream of lines

    Definition Classes
    CmdScriptBaseScriptDef
  9. def execStdOutString(configObjectId: ConfigObjectId, partitionValues: Seq[PartitionValues], parameters: Map[String, String], errors: Buffer[String] = mutable.Buffer())(implicit context: ActionPipelineContext): String

    Function to be implemented to execute command and return stdout as String.

    Function to be implemented to execute command and return stdout as String.

    configObjectId

    id of the action or dataobject which executes this transformation. This is mainly used to prefix error messages.

    partitionValues

    partition values to transform

    parameters

    key-value parameters

    errors

    an optional Buffer to collect stdErr messages

    returns

    standard output of script as String

    Definition Classes
    CmdScriptBaseScriptDef
  10. def factory: FromConfigFactory[ParsableScriptDef]

    Returns the factory that can parse this type (that is, type CO).

    Returns the factory that can parse this type (that is, type CO).

    Typically, implementations of this method should return the companion object of the implementing class. The companion object in turn should implement FromConfigFactory.

    returns

    the factory (object) for this class.

    Definition Classes
    CmdScript → ParsableFromConfig
  11. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  12. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  13. val linuxCmd: Option[String]
  14. lazy val logger: Logger
    Attributes
    protected
    Definition Classes
    SmartDataLakeLogger
    Annotations
    @transient()
  15. val name: String
    Definition Classes
    CmdScriptScriptDef
  16. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  17. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  18. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  19. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  20. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  21. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  22. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. val winCmd: Option[String]

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] ) @Deprecated
    Deprecated

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from CmdScriptBase

Inherited from SmartDataLakeLogger

Inherited from ParsableScriptDef

Inherited from ParsableFromConfig[ParsableScriptDef]

Inherited from ScriptDef

Inherited from AnyRef

Inherited from Any

Ungrouped