File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed
compiler/src/main/scala/edu/berkeley/cs/boom/bloomscala/codegen/js Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ The command line interface to the Bloom compiler is implemented by the
12
12
During development, the easiest way to run the compiler is through ` sbt run ` ;
13
13
use
14
14
15
- sbt run --infile <sourcefile> --target [dataflow|rxflow]
15
+ sbt " run --infile <sourcefile> --target [dataflow|rxflow]"
16
16
17
17
to compile ` sourcefile ` and generate either a GraphViz .DOT file representing
18
18
a dataflow graph (for the ` dataflow ` target) or Javascript code (for the
Original file line number Diff line number Diff line change @@ -50,8 +50,6 @@ object RxFlowCodeGenerator extends DataflowCodeGenerator with JsCodeGeneratorUti
50
50
inputPort.name match {
51
51
case " deltaIn" => " .insert"
52
52
}
53
- case OutputElement (collection) =>
54
- empty // Since outputs are currently implemented as RxJs Sbjects.
55
53
case _ => " .input"
56
54
})
57
55
}
@@ -94,15 +92,14 @@ object RxFlowCodeGenerator extends DataflowCodeGenerator with JsCodeGeneratorUti
94
92
}
95
93
96
94
private def buildOutputs (graph : DataflowGraph ): Doc = {
97
- // TODO: this should create an Rx observable, not a Subject.
98
95
val outputs = graph.outputs.values.map { output =>
99
- (elemName(output), " new" <+> methodCall(" rx " , " Subject " ) <+>
96
+ (elemName(output), " new" <+> methodCall(" rxflow " , " ObservableSink " ) <+>
100
97
comment(BloomPrettyPrinter .pretty(output.collection)))
101
98
}.toMap
102
99
103
100
" var" <+> " outputs" <+> equal <+> mapLiteral(outputs) <> semi <@@>
104
101
graph.outputs.values.map { output =>
105
- " this" <> dot <> output.collection.name <+> equal <+> elemRef(output) <> semi
102
+ " this" <> dot <> output.collection.name <+> equal <+> elemRef(output) <> dot <> " output " <> semi
106
103
}.foldLeft(empty)(_ <@@> _)
107
104
}
108
105
You can’t perform that action at this time.
0 commit comments