Clarisse 5.0 SP8 SDK  5.0.5.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
OfSerialOptions Struct Reference

Public Types

enum  Mode {
  MODE_NONE = 0,
  MODE_DEFAULT = 1,
  MODE_COPY = 1 << 1,
  MODE_PASTE = 1 << 2,
  MODE_REFERENCE = 1 << 3,
  MODE_RELOAD = 1 << 4,
  MODE_LOAD = 1 << 5,
  MODE_SAVE_ARCHIVE = 1 << 6,
  MODE_EXPORT_PROJECT = 1 << 7,
  MODE_EXPORT_BUILD = 1 << 8,
  MODE_EXPORT_CTX_DEPS = 1 << 9,
  MODE_UNDO = 1 << 10,
  MODE_FORCE_SAVE_PROJECT = 1 << 11
}
 
enum  ModePasteAdvanced {
  PASTE_DEFAULT = 0,
  PASTE_ATTR,
  PASTE_ATTR_VALUE,
  PASTE_ATTR_ANIMATION,
  PASTE_ATTR_EXPRESSION,
  PASTE_ATTR_TEXTURE,
  PASTE_ATTR_SHADING_VARIABLE
}
 
enum  Object {
  OBJECT_NAME_ONLY = 0,
  OBJECT_NAME_PREFIX = 1,
  OBJECT_NAME_SUFFIX = 2
}
 
enum  Reference {
  REFERENCE_PATH_ABSOLUTE,
  REFERENCE_PATH_RELATIVE
}
 

Public Member Functions

 OfSerialOptions ()
 default constructor
 
 OfSerialOptions (const OfSerialOptions &options)
 copy constructor
 
 OfSerialOptions (OfApp &app, const Mode &mode=MODE_DEFAULT, bool is_app_resources=false)
 constructor
 
const OfSerialOptionsoperator= (const OfSerialOptions &options)
 
CoreString get_item_path (const CoreString &serial_path) const
 
double get_project_version () const
 
double get_object_framework_version () const
 
void set_project_version (const double &version)
 
void set_object_framework_version (const double &version)
 
void set_nb_load (int nb)
 
void set_use_nb_load (bool state)
 
bool can_load () const
 
void decrement_nb_load () const
 
void add_project_resources (const ParserGroup &root)
 add all resources serialization under the given group in the options resource list
 

Static Public Member Functions

static CoreString get_mode_paste_label (const ModePasteAdvanced &id)
 
static void create_default_options (OfApp &app)
 
static const OfSerialOptionsget_default ()
 

Public Attributes

int mode
 
ModePasteAdvanced mode_paste_advanced = PASTE_DEFAULT
 
struct {
CoreString filename
 
file
 
struct {
CoreString file_pdir
 
vars
 
struct {
CoreString default_name
 
CoreString name
 
OfContextcontext = nullptr
 
root
 
struct {
int name
 
CoreString prefix
 
CoreString suffix
 
object
 
struct {
CoreString table_name
 
int reference_path
 
int value_page = 0
 
bool force_group_serialization = false
 if true, attributes will always be serialized in a group
 
bool skip_value = false
 value is not serialized even if localized and changed
 
bool dump_value = false
 value is serialized even if not localized and same as prototype
 
bool compact_custom = false
 
bool reset_undeserialized_locals = true
 
int skip_flags = 0
 
attribute
 
struct {
CoreHashTable< CoreString,
OfObject * > 
copies_object
 
CoreHashTable< CoreString,
OfContext * > 
copies_context
 
CoreHashTable< OfObject
*, CoreString
copies_object_inv
 
CoreHashTable< OfContext
*, CoreString
copies_context_inv
 
paste
 
struct {
CoreHashTable< CoreString,
CoreString
dependencies_update
 
OfContextroot
 
export_with_dependencies
 
struct {
bool is_app_resources
 
CoreHashTable< CoreString,
ParserEntry * > * 
project_resources
 
resources
 

Member Enumeration Documentation

Enumerator:
PASTE_DEFAULT 

Default value, when mode is not MODE_PASTE. Used also when mode is MODE_PASTE to paste the whole object.

PASTE_ATTR 

Paste the whole attribute and its modifiers. Only used when mode is MODE_PASTE

PASTE_ATTR_VALUE 

Paste only the values. Only used when mode is MODE_PASTE

PASTE_ATTR_ANIMATION 

Paste only the curves. Only used when mode is MODE_PASTE

PASTE_ATTR_EXPRESSION 

Paste only the expressions. Only used when mode is MODE_PASTE

PASTE_ATTR_TEXTURE 

Paste only the texture. Only used when mode is MODE_PASTE

PASTE_ATTR_SHADING_VARIABLE 

Paste only the shading variables. Only used when mode is MODE_PASTE

Constructor & Destructor Documentation

OfSerialOptions::OfSerialOptions ( OfApp app,
const Mode &  mde = MODE_DEFAULT,
bool  is_app_resources = false 
)

constructor

Parameters
appthe application
mdethe serial mode
is_app_resourcesdefine if the serializations of resources must be shared with those stored in the application

Member Function Documentation

CoreString OfSerialOptions::get_item_path ( const CoreString serial_path) const

When serializing it converts the given item path to a valid serial path When deserializing it converts the given serial path to a valid item path