public class DModule extends Object implements SourceFile
Constructor and Description |
---|
DModule(SourceLocator sourceLocator,
int id,
int bitmap,
String name,
String script,
int isolateId) |
Modifier and Type | Method and Description |
---|---|
String |
getBasePath()
Base path for this filename, without the package-name portion.
|
int |
getBitmap() |
String |
getFullPath()
Full path and file name, if its exists, for this SourceFile.
|
String |
getFunctionNameForLine(Session s,
int line)
Return the function name for a given line number, or
null
if not known or if the line matches more than one function. |
String[] |
getFunctionNames(Session s)
Get a list of all function names for this SourceFile
|
int |
getId()
Return a unique identifier for this SourceFile.
|
String |
getLine(int i)
Obtains the textual content of the given line
from within a source file.
|
int |
getLineCount()
Returns the number of source lines in the given file
|
int |
getLineForFunctionName(Session s,
String name)
Return the line number for the given function name
if it doesn't exists -1 is returned
|
String |
getName()
File name of this SourceFile.
|
int |
getOffsetForLine(int line)
Return the offset within the SWF for a given line
number.
|
String |
getPackageName()
Get the package name portion of the path for this file.
|
String |
getRawName()
Raw, unprocessed file name for this SourceFile.
|
ScriptText |
getScript() |
void |
lineMapping(StringBuilder sb) |
String |
toString()
for debugging
|
public DModule(SourceLocator sourceLocator, int id, int bitmap, String name, String script, int isolateId)
name
- filename in "basepath;package;filename" formatpublic ScriptText getScript()
public String getBasePath()
SourceFile
getBasePath
in interface SourceFile
public String getName()
SourceFile
getName
in interface SourceFile
public String getFullPath()
SourceFile
getBasePath + slash + getPackageName() + slash + getName()
where "slash" is a platform-specific slash character.getFullPath
in interface SourceFile
public String getPackageName()
SourceFile
getPackageName
in interface SourceFile
public String getRawName()
SourceFile
getRawName
in interface SourceFile
public int getId()
SourceFile
getId
in interface SourceFile
public int getBitmap()
public int getLineCount()
SourceFile
getLineCount
in interface SourceFile
public String getLine(int i)
SourceFile
getLine
in interface SourceFile
public int getOffsetForLine(int line)
SourceFile
getOffsetForLine
in interface SourceFile
public int getLineForFunctionName(Session s, String name)
SourceFile
getLineForFunctionName
in interface SourceFile
public String getFunctionNameForLine(Session s, int line)
SourceFile
null
if not known or if the line matches more than one function.getFunctionNameForLine
in interface SourceFile
public String[] getFunctionNames(Session s)
SourceFile
getFunctionNames
in interface SourceFile
public void lineMapping(StringBuilder sb)
Copyright © 2016 The Apache Software Foundation. All rights reserved.