Packagecom.yworks.remote
Classpublic class RoundtripEvent
InheritanceRoundtripEvent Inheritance flash.events.Event

The RoundtripEvent is fired by the RoundtripHandler at different stages of the roundtrip process.

See also

RoundtripHandler


Public Properties
 PropertyDefined By
  graph : IGraph
[read-only] The graph which is created from the recieved XML.
RoundtripEvent
  xml : XML
[read-only] The result which is recieved from the server as XML.
RoundtripEvent
Public Methods
 MethodDefined By
  
RoundtripEvent(type:String, xml:XML = null, graph:IGraph = null, bubbles:Boolean = false, cancelable:Boolean = false)
Creates a new instance.
RoundtripEvent
  
clone():Event
[override]
RoundtripEvent
Public Constants
 ConstantDefined By
  GRAPH_PARSED : String = graphParsed
[static] Dispatched after the GraphML was parsed.
RoundtripEvent
  ROUNDTRIP_COMPLETE : String = roundtripComplete
[static] Dispatched after the roundtrip is completed and the new graph is stored in the GraphCanvasComponent graph.
RoundtripEvent
  XML_LOADED : String = xmlLoaded
[static] Dispatched when the response GraphML is completely loaded but not yet parsed.
RoundtripEvent
  XML_SERIALIZED : String = xmlSerialized
[static] Dispatched when the graph is serialized as GraphML before sending.
RoundtripEvent
Property Detail
graphproperty
graph:IGraph  [read-only]

The graph which is created from the recieved XML.

Can be null if the XML is not yet parsed.


Implementation
    public function get graph():IGraph
xmlproperty 
xml:XML  [read-only]

The result which is recieved from the server as XML.

Can be null if nothing is recieved or if it is already parsed.


Implementation
    public function get xml():XML
Constructor Detail
RoundtripEvent()Constructor
public function RoundtripEvent(type:String, xml:XML = null, graph:IGraph = null, bubbles:Boolean = false, cancelable:Boolean = false)

Creates a new instance.

Parameters
type:String — The event type.
 
xml:XML (default = null) — The loaded XML.
 
graph:IGraph (default = null) — The IGraph instance to which the graph is read.
 
bubbles:Boolean (default = false) — Whether this event bubbles.
 
cancelable:Boolean (default = false) — Whether this even is cancelable.
Method Detail
clone()method
override public function clone():Event

Returns
Event
Constant Detail
GRAPH_PARSEDConstant
public static const GRAPH_PARSED:String = graphParsed

Dispatched after the GraphML was parsed.

Note that usually the graph is a temporary graph and not the visible graph. The graph can be retrieved in the graph property.

ROUNDTRIP_COMPLETEConstant 
public static const ROUNDTRIP_COMPLETE:String = roundtripComplete

Dispatched after the roundtrip is completed and the new graph is stored in the GraphCanvasComponent graph.

The graph can be retrieved in the graph property.

XML_LOADEDConstant 
public static const XML_LOADED:String = xmlLoaded

Dispatched when the response GraphML is completely loaded but not yet parsed.

The loaded XML can be retrieved in the xml property.

XML_SERIALIZEDConstant 
public static const XML_SERIALIZED:String = xmlSerialized

Dispatched when the graph is serialized as GraphML before sending.

The serialized XML can be retrieved in the xml property.