Rebel Fork Framework
Urho3D::PrefabWriter Class Referenceabstract

#include <Urho3D/Scene/PrefabWriter.h>

Inheritance diagram for Urho3D::PrefabWriter:
Urho3D::NonCopyable Urho3D::PrefabWriterToArchive Urho3D::PrefabWriterToMemory

Public Member Functions

virtual void WriteNode (unsigned id, const Serializable *node)=0
 
virtual void WriteNumComponents (unsigned numComponents)=0
 
virtual void WriteComponent (unsigned id, const Serializable *component)=0
 
virtual void WriteNumChildren (unsigned numChildren)=0
 
virtual void BeginChild ()=0
 
virtual void EndChild ()=0
 
virtual bool IsEOF () const =0
 
virtual PrefabSaveFlags GetFlags () const =0
 

Additional Inherited Members

- Protected Member Functions inherited from Urho3D::NonCopyable
 NonCopyable (const NonCopyable &other)=delete
 
 NonCopyable (NonCopyable &&other)=delete
 
NonCopyableoperator= (const NonCopyable &other)=delete
 
NonCopyableoperator= (NonCopyable &&other)=delete
 

Detailed Description

Interface of a class that writes prefab data. Useful for writing generic code in Node and Scene serialization. Call order:

  • WriteNode() should be called first exactly once.
  • WriteNumComponents() should be called after WriteNode() exactly once.
  • WriteComponent() should be called after WriteNumComponents() the exact number of times.
  • WriteNumChildren() should be called after all calls to WriteComponent() exactly once.
  • BeginChild() and then EndChild() should be called after WriteNumChildren() the exact number of times.
  • The sequence above should be recursively repeated between BeginChild() and EndChild().

The documentation for this class was generated from the following file: