Java Doc for DataCompiler.java in  » Ajax » Laszlo-4.0.10 » org » openlaszlo » xml » internal » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Ajax » Laszlo 4.0.10 » org.openlaszlo.xml.internal 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.openlaszlo.xml.internal.DataCommon
      org.openlaszlo.xml.internal.DataCompiler

DataCompiler
public class DataCompiler extends DataCommon (Code)
Takes XML in various forms, and serializes it to isomorphic actionscript bytecode.
author:
   Max Carlson, Henry Minsky
version:
   1.1

Inner Class :static class DCOptions implements Cloneable

Field Summary
static  intFB_INIT_SIZE
    
static  intMAXFRAME_SIZE
    
static  intMISC_BUFSIZ
    
static  StringSTRINGBUF_VAR
    

Constructor Summary
public  DataCompiler()
    

Method Summary
public static  InputStreamcompile(String x, String headers, int flashVersion, boolean addwrapper, boolean trimWhitespace)
    
public static  InputStreamcompile(String x, String headers, int flashVersion, boolean addwrapper, boolean trimWhitespace, boolean compress)
    
public static  InputStreamcompile(String x, String headers, int flashVersion, boolean addwrapper, boolean trimWhitespace, boolean compress, boolean nsprefix)
    
public static  InputStreamcompile(String x, int flashVersion)
    
public static  InputStreamcompile(String x, int flashVersion, boolean nsprefix)
    
public static  InputStreamgetSWF(XmlPullParser xpp, XmlPullParser xpheaders, int xmlsize, int flashVersion, boolean addwrapper)
    
public static  InputStreamgetSWF(XmlPullParser xpp, XmlPullParser xpheaders, int xmlsize, int flashVersion, boolean addwrapper, boolean trimWhitespace, boolean compress, boolean nsprefix)
    
static  StringgetStackTrace(Throwable aThrowable)
    
public static  ProgrammakeProgram(Element data, int flashVersion)
    
public static  ProgrammakeProgram(Element data, int flashVersion, boolean trimWhitespace, boolean localdata, boolean nsprefix)
    
public static  ProgrammakeProgram(Element data, DCOptions ioptions)
    
public static  VectormakeProgram(XmlPullParser xpp, XmlPullParser xpheaders, int xmlsize, DCOptions ioptions)
     Produces a JGenerator Flash Program containing executable SWF codes to build an XML datasource structure which represents this XML stream.
static  voidsplitPushString(String text, Program prog)
     Split string into PUSH chunks of less than 64k, and emit string concat instructions to re-assemble them.

Field Detail
FB_INIT_SIZE
static int FB_INIT_SIZE(Code)



MAXFRAME_SIZE
static int MAXFRAME_SIZE(Code)



MISC_BUFSIZ
static int MISC_BUFSIZ(Code)
global var to hold the image of the stack when splitting frames



STRINGBUF_VAR
static String STRINGBUF_VAR(Code)




Constructor Detail
DataCompiler
public DataCompiler()(Code)




Method Detail
compile
public static InputStream compile(String x, String headers, int flashVersion, boolean addwrapper, boolean trimWhitespace) throws IOException, DataCompilerException(Code)



compile
public static InputStream compile(String x, String headers, int flashVersion, boolean addwrapper, boolean trimWhitespace, boolean compress) throws IOException, DataCompilerException(Code)



compile
public static InputStream compile(String x, String headers, int flashVersion, boolean addwrapper, boolean trimWhitespace, boolean compress, boolean nsprefix) throws IOException, DataCompilerException(Code)
Compile XML to SWF
Parameters:
  x - XML string to compile input streamThe size of the input XML will always be greater than theoutput .swf (possibly plus some factor, to be measured), so we can allocate a FlashBufferwith that max size and be done.



compile
public static InputStream compile(String x, int flashVersion) throws IOException, DataCompilerException(Code)



compile
public static InputStream compile(String x, int flashVersion, boolean nsprefix) throws IOException, DataCompilerException(Code)



getSWF
public static InputStream getSWF(XmlPullParser xpp, XmlPullParser xpheaders, int xmlsize, int flashVersion, boolean addwrapper) throws IOException, XmlPullParserException(Code)
default trimWhitespace to true, for back compatibility



getSWF
public static InputStream getSWF(XmlPullParser xpp, XmlPullParser xpheaders, int xmlsize, int flashVersion, boolean addwrapper, boolean trimWhitespace, boolean compress, boolean nsprefix) throws IOException, XmlPullParserException(Code)
Get XML to output stream SWF
Parameters:
  xpp - an XPP XML parser which points to the XML data
Parameters:
  xppheaders - an XPP XML parser which points to HTTP or other header XML metadata
Parameters:
  flashVersion - 5 or greater
Parameters:
  addwrapper - Set to true if you pass in a separate HTTP headers string
Parameters:
  trimWhitespace - controls whether whitespace is trimmed in text content swf input stream



getStackTrace
static String getStackTrace(Throwable aThrowable)(Code)



makeProgram
public static Program makeProgram(Element data, int flashVersion) throws CompilationError(Code)
default trimWhitespace=false



makeProgram
public static Program makeProgram(Element data, int flashVersion, boolean trimWhitespace, boolean localdata, boolean nsprefix) throws CompilationError(Code)
Called for compile-time data, don't do frame splitting, and don't add any resultset wrapper



makeProgram
public static Program makeProgram(Element data, DCOptions ioptions) throws CompilationError(Code)
Called for compile-time data, don't do frame splitting, and don't add any resultset wrapper



makeProgram
public static Vector makeProgram(XmlPullParser xpp, XmlPullParser xpheaders, int xmlsize, DCOptions ioptions) throws IOException, XmlPullParserException(Code)
Produces a JGenerator Flash Program containing executable SWF codes to build an XML datasource structure which represents this XML stream. Splits execution across frames when program buffer becomes too large.
Parameters:
  xpp - XML XPP parser which is reading from the data content string Vector of one or more (if frame splitting) Flash Programs



splitPushString
static void splitPushString(String text, Program prog)(Code)
Split string into PUSH chunks of less than 64k, and emit string concat instructions to re-assemble them. Leaves string value on stack.



Fields inherited from org.openlaszlo.xml.internal.DataCommon
public static String BODY_NODE_INSTANTIATOR_FN(Code)(Java Doc)
public static String NODE_INSTANTIATOR_FN(Code)(Java Doc)
public static String RESULTSET_NODE_INSTANTIATOR_FN(Code)(Java Doc)
public static String ROOT_NODE_FINAL_FN(Code)(Java Doc)
public static String ROOT_NODE_INSTANTIATOR_FN(Code)(Java Doc)
public static String TEXT_INSTANTIATOR_FN(Code)(Java Doc)

Methods inherited from org.openlaszlo.xml.internal.DataCommon
final public static void _pushMergedStringData(String s, FlashBuffer body, DataContext dc)(Code)(Java Doc)
final public static void _pushMergedStringDataSymbol(String s, FlashBuffer body, DataContext dc)(Code)(Java Doc)
final public static void _pushStringData(String s, FlashBuffer body, DataContext dc)(Code)(Java Doc)
final public static void _writeOffset(int o, FlashBuffer fb)(Code)(Java Doc)
final public static int addStringConstant(String s, DataContext dc)(Code)(Java Doc)
public static int getByteLength(String s, String encoding)(Code)(Java Doc)
final public static int getStringIndex(String s, DataContext dc)(Code)(Java Doc)
final public static int internString(String s, DataContext dc)(Code)(Java Doc)
final public static byte[] makeStringPool(DataContext dc)(Code)(Java Doc)
final public static int maybeInternString(String s, DataContext dc)(Code)(Java Doc)
public static void printProgram(Program program)(Code)(Java Doc)
final public static void pushMergedStringData(String s, FlashBuffer body, DataContext dc)(Code)(Java Doc)
final public static void pushMergedStringDataSymbol(String s, FlashBuffer body, DataContext dc)(Code)(Java Doc)
final public static void pushStringData(String s, FlashBuffer body, DataContext dc)(Code)(Java Doc)
final public static void writeFlashData(FlashBuffer body, byte[] data, int destPos)(Code)(Java Doc)
final public static void writeOffset(int o, FlashBuffer fb)(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.