Back to index

python3.2  3.2.2
Classes | Functions | Variables
spark Namespace Reference

Classes

class  GenericScanner
class  _State
class  GenericParser
class  GenericASTBuilder
class  GenericASTTraversalPruningException
class  GenericASTTraversal
class  GenericASTMatcher

Functions

def output
def sorted
def _namelist
def _dump

Variables

string __version__ = 'SPARK-0.7 (pre-alpha-5)'

Class Documentation

class spark::GenericASTTraversalPruningException

Definition at line 730 of file spark.py.


Function Documentation

def spark._dump (   tokens,
  sets,
  states 
) [private]

Definition at line 836 of file spark.py.

00836 
00837 def _dump(tokens, sets, states):
00838     for i in range(len(sets)):
00839         output('set %d' % i)
00840         for item in sets[i]:
00841             output('\t', item)
00842             for (lhs, rhs), pos in states[item[0]].items:
00843                 output('\t\t', lhs, '::=', end='')
00844                 output(' '.join(rhs[:pos]), end='')
00845                 output('.', end='')
00846                 output(' '.join(rhs[pos:]))
00847         if i < len(tokens):
00848             output()
00849             output('token %s' % str(tokens[i]))
00850             output()

Here is the call graph for this function:

def spark._namelist (   instance) [private]

Definition at line 38 of file spark.py.

00038 
00039 def _namelist(instance):
00040     namelist, namedict, classlist = [], {}, [instance.__class__]
00041     for c in classlist:
00042         for b in c.__bases__:
00043             classlist.append(b)
00044         for name in c.__dict__.keys():
00045             if name not in namedict:
00046                 namelist.append(name)
00047                 namedict[name] = 1
00048     return namelist

Here is the caller graph for this function:

def spark.output (   string = '',
  end = '\n' 
)

Definition at line 27 of file spark.py.

00027 
00028 def output(string='', end='\n'):
00029     sys.stdout.write(string + end)
00030 
00031 try:
    sorted

Here is the caller graph for this function:

def spark.sorted (   seq)

Definition at line 33 of file spark.py.

00033 
00034     def sorted(seq):
00035         seq2 = seq[:]
00036         seq2.sort()
00037         return seq2

Here is the caller graph for this function:


Variable Documentation

string spark.__version__ = 'SPARK-0.7 (pre-alpha-5)'

Definition at line 22 of file spark.py.