This GitLab instance reached the end of its service life. It won't be possible to create new users or projects.

Please read the deprecation notice for more information concerning the deprecation timeline

Visit migration.git.tu-berlin.de (internal network only) to import your old projects to the new GitLab platform 📥

TestSamples.scala 792 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
package de.bbisping.coupledsim.algo

import de.bbisping.coupledsim.tool.control.Samples
import de.bbisping.coupledsim.tool.control.Structure
import de.bbisping.coupledsim.tool.model.NodeID
import de.bbisping.coupledsim.ts.Interpreter
import de.bbisping.coupledsim.util.Interpreting
import de.bbisping.coupledsim.ts.Parser

object TestSamples  {
  
  val samples = for {
    Samples.Example(slug, name, src) <- Samples.namedSamples
    val parser: Parser = new Parser(src)
    val parser.ParseSuccess(esDef, _) = parser.parse
    val interpreter = new Interpreter(esDef, NodeID(_), Structure.arrowAnnotator, Structure.nodeAnnotator)
    val Interpreting.Success(is) = interpreter.result(Structure.transitionSystemConstructor(_, _))
  } yield (slug, is.asInstanceOf[Structure.TSStructure])
  
}