Sha256: 12d7272ea861633e7b6643f4cdb13e787cca692ec52647cab51b0f2990c5d1ef
Contents?: true
Size: 951 Bytes
Versions: 8
Compression:
Stored size: 951 Bytes
Contents
# # ActiveFacts Generators. # Generate *no* output for ActiveFacts vocabularies; i.e. just a stub # # Copyright (c) 2009 Clifford Heath. Read the LICENSE file. # require 'activefacts/rmap' module ActiveFacts module Generators # Generate nothing from an ActiveFacts vocabulary. This is useful to check the file can be read ok. # Invoke as # afgen --null <file>.cql class NULL private def initialize(vocabulary, *options) @vocabulary = vocabulary @vocabulary = @vocabulary.Vocabulary.values[0] if ActiveFacts::API::Constellation === @vocabulary @tables = options.include? "tables" @columns = options.include? "columns" @indices = options.include? "indices" end public def generate(out = $>) @vocabulary.tables if @tables || @columns || @indices end end end end ActiveFacts::Registry.generator('null', ActiveFacts::Generators::NULL)
Version data entries
8 entries across 8 versions & 1 rubygems