| java.lang.Object org.openlaszlo.compiler.ObjectWriter
All known Subclasses: org.openlaszlo.compiler.SWFWriter, org.openlaszlo.compiler.DHTMLWriter,
ObjectWriter | abstract class ObjectWriter (Code) | | Accumulates code, XML, and assets to an object file.
Properties documented in Compiler.getProperties.
|
Method Summary | |
abstract void | addPreloader(CompilationEnvironment env) | abstract void | addPreloaderScript(String script) | abstract public int | addScript(String script) Compiles the specified script to bytecodes
and add its bytecodes to the app. | abstract public void | close() Writes the object code to the OutputStream that was
supplied to the ObjectWriter's constructor. | abstract public void | closeSnippet() | String | createName() Returns a new unique js name. | abstract FontManager | getFontManager() | protected Resource | getMultiFrameResource(String fileName, String name, int fNum) Find a resource for importing into a movie and return a flashdef. | protected Resource | getResource(String fileName, String name) Find a resource for importing into a movie and return a flashdef. | protected Resource | getResource(String fileName, String name, boolean stop) Find a resource for importing into a movie and return a flashdef. | abstract public void | importBaseLibrary(String library, CompilationEnvironment env) | abstract public String | importClickResource(File file) | abstract void | importFontStyle(String fileName, String face, String style, CompilationEnvironment env) | protected Resource | importMP3(String fileName, String name) | abstract public void | importPreloadResource(String fileName, String name) Import a resource file into the preloader movie. | abstract public void | importPreloadResource(File fileName, String name) | abstract public void | importPreloadResource(List sources, String name, File parent) Import a multiframe resource into the current movie. | public String | importResource(File file) Imports file, if it has not previously been imported, and
returns in any case the name of the clip that refers to it.
File should refer to a graphical asset. | abstract public void | importResource(String fileName, String name) Import a resource file into the current movie. | abstract public void | importResource(File fFile, String name) | abstract public void | importResource(List sources, String name, File parent) | protected Resource | importSWF(String fileName, String name, boolean addStop) | abstract public boolean | isDeviceFont(String face) | abstract public void | openSnippet(String url) | abstract void | setCanvas(Canvas canvas, String canvasConstructor) | abstract void | setCanvasDefaults(Canvas canvas, CompilerMediaCache mc) | abstract public void | setDeviceFont(String face) | abstract public void | setFontManager(FontManager fm) | public void | setScriptLimits(int recursion, int timeout) | public static String | stripBaseName(String fileName, CompilationEnvironment env) | void | warn(CompilationEnvironment env, String msg) |
TWIP | final protected int TWIP(Code) | | Constant
|
mClickResourceMap | protected Map mClickResourceMap(Code) | | |
mCloseCalled | protected boolean mCloseCalled(Code) | | True iff close() has been called.
|
mExecutionTimeout | protected int mExecutionTimeout(Code) | | |
mHeight | protected int mHeight(Code) | | Canvas Height
|
mInfo | protected Element mInfo(Code) | | InfoXML
|
mLogger | protected static Logger mLogger(Code) | | Logger
|
mMultiFrameResourceMap | protected Map mMultiFrameResourceMap(Code) | | |
mMultiFrameResourceSet | final protected HashSet mMultiFrameResourceSet(Code) | | Set of resoures we're importing into the output
|
mPreloaderAdded | protected boolean mPreloaderAdded(Code) | | Has the preloader been added?
|
mRecursionLimit | protected int mRecursionLimit(Code) | | |
mResourceMap | protected Map mResourceMap(Code) | | maps resource files to the Resources
definition in the swf file.
|
mWidth | protected int mWidth(Code) | | Canvas Width
|
ObjectWriter | ObjectWriter(Properties props, OutputStream stream, CompilerMediaCache cache, boolean importLibrary, CompilationEnvironment env)(Code) | | Initializes a ObjectWriter with an OutputStream to which a new object file
will be written when ObjectWriter.close() is called.
Parameters: stream - A java.io.OutputStream that themovie will be written to. Parameters: props - list of properties Parameters: cache - media cache Parameters: importLibrary - If true, the compiler will add in the LaszloLibrary. |
addPreloaderScript | abstract void addPreloaderScript(String script)(Code) | | |
addScript | abstract public int addScript(String script)(Code) | | Compiles the specified script to bytecodes
and add its bytecodes to the app.
Parameters: script - the script to be compiled the number of bytes |
close | abstract public void close() throws IOException(Code) | | Writes the object code to the OutputStream that was
supplied to the ObjectWriter's constructor.
throws: IOException - if an error occurs |
createName | String createName()(Code) | | Returns a new unique js name.
|
getMultiFrameResource | protected Resource getMultiFrameResource(String fileName, String name, int fNum) throws ImportResourceError(Code) | | Find a resource for importing into a movie and return a flashdef.
Doesn't includes stop action.
Parameters: fileName - file name of the resource Parameters: name - name of the resource |
getResource | protected Resource getResource(String fileName, String name) throws ImportResourceError(Code) | | Find a resource for importing into a movie and return a flashdef.
Includes stop action.
Parameters: fileName - file name of the resource Parameters: name - name of the resource |
getResource | protected Resource getResource(String fileName, String name, boolean stop) throws ImportResourceError(Code) | | Find a resource for importing into a movie and return a flashdef.
Parameters: name - name of the resource Parameters: fileName - file name of the resource Parameters: stop - include stop action if true |
importClickResource | abstract public String importClickResource(File file) throws ImportResourceError(Code) | | |
importPreloadResource | abstract public void importPreloadResource(String fileName, String name) throws ImportResourceError(Code) | | Import a resource file into the preloader movie.
Using a name that already exists clobbers the
old resource (for now).
Parameters: fileName - file name of the resource Parameters: name - name of the MovieClip/Sprite throws: CompilationError - |
importPreloadResource | abstract public void importPreloadResource(File fileName, String name) throws ImportResourceError(Code) | | |
importPreloadResource | abstract public void importPreloadResource(List sources, String name, File parent) throws ImportResourceError(Code) | | Import a multiframe resource into the current movie. Using a
name that already exists clobbers the old resource (for now).
|
importResource | public String importResource(File file)(Code) | | Imports file, if it has not previously been imported, and
returns in any case the name of the clip that refers to it.
File should refer to a graphical asset.
|
importResource | abstract public void importResource(String fileName, String name) throws ImportResourceError(Code) | | Import a resource file into the current movie.
Using a name that already exists clobbers the
old resource (for now).
Parameters: fileName - file name of the resource Parameters: name - name of the MovieClip/Sprite throws: CompilationError - |
importResource | abstract public void importResource(File fFile, String name) throws ImportResourceError(Code) | | |
isDeviceFont | abstract public boolean isDeviceFont(String face)(Code) | | |
setCanvas | abstract void setCanvas(Canvas canvas, String canvasConstructor)(Code) | | Sets the canvas for the app
Parameters: canvas - |
setDeviceFont | abstract public void setDeviceFont(String face)(Code) | | |
setScriptLimits | public void setScriptLimits(int recursion, int timeout)(Code) | | |
|
|