packages feed

hydra-build-0.17.5: src/main/haskell/Hydra/Dsl/Build/Assembly.hs

-- Note: this is an automatically generated file. Do not edit.

-- | DSL functions for hydra.build.assembly

module Hydra.Dsl.Build.Assembly where

import qualified Hydra.Build.Assembly as Assembly
import qualified Hydra.Core as Core
import qualified Hydra.Decode.Build.Assembly as DecodeBuildAssembly
import qualified Hydra.Encode.Build.Assembly as EncodeBuildAssembly
import qualified Hydra.Typed as Typed
import Prelude hiding  (Enum, Ordering, decodeFloat, encodeFloat, fail, lines, map, pure, sum, unlines)
import qualified Data.Scientific as Sci

-- | DSL constructor for hydra.build.assembly.AssemblyEntry
assemblyEntry :: Typed.TypedTerm String -> Typed.TypedTerm String -> Typed.TypedTerm Assembly.AssemblyEntryKind -> Typed.TypedTerm [String] -> Typed.TypedTerm Assembly.AssemblyEntry
assemblyEntry sourceTree destTree kind exclude =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceTree"),
          Core.fieldTerm = (Typed.unTypedTerm sourceTree)},
        Core.Field {
          Core.fieldName = (Core.Name "destTree"),
          Core.fieldTerm = (Typed.unTypedTerm destTree)},
        Core.Field {
          Core.fieldName = (Core.Name "kind"),
          Core.fieldTerm = (Typed.unTypedTerm kind)},
        Core.Field {
          Core.fieldName = (Core.Name "exclude"),
          Core.fieldTerm = (Typed.unTypedTerm exclude)}]}))

-- | DSL name token for hydra.build.assembly.AssemblyEntry
assemblyEntryAssemblyEntry :: Typed.TypedName Assembly.AssemblyEntry
assemblyEntryAssemblyEntry = Typed.TypedName (Core.Name "hydra.build.assembly.AssemblyEntry")

-- | DSL accessor for the destTree field of hydra.build.assembly.AssemblyEntry
assemblyEntryDestTree :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm String
assemblyEntryDestTree x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
        Core.projectionFieldName = (Core.Name "destTree")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the exclude field of hydra.build.assembly.AssemblyEntry
assemblyEntryExclude :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm [String]
assemblyEntryExclude x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
        Core.projectionFieldName = (Core.Name "exclude")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the kind field of hydra.build.assembly.AssemblyEntry
assemblyEntryKind :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm Assembly.AssemblyEntryKind
assemblyEntryKind x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
        Core.projectionFieldName = (Core.Name "kind")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL name token for hydra.build.assembly.AssemblyEntryKind
assemblyEntryKindAssemblyEntryKind :: Typed.TypedName Assembly.AssemblyEntryKind
assemblyEntryKindAssemblyEntryKind = Typed.TypedName (Core.Name "hydra.build.assembly.AssemblyEntryKind")

-- | DSL injection for the merge variant of hydra.build.assembly.AssemblyEntryKind
assemblyEntryKindMerge :: Typed.TypedTerm Assembly.AssemblyEntryKind
assemblyEntryKindMerge =
    Typed.TypedTerm (Core.TermInject (Core.Injection {
      Core.injectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntryKind"),
      Core.injectionField = Core.Field {
        Core.fieldName = (Core.Name "merge"),
        Core.fieldTerm = Core.TermUnit}}))

-- | DSL injection for the symlinkDir variant of hydra.build.assembly.AssemblyEntryKind
assemblyEntryKindSymlinkDir :: Typed.TypedTerm Assembly.AssemblyEntryKind
assemblyEntryKindSymlinkDir =
    Typed.TypedTerm (Core.TermInject (Core.Injection {
      Core.injectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntryKind"),
      Core.injectionField = Core.Field {
        Core.fieldName = (Core.Name "symlinkDir"),
        Core.fieldTerm = Core.TermUnit}}))

-- | DSL injection for the symlinkTree variant of hydra.build.assembly.AssemblyEntryKind
assemblyEntryKindSymlinkTree :: Typed.TypedTerm Assembly.AssemblyEntryKind
assemblyEntryKindSymlinkTree =
    Typed.TypedTerm (Core.TermInject (Core.Injection {
      Core.injectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntryKind"),
      Core.injectionField = Core.Field {
        Core.fieldName = (Core.Name "symlinkTree"),
        Core.fieldTerm = Core.TermUnit}}))

-- | DSL injection for the wipeThenCopy variant of hydra.build.assembly.AssemblyEntryKind
assemblyEntryKindWipeThenCopy :: Typed.TypedTerm Assembly.AssemblyEntryKind
assemblyEntryKindWipeThenCopy =
    Typed.TypedTerm (Core.TermInject (Core.Injection {
      Core.injectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntryKind"),
      Core.injectionField = Core.Field {
        Core.fieldName = (Core.Name "wipeThenCopy"),
        Core.fieldTerm = Core.TermUnit}}))

-- | DSL accessor for the sourceTree field of hydra.build.assembly.AssemblyEntry
assemblyEntrySourceTree :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm String
assemblyEntrySourceTree x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
        Core.projectionFieldName = (Core.Name "sourceTree")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL updater for the destTree field of hydra.build.assembly.AssemblyEntry
assemblyEntryWithDestTree :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm String -> Typed.TypedTerm Assembly.AssemblyEntry
assemblyEntryWithDestTree original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceTree"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "sourceTree")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "destTree"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "kind"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "kind")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "exclude"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "exclude")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the exclude field of hydra.build.assembly.AssemblyEntry
assemblyEntryWithExclude :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm [String] -> Typed.TypedTerm Assembly.AssemblyEntry
assemblyEntryWithExclude original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceTree"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "sourceTree")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "destTree"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "destTree")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "kind"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "kind")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "exclude"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)}]}))

-- | DSL updater for the kind field of hydra.build.assembly.AssemblyEntry
assemblyEntryWithKind :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm Assembly.AssemblyEntryKind -> Typed.TypedTerm Assembly.AssemblyEntry
assemblyEntryWithKind original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceTree"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "sourceTree")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "destTree"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "destTree")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "kind"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "exclude"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "exclude")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the sourceTree field of hydra.build.assembly.AssemblyEntry
assemblyEntryWithSourceTree :: Typed.TypedTerm Assembly.AssemblyEntry -> Typed.TypedTerm String -> Typed.TypedTerm Assembly.AssemblyEntry
assemblyEntryWithSourceTree original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceTree"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "destTree"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "destTree")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "kind"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "kind")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "exclude"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyEntry"),
              Core.projectionFieldName = (Core.Name "exclude")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL constructor for hydra.build.assembly.AssemblyPlan
assemblyPlan :: Typed.TypedTerm [Assembly.AssemblyEntry] -> Typed.TypedTerm [Assembly.KeepPathEntry] -> Typed.TypedTerm Assembly.AssemblyPlan
assemblyPlan entries keepPaths =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyPlan"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "entries"),
          Core.fieldTerm = (Typed.unTypedTerm entries)},
        Core.Field {
          Core.fieldName = (Core.Name "keepPaths"),
          Core.fieldTerm = (Typed.unTypedTerm keepPaths)}]}))

-- | DSL name token for hydra.build.assembly.AssemblyPlan
assemblyPlanAssemblyPlan :: Typed.TypedName Assembly.AssemblyPlan
assemblyPlanAssemblyPlan = Typed.TypedName (Core.Name "hydra.build.assembly.AssemblyPlan")

-- | DSL accessor for the entries field of hydra.build.assembly.AssemblyPlan
assemblyPlanEntries :: Typed.TypedTerm Assembly.AssemblyPlan -> Typed.TypedTerm [Assembly.AssemblyEntry]
assemblyPlanEntries x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyPlan"),
        Core.projectionFieldName = (Core.Name "entries")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the keepPaths field of hydra.build.assembly.AssemblyPlan
assemblyPlanKeepPaths :: Typed.TypedTerm Assembly.AssemblyPlan -> Typed.TypedTerm [Assembly.KeepPathEntry]
assemblyPlanKeepPaths x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyPlan"),
        Core.projectionFieldName = (Core.Name "keepPaths")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL updater for the entries field of hydra.build.assembly.AssemblyPlan
assemblyPlanWithEntries :: Typed.TypedTerm Assembly.AssemblyPlan -> Typed.TypedTerm [Assembly.AssemblyEntry] -> Typed.TypedTerm Assembly.AssemblyPlan
assemblyPlanWithEntries original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyPlan"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "entries"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "keepPaths"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyPlan"),
              Core.projectionFieldName = (Core.Name "keepPaths")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the keepPaths field of hydra.build.assembly.AssemblyPlan
assemblyPlanWithKeepPaths :: Typed.TypedTerm Assembly.AssemblyPlan -> Typed.TypedTerm [Assembly.KeepPathEntry] -> Typed.TypedTerm Assembly.AssemblyPlan
assemblyPlanWithKeepPaths original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.AssemblyPlan"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "entries"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.AssemblyPlan"),
              Core.projectionFieldName = (Core.Name "entries")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "keepPaths"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)}]}))

-- | DSL constructor for hydra.build.assembly.KeepPathEntry
keepPathEntry :: Typed.TypedTerm String -> Typed.TypedTerm String -> Typed.TypedTerm Assembly.KeepPathEntry
keepPathEntry sourceSetDir relPath =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.KeepPathEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceSetDir"),
          Core.fieldTerm = (Typed.unTypedTerm sourceSetDir)},
        Core.Field {
          Core.fieldName = (Core.Name "relPath"),
          Core.fieldTerm = (Typed.unTypedTerm relPath)}]}))

-- | DSL name token for hydra.build.assembly.KeepPathEntry
keepPathEntryKeepPathEntry :: Typed.TypedName Assembly.KeepPathEntry
keepPathEntryKeepPathEntry = Typed.TypedName (Core.Name "hydra.build.assembly.KeepPathEntry")

-- | DSL accessor for the relPath field of hydra.build.assembly.KeepPathEntry
keepPathEntryRelPath :: Typed.TypedTerm Assembly.KeepPathEntry -> Typed.TypedTerm String
keepPathEntryRelPath x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.KeepPathEntry"),
        Core.projectionFieldName = (Core.Name "relPath")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the sourceSetDir field of hydra.build.assembly.KeepPathEntry
keepPathEntrySourceSetDir :: Typed.TypedTerm Assembly.KeepPathEntry -> Typed.TypedTerm String
keepPathEntrySourceSetDir x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.assembly.KeepPathEntry"),
        Core.projectionFieldName = (Core.Name "sourceSetDir")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL updater for the relPath field of hydra.build.assembly.KeepPathEntry
keepPathEntryWithRelPath :: Typed.TypedTerm Assembly.KeepPathEntry -> Typed.TypedTerm String -> Typed.TypedTerm Assembly.KeepPathEntry
keepPathEntryWithRelPath original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.KeepPathEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceSetDir"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.KeepPathEntry"),
              Core.projectionFieldName = (Core.Name "sourceSetDir")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "relPath"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)}]}))

-- | DSL updater for the sourceSetDir field of hydra.build.assembly.KeepPathEntry
keepPathEntryWithSourceSetDir :: Typed.TypedTerm Assembly.KeepPathEntry -> Typed.TypedTerm String -> Typed.TypedTerm Assembly.KeepPathEntry
keepPathEntryWithSourceSetDir original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.assembly.KeepPathEntry"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "sourceSetDir"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "relPath"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.assembly.KeepPathEntry"),
              Core.projectionFieldName = (Core.Name "relPath")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))