lib/compiler/flowgraph/implicit_views.js
function implicit_views(g, options) {
    var default_view = options.default_view || 'table';

    var leaves = g.get_leaves();
    var table;
    _.each(leaves, function(node) {
        if (!is_sink(node)) {
            table = g.add_node('View', default_view);
            g.add_edge(node, table);
        }
    });
}
function implicit_views(g, options) {
    var default_view = options.default_view || 'table';

    var leaves = g.get_leaves();
    var table;
    _.each(leaves, function(node) {
        if (!is_sink(node)) {
            table = g.add_node('View', default_view);
            g.add_edge(node, table);
        }
    });
}
function implicit_views ( g , options ) { var default_view = options . default_view || 'table' ; var leaves = g . get_leaves ( ) ; var table ; _ . each ( leaves , function ( node ) { if ( ! is_sink ( node ) ) { table = g . add_node ( 'View' , default_view ) ; g . add_edge ( node , table ) ; } } ) ; }
Generate a graph builder that adds an implicit sink of the given type to any branches of the graph that don't already end in a sink.
Generate a graph builder that adds an implicit sink of the given type to any branches of the graph that don t already end in a sink .