Package jazzparser :: Package formalisms :: Package music_halfspan :: Module songtools :: Class SongTreeTool
[hide private]
[frames] | no frames]

Class SongTreeTool

source code

      object --+    
               |    
shell.tools.Tool --+
                   |
                  SongTreeTool

Converts a song's semantics to a tree. Mainly just for debugging.

Instance Methods [hide private]
 
run(self, args, state)
Main operation of tool, taking arguments in args and reading and potentially manipulating the shell state.
source code

Inherited from shell.tools.Tool: process_option_list

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __init__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  name = 'Song tree'
hash(x)
  commands = ['tree']
  usage = ('tree <song-num>', 'converts the semantics of the son...
  tool_options = Tool.tool_options+ [ModuleOption('res', filter=...
  help = 'Converts the semantics of the numbered song to its tre...
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

run(self, args, state)

source code 

Main operation of tool, taking arguments in args and reading and potentially manipulating the shell state.

By the time this is called, the options dict is available in self.options.

Overrides: shell.tools.Tool.run
(inherited documentation)

Class Variable Details [hide private]

usage

Value:
('tree <song-num>',
 'converts the semantics of the song to a tree representation')

tool_options

Value:
Tool.tool_options+ [ModuleOption('res', filter= str_to_bool, usage= "r\
es=B, where B is true or false", default= False, help_text= "Show a re\
sult, instead of a corpus song"),]

help

Value:
'''Converts the semantics of the numbered song to its tree representat\
ion that 
will be used for comparison to other logical forms. This is mainly for\
 
debugging and has no use in itself.
'''