packages feed

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

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

-- | DSL functions for hydra.build.benchresult

module Hydra.Dsl.Build.Benchresult where

import qualified Hydra.Build.Benchresult as Benchresult
import qualified Hydra.Core as Core
import qualified Hydra.Decode.Build.Benchresult as DecodeBuildBenchresult
import qualified Hydra.Encode.Build.Benchresult as EncodeBuildBenchresult
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
import qualified Data.Map as M

-- | DSL constructor for hydra.build.benchresult.BenchMetadata
benchMetadata :: Typed.TypedTerm String -> Typed.TypedTerm String -> Typed.TypedTerm String -> Typed.TypedTerm String -> Typed.TypedTerm String -> Typed.TypedTerm Benchresult.BenchMetadata
benchMetadata timestamp language branch commit commitMessage =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "timestamp"),
          Core.fieldTerm = (Typed.unTypedTerm timestamp)},
        Core.Field {
          Core.fieldName = (Core.Name "language"),
          Core.fieldTerm = (Typed.unTypedTerm language)},
        Core.Field {
          Core.fieldName = (Core.Name "branch"),
          Core.fieldTerm = (Typed.unTypedTerm branch)},
        Core.Field {
          Core.fieldName = (Core.Name "commit"),
          Core.fieldTerm = (Typed.unTypedTerm commit)},
        Core.Field {
          Core.fieldName = (Core.Name "commitMessage"),
          Core.fieldTerm = (Typed.unTypedTerm commitMessage)}]}))

-- | DSL name token for hydra.build.benchresult.BenchMetadata
benchMetadataBenchMetadata :: Typed.TypedName Benchresult.BenchMetadata
benchMetadataBenchMetadata = Typed.TypedName (Core.Name "hydra.build.benchresult.BenchMetadata")

-- | DSL accessor for the branch field of hydra.build.benchresult.BenchMetadata
benchMetadataBranch :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String
benchMetadataBranch x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
        Core.projectionFieldName = (Core.Name "branch")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the commit field of hydra.build.benchresult.BenchMetadata
benchMetadataCommit :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String
benchMetadataCommit x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
        Core.projectionFieldName = (Core.Name "commit")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the commitMessage field of hydra.build.benchresult.BenchMetadata
benchMetadataCommitMessage :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String
benchMetadataCommitMessage x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
        Core.projectionFieldName = (Core.Name "commitMessage")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the language field of hydra.build.benchresult.BenchMetadata
benchMetadataLanguage :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String
benchMetadataLanguage x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
        Core.projectionFieldName = (Core.Name "language")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the timestamp field of hydra.build.benchresult.BenchMetadata
benchMetadataTimestamp :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String
benchMetadataTimestamp x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
        Core.projectionFieldName = (Core.Name "timestamp")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL updater for the branch field of hydra.build.benchresult.BenchMetadata
benchMetadataWithBranch :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String -> Typed.TypedTerm Benchresult.BenchMetadata
benchMetadataWithBranch original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "timestamp"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "timestamp")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "language"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "language")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "branch"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "commit"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commit")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commitMessage"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commitMessage")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the commit field of hydra.build.benchresult.BenchMetadata
benchMetadataWithCommit :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String -> Typed.TypedTerm Benchresult.BenchMetadata
benchMetadataWithCommit original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "timestamp"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "timestamp")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "language"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "language")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "branch"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "branch")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commit"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "commitMessage"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commitMessage")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the commitMessage field of hydra.build.benchresult.BenchMetadata
benchMetadataWithCommitMessage :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String -> Typed.TypedTerm Benchresult.BenchMetadata
benchMetadataWithCommitMessage original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "timestamp"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "timestamp")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "language"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "language")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "branch"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "branch")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commit"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commit")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commitMessage"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)}]}))

-- | DSL updater for the language field of hydra.build.benchresult.BenchMetadata
benchMetadataWithLanguage :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String -> Typed.TypedTerm Benchresult.BenchMetadata
benchMetadataWithLanguage original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "timestamp"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "timestamp")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "language"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "branch"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "branch")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commit"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commit")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commitMessage"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commitMessage")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the timestamp field of hydra.build.benchresult.BenchMetadata
benchMetadataWithTimestamp :: Typed.TypedTerm Benchresult.BenchMetadata -> Typed.TypedTerm String -> Typed.TypedTerm Benchresult.BenchMetadata
benchMetadataWithTimestamp original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "timestamp"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "language"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "language")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "branch"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "branch")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commit"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commit")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "commitMessage"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.BenchMetadata"),
              Core.projectionFieldName = (Core.Name "commitMessage")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL constructor for hydra.build.benchresult.GenBenchResult
genBenchResult :: Typed.TypedTerm String -> Typed.TypedTerm Int -> Typed.TypedTerm (M.Map String Benchresult.HostResult) -> Typed.TypedTerm (Maybe Benchresult.BenchMetadata) -> Typed.TypedTerm Benchresult.GenBenchResult
genBenchResult target runs hosts metadata =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "target"),
          Core.fieldTerm = (Typed.unTypedTerm target)},
        Core.Field {
          Core.fieldName = (Core.Name "runs"),
          Core.fieldTerm = (Typed.unTypedTerm runs)},
        Core.Field {
          Core.fieldName = (Core.Name "hosts"),
          Core.fieldTerm = (Typed.unTypedTerm hosts)},
        Core.Field {
          Core.fieldName = (Core.Name "metadata"),
          Core.fieldTerm = (Typed.unTypedTerm metadata)}]}))

-- | DSL name token for hydra.build.benchresult.GenBenchResult
genBenchResultGenBenchResult :: Typed.TypedName Benchresult.GenBenchResult
genBenchResultGenBenchResult = Typed.TypedName (Core.Name "hydra.build.benchresult.GenBenchResult")

-- | DSL accessor for the hosts field of hydra.build.benchresult.GenBenchResult
genBenchResultHosts :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm (M.Map String Benchresult.HostResult)
genBenchResultHosts x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
        Core.projectionFieldName = (Core.Name "hosts")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the metadata field of hydra.build.benchresult.GenBenchResult
genBenchResultMetadata :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm (Maybe Benchresult.BenchMetadata)
genBenchResultMetadata x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
        Core.projectionFieldName = (Core.Name "metadata")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the runs field of hydra.build.benchresult.GenBenchResult
genBenchResultRuns :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm Int
genBenchResultRuns x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
        Core.projectionFieldName = (Core.Name "runs")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the target field of hydra.build.benchresult.GenBenchResult
genBenchResultTarget :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm String
genBenchResultTarget x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
        Core.projectionFieldName = (Core.Name "target")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL updater for the hosts field of hydra.build.benchresult.GenBenchResult
genBenchResultWithHosts :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm (M.Map String Benchresult.HostResult) -> Typed.TypedTerm Benchresult.GenBenchResult
genBenchResultWithHosts original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "target"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "target")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "runs"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "runs")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "hosts"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "metadata"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "metadata")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the metadata field of hydra.build.benchresult.GenBenchResult
genBenchResultWithMetadata :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm (Maybe Benchresult.BenchMetadata) -> Typed.TypedTerm Benchresult.GenBenchResult
genBenchResultWithMetadata original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "target"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "target")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "runs"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "runs")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "hosts"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "hosts")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "metadata"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)}]}))

-- | DSL updater for the runs field of hydra.build.benchresult.GenBenchResult
genBenchResultWithRuns :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm Int -> Typed.TypedTerm Benchresult.GenBenchResult
genBenchResultWithRuns original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "target"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "target")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "runs"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "hosts"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "hosts")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "metadata"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "metadata")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL updater for the target field of hydra.build.benchresult.GenBenchResult
genBenchResultWithTarget :: Typed.TypedTerm Benchresult.GenBenchResult -> Typed.TypedTerm String -> Typed.TypedTerm Benchresult.GenBenchResult
genBenchResultWithTarget original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "target"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "runs"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "runs")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "hosts"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "hosts")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "metadata"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.GenBenchResult"),
              Core.projectionFieldName = (Core.Name "metadata")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL constructor for hydra.build.benchresult.HostResult
hostResult :: Typed.TypedTerm Int -> Typed.TypedTerm (M.Map String Benchresult.RunStats) -> Typed.TypedTerm Benchresult.HostResult
hostResult setupMs packages =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.HostResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "setupMs"),
          Core.fieldTerm = (Typed.unTypedTerm setupMs)},
        Core.Field {
          Core.fieldName = (Core.Name "packages"),
          Core.fieldTerm = (Typed.unTypedTerm packages)}]}))

-- | DSL name token for hydra.build.benchresult.HostResult
hostResultHostResult :: Typed.TypedName Benchresult.HostResult
hostResultHostResult = Typed.TypedName (Core.Name "hydra.build.benchresult.HostResult")

-- | DSL accessor for the packages field of hydra.build.benchresult.HostResult
hostResultPackages :: Typed.TypedTerm Benchresult.HostResult -> Typed.TypedTerm (M.Map String Benchresult.RunStats)
hostResultPackages x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.HostResult"),
        Core.projectionFieldName = (Core.Name "packages")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL accessor for the setupMs field of hydra.build.benchresult.HostResult
hostResultSetupMs :: Typed.TypedTerm Benchresult.HostResult -> Typed.TypedTerm Int
hostResultSetupMs x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.HostResult"),
        Core.projectionFieldName = (Core.Name "setupMs")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL updater for the packages field of hydra.build.benchresult.HostResult
hostResultWithPackages :: Typed.TypedTerm Benchresult.HostResult -> Typed.TypedTerm (M.Map String Benchresult.RunStats) -> Typed.TypedTerm Benchresult.HostResult
hostResultWithPackages original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.HostResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "setupMs"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.HostResult"),
              Core.projectionFieldName = (Core.Name "setupMs")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "packages"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)}]}))

-- | DSL updater for the setupMs field of hydra.build.benchresult.HostResult
hostResultWithSetupMs :: Typed.TypedTerm Benchresult.HostResult -> Typed.TypedTerm Int -> Typed.TypedTerm Benchresult.HostResult
hostResultWithSetupMs original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.HostResult"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "setupMs"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "packages"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.HostResult"),
              Core.projectionFieldName = (Core.Name "packages")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))

-- | DSL constructor for hydra.build.benchresult.RunStats
runStats :: Typed.TypedTerm [Int] -> Typed.TypedTerm Int -> Typed.TypedTerm Benchresult.RunStats
runStats runsMs medianMs =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.RunStats"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "runsMs"),
          Core.fieldTerm = (Typed.unTypedTerm runsMs)},
        Core.Field {
          Core.fieldName = (Core.Name "medianMs"),
          Core.fieldTerm = (Typed.unTypedTerm medianMs)}]}))

-- | DSL accessor for the medianMs field of hydra.build.benchresult.RunStats
runStatsMedianMs :: Typed.TypedTerm Benchresult.RunStats -> Typed.TypedTerm Int
runStatsMedianMs x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.RunStats"),
        Core.projectionFieldName = (Core.Name "medianMs")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL name token for hydra.build.benchresult.RunStats
runStatsRunStats :: Typed.TypedName Benchresult.RunStats
runStatsRunStats = Typed.TypedName (Core.Name "hydra.build.benchresult.RunStats")

-- | DSL accessor for the runsMs field of hydra.build.benchresult.RunStats
runStatsRunsMs :: Typed.TypedTerm Benchresult.RunStats -> Typed.TypedTerm [Int]
runStatsRunsMs x =
    Typed.TypedTerm (Core.TermApplication (Core.Application {
      Core.applicationFunction = (Core.TermProject (Core.Projection {
        Core.projectionTypeName = (Core.Name "hydra.build.benchresult.RunStats"),
        Core.projectionFieldName = (Core.Name "runsMs")})),
      Core.applicationArgument = (Typed.unTypedTerm x)}))

-- | DSL updater for the medianMs field of hydra.build.benchresult.RunStats
runStatsWithMedianMs :: Typed.TypedTerm Benchresult.RunStats -> Typed.TypedTerm Int -> Typed.TypedTerm Benchresult.RunStats
runStatsWithMedianMs original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.RunStats"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "runsMs"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.RunStats"),
              Core.projectionFieldName = (Core.Name "runsMs")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))},
        Core.Field {
          Core.fieldName = (Core.Name "medianMs"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)}]}))

-- | DSL updater for the runsMs field of hydra.build.benchresult.RunStats
runStatsWithRunsMs :: Typed.TypedTerm Benchresult.RunStats -> Typed.TypedTerm [Int] -> Typed.TypedTerm Benchresult.RunStats
runStatsWithRunsMs original newVal =
    Typed.TypedTerm (Core.TermRecord (Core.Record {
      Core.recordTypeName = (Core.Name "hydra.build.benchresult.RunStats"),
      Core.recordFields = [
        Core.Field {
          Core.fieldName = (Core.Name "runsMs"),
          Core.fieldTerm = (Typed.unTypedTerm newVal)},
        Core.Field {
          Core.fieldName = (Core.Name "medianMs"),
          Core.fieldTerm = (Core.TermApplication (Core.Application {
            Core.applicationFunction = (Core.TermProject (Core.Projection {
              Core.projectionTypeName = (Core.Name "hydra.build.benchresult.RunStats"),
              Core.projectionFieldName = (Core.Name "medianMs")})),
            Core.applicationArgument = (Typed.unTypedTerm original)}))}]}))