org.prorefactor.macrolevel
Class MacroLevel

java.lang.Object
  extended by org.prorefactor.macrolevel.MacroLevel

public class MacroLevel
extends java.lang.Object

Static functions for working with an existing macro tree.


Constructor Summary
MacroLevel()
           
 
Method Summary
static int[] getDefinitionPosition(MacroDef def)
          Trace back nested macro definitions until we find the original source.
static MacroRef[] sourceArray(MacroRef top)
          Build and return an array of the MacroRef objects, which would map to the SOURCENUM attribute from JPNode.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MacroLevel

public MacroLevel()
Method Detail

getDefinitionPosition

public static int[] getDefinitionPosition(MacroDef def)
Trace back nested macro definitions until we find the original source.

Returns:
int[3] - file, line, column.

sourceArray

public static MacroRef[] sourceArray(MacroRef top)
Build and return an array of the MacroRef objects, which would map to the SOURCENUM attribute from JPNode. Built simply by walking the tree and adding every MacroRef to the array.



Copyright © 2008 Joanju Software. All Rights Reserved.