Code Search for Developers
 
 
  

test_tm.py from The Nebula Device at Krugle


Show test_tm.py syntax highlighted

import sys
sys.stderr = sys.stdout

from TransitionMaps import TransitionMap

m = TransitionMap()
print m

def add(c, s):
  print
  print "adding", repr(c), "-->", repr(s)
  m.add_transition(c, s)
  print m
  print "keys:", m.keys()

add('a','alpha')
add('e', 'eta')
add('f', 'foo')
add('i', 'iota')
add('i', 'imp')
add('eol', 'elephant')







See more files for this project here

The Nebula Device

Realtime 3D game/visualization engine, written in C++, scriptable through Tcl/Tk, Python and Lua. Supports D3D and OpenGL for rendering, runs under Linux and Windows.

Project homepage: http://sourceforge.net/projects/nebuladevice
Programming language(s): C,C++,Python
License: other

  Actions.py
  DFA.py
  Errors.py
  Lexicons.py
  Machines.py
  README
  Regexps.py
  Scanners.py
  TODO
  Timing.py
  Traditional.py
  Transitions.py
  __init__.py
  test_tm.py