class Twb::TabClass

Attributes

id[RW]
properties[RW]
ttlogfile[RW]
ttlogfilename[RW]
type[RW]
uuid[RW]

Public Class Methods

new() click to toggle source
# File lib/twb/tabclass.rb, line 28
def initialize
    @ttlogfile    = 'TableauTools.ttlog'
    @logger       = Logger.new(@ttlogfile)
    @logger.level = Logger::DEBUG
end

Public Instance Methods

docFile(name) click to toggle source
# File lib/twb/tabclass.rb, line 50
def docFile name
  @ttdocdir.nil? ? name : "#{@@ttdocdir}/#{name}"
end
emit(local=@localEmit, stuff) click to toggle source
# File lib/twb/tabclass.rb, line 54
def emit(local=@localEmit, stuff)
    # puts "\nstuff.class #{stuff.class}  :: #{stuff}" if local
    if stuff.is_a? String then
      lines = stuff.split(/\n/)
      lines.each do |line|
        @logger.debug "#{@emitPrefix}#{line}"
                 puts "#{@emitPrefix}#{line}" if local
      end
    else
        @logger.debug "#{@emitPrefix}#{stuff}"
                 puts "#{@emitPrefix}#{stuff}" if local
    end
end
setDocFileName() click to toggle source
# File lib/twb/tabclass.rb, line 46
def setDocFileName
    docFile @@ttlogfilename
end