|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.google.javascript.rhino.jstype.SimpleSourceFile
public final class SimpleSourceFile
A simple implementation of StaticSourceFile for testing.
| Constructor Summary | |
|---|---|
SimpleSourceFile(String name,
boolean extern)
|
|
| Method Summary | |
|---|---|
int |
getColumnOfOffset(int offset)
Gets the 0-based column number of the given source offset. |
int |
getLineOffset(int line)
Returns the offset of the given line number relative to the file start. |
int |
getLineOfOffset(int offset)
Gets the 1-based line number of the given source offset. |
String |
getName()
The name of the file. |
boolean |
isExtern()
Returns whether this is an externs file. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SimpleSourceFile(String name,
boolean extern)
| Method Detail |
|---|
public String getName()
StaticSourceFile
getName in interface StaticSourceFilepublic boolean isExtern()
StaticSourceFile
isExtern in interface StaticSourceFilepublic int getColumnOfOffset(int offset)
StaticSourceFile
getColumnOfOffset in interface StaticSourceFileoffset - An absolute file offset.
public int getLineOfOffset(int offset)
StaticSourceFile
getLineOfOffset in interface StaticSourceFileoffset - An absolute file offset.
public int getLineOffset(int line)
StaticSourceFile
getLineOffset in interface StaticSourceFileline - the line of the input to get the absolute offset of.
public String toString()
toString in class Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||