Java Doc for Instance.java in  » Ajax » Laszlo-4.0.10 » org » openlaszlo » iv » flash » api » 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.iv.flash.api 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.openlaszlo.iv.flash.api.FlashItem
      org.openlaszlo.iv.flash.api.FlashObject
         org.openlaszlo.iv.flash.api.Instance

Instance
public class Instance extends FlashObject (Code)
Instance of flash definition

This object represents flash file format's PlaceObject2 as well as PlaceObject tags.

PlaceObject2 can both add a character to the display list, and modify the attributes of a character that is already on the display list.

The tag begins with a group of flags that indicate which fields are present in the tag. The optional fields are def, matrix, cxform, ratio, clip and name. The depth field is the only field that is always required.

The depth value determines the stacking order of the character. Characters with lower depth values are displayed underneath characters with higher depth values. A depth value of 1 means the character is displayed at the bottom of the stack. There can be only one character at any given depth. This means a character that is already on the display list can be identified by its depth alone. (i.e. a def is not required).

Flag Move and flag HasCharacter indicate whether a new character is being added to the display list, or a character already on the display list is being modified. The meaning of the flags is as follows:

  • PlaceFlagMove = 0 and PlaceFlagHasCharacter = 1
    A new character (with ID of CharacterId) is placed on the display list at the specified Depth. Other fields set the attributes of this new character.
  • PlaceFlagMove = 1 and PlaceFlagHasCharacter = 0
    The character at the specified Depth is modified. Other fields modify the attributes of this character. Because there can be only one character at any given depth, no CharacterId is required.
  • PlaceFlagMove = 1 and PlaceFlagHasCharacter = 1
    The character at the specified Depth is removed, and a new character (with ID of CharacterId) is placed at that depth. Other fields set the attributes of this new character.

The optional fields in PlaceObject2 have the following meaning:

  • The def field specifies the character to be added to the display list. It only used only when a new character is being added. If a character that is already on the display list is being modified, the def field is absent.
  • The matrix field specifies the position, scale and rotation of the character being added or modified.
  • The cxform field specifies the color effect applied to the character being added or modified.
  • The ratio field specifies a morph ratio for the character being added or modified. This field applies only to characters defined with DefineMorphShape, and controls how far the morph has progressed. A ratio of zero displays the character at the start of the morph. A ratio of 65535 displays the character at the end of the morph. For values between zero and 65535 the player interpolates between the start and end shapes, and displays an 'in-between' shape.
  • The clip field specifies the top-most depth that will be masked by the character being added. A clip of zero indicates no clipping.
  • The name field specifies a name for the character being added or modified. This field is typically used with sprite characters, and is used to identify the sprite for SetTarget actions. It allows the main movie (or other sprites) to perform actions inside the sprite.

author:
   Dmitry Skavish
See Also:   RemoveObject


Field Summary
final public static  intHAS_CHARACTER
    
final public static  intHAS_CLIP
    
final public static  intHAS_CLIPACTIONS
    
final public static  intHAS_COLOR_TRANSF
    
final public static  intHAS_MATRIX
    
final public static  intHAS_NAME
    
final public static  intHAS_RATIO
    
final public static  intMOVE
    
public  ClipActionsactions
    
public  intclip
    
public  GenericCommandcommand
    
public  CXFormcxform
    
public  FlashDefdef
    
public  intdepth
    
public  booleanisMove
     true if this instance just for changing an object properties, such as transformation etc.
public  AffineTransformmatrix
    
public  Stringname
    
public  intratio
    

Constructor Summary
public  Instance()
    

Method Summary
protected  boolean_isConstant()
    
public  voidapply(Context context)
    
public  voidcollectDeps(DepsCollector dc)
    
public  voidcollectFonts(FontsCollector fc)
    
protected  FlashItemcopyInto(FlashItem item, ScriptCopier copier)
    
public  ScriptcopyScript()
    
public  Rectangle2DgetBounds()
    
public  GenericCommandgetCommand()
    
public  FlashItemgetCopy(ScriptCopier copier)
    
public  FlashDefgetFirstNestedFlashDef(AffineTransform m)
    
public  ScriptgetScript()
    
public  intgetTag()
    
public  booleanisCommand()
    
public  booleanisProcessed()
    
public  booleanisScript()
    
public static  Instanceparse(Parser p)
    
public static  Instanceparse2(Parser p)
    
public  voidprintContent(PrintStream out, String indent)
    
public  voidprocess(FlashFile file, Context context)
    
public  voidsetCommand(GenericCommand command)
    
public  voidsetProcessed()
    
public  ScriptsetScript(Script script)
    
public  voidwrite(FlashOutput fob)
    

Field Detail
HAS_CHARACTER
final public static int HAS_CHARACTER(Code)



HAS_CLIP
final public static int HAS_CLIP(Code)



HAS_CLIPACTIONS
final public static int HAS_CLIPACTIONS(Code)



HAS_COLOR_TRANSF
final public static int HAS_COLOR_TRANSF(Code)



HAS_MATRIX
final public static int HAS_MATRIX(Code)



HAS_NAME
final public static int HAS_NAME(Code)



HAS_RATIO
final public static int HAS_RATIO(Code)



MOVE
final public static int MOVE(Code)



actions
public ClipActions actions(Code)
Clip actions or null



clip
public int clip(Code)
Clip layer number or -1



command
public GenericCommand command(Code)
Generator command applied to this instance or null



cxform
public CXForm cxform(Code)
Color transformation matrix or null



def
public FlashDef def(Code)
Flash definition or null



depth
public int depth(Code)
Layer depth



isMove
public boolean isMove(Code)
true if this instance just for changing an object properties, such as transformation etc.



matrix
public AffineTransform matrix(Code)
Transformation matrix



name
public String name(Code)
Instance name or null



ratio
public int ratio(Code)
Morphing ratio or -1




Constructor Detail
Instance
public Instance()(Code)




Method Detail
_isConstant
protected boolean _isConstant()(Code)



apply
public void apply(Context context)(Code)



collectDeps
public void collectDeps(DepsCollector dc)(Code)



collectFonts
public void collectFonts(FontsCollector fc)(Code)



copyInto
protected FlashItem copyInto(FlashItem item, ScriptCopier copier)(Code)



copyScript
public Script copyScript()(Code)
Makes a copy of a script which is the flash definition of this instance copy of the script



getBounds
public Rectangle2D getBounds()(Code)



getCommand
public GenericCommand getCommand()(Code)
Returns attached generator command attached generator command



getCopy
public FlashItem getCopy(ScriptCopier copier)(Code)



getFirstNestedFlashDef
public FlashDef getFirstNestedFlashDef(AffineTransform m)(Code)
Returns first nested non-script of this instance and its transformation matrix beginning from this instance
Parameters:
  m - collect transformations in this matrix first nested non-script



getScript
public Script getScript()(Code)
Returns flash definition as a Script definition as a Script



getTag
public int getTag()(Code)



isCommand
public boolean isCommand()(Code)
Return true if there is generator command attached to this instance true if there is generator command attached to this instance



isProcessed
public boolean isProcessed()(Code)



isScript
public boolean isScript()(Code)
Returns true if this is instance of a script true if this is instance of a script



parse
public static Instance parse(Parser p)(Code)
Parses PlaceObject tag
Parameters:
  p - parser parser tag



parse2
public static Instance parse2(Parser p)(Code)
Parses PlaceObject2 tag
Parameters:
  p - parser parser tag



printContent
public void printContent(PrintStream out, String indent)(Code)



process
public void process(FlashFile file, Context context) throws IVException(Code)



setCommand
public void setCommand(GenericCommand command)(Code)
Attaches generator command to this instance
Parameters:
  command - generator command to be attached



setProcessed
public void setProcessed()(Code)



setScript
public Script setScript(Script script)(Code)
Sets specified script as flash definition of this instance
Parameters:
  script - specified script specified script



write
public void write(FlashOutput fob)(Code)



Methods inherited from org.openlaszlo.iv.flash.api.FlashObject
protected boolean _isConstant()(Code)(Java Doc)
public void apply(Context context)(Code)(Java Doc)
public void collectDeps(DepsCollector dc)(Code)(Java Doc)
public void collectFonts(FontsCollector fc)(Code)(Java Doc)
protected FlashItem copyInto(FlashItem item, ScriptCopier copier)(Code)(Java Doc)
public void generate(FlashOutput fob, DepsCollector dc)(Code)(Java Doc)
public Rectangle2D getBounds()(Code)(Java Doc)
abstract public int getTag()(Code)(Java Doc)
public boolean isConstant()(Code)(Java Doc)
public boolean isProcessed()(Code)(Java Doc)
public void printContent(PrintStream out, String indent)(Code)(Java Doc)
public void process(FlashFile file, Context context) throws IVException(Code)(Java Doc)
protected void setConstant(boolean is_const)(Code)(Java Doc)
public void setProcessed()(Code)(Java Doc)

Methods inherited from org.openlaszlo.iv.flash.api.FlashItem
protected FlashItem copyInto(FlashItem item, ScriptCopier copier)(Code)(Java Doc)
public FlashItem getCopy(ScriptCopier copier)(Code)(Java Doc)
abstract public void printContent(PrintStream out, String indent)(Code)(Java Doc)
public String toString()(Code)(Java Doc)
abstract public void write(FlashOutput fob)(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.