maxscript/macros/define_abstract_functions.h File Reference

Macros

#define def_generic(fn, name)   virtual Value* fn##_vf(Value** arglist, int arg_count) { ABSTRACT_FUNCTION(_M(#name), this, Value*); }
 
#define def_visible_generic(fn, name)   def_generic(fn, name)
 
#define def_struct_generic(fn, name)   def_generic(fn, name)
 
#define def_node_generic(fn, name)   def_generic(fn, name)
 
#define def_mapped_generic(fn, name)   def_generic(fn, name)
 
#define use_generic(fn, name)
 
#define def_generic_debug_ok(fn, name)   def_generic(fn, name)
 
#define def_visible_generic_debug_ok(fn, name)   def_generic(fn, name)
 
#define def_struct_generic_debug_ok(fn, name)   def_generic(fn, name)
 
#define def_node_generic_debug_ok(fn, name)   def_generic(fn, name)
 
#define def_mapped_generic_debug_ok(fn, name)   def_generic(fn, name)
 
#define def_primitive(fn, name)
 
#define def_visible_primitive(fn, name)
 
#define def_mapped_primitive(fn, name)
 
#define def_lazy_primitive(fn, name)
 
#define def_visible_lazy_primitive(fn, name)
 
#define def_struct_primitive(fn, _struct, name)
 
#define def_primitive_debug_ok(fn, name)
 
#define def_visible_primitive_debug_ok(fn, name)
 
#define def_mapped_primitive_debug_ok(fn, name)
 
#define def_lazy_primitive_debug_ok(fn, name)
 
#define def_visible_lazy_primitive_debug_ok(fn, name)
 
#define def_struct_primitive_debug_ok(fn, _struct, name)
 
#define def_property(p)
 
#define def_property_alias(p, real_p)
 
#define def_2_prop_path(p1, p2)
 
#define def_2_prop_path_alias(p1, p2, real_p1, real_p2)
 
#define def_nested_prop(p1)
 
#define def_nested_prop_alias(p1, real_p1)
 
#define ABSTRACT_FUNCTION(m, v, t)   throw NoMethodError (m, v); return (t)0
 
#define ABSTRACT_CONVERTER(t, l)   throw ConversionError (this, _M(#l)); return (t)0
 
#define ABSTRACT_WIDENER(a)   throw IncompatibleTypes (this, a); return (Value*)&undefined
 
#define ABSTRACT_GETTER()   throw AccessorError (this, arg_list[0]); return (Value*)&undefined
 
#define ABSTRACT_SETTER()   throw AccessorError (this, arg_list[1]); return (Value*)&undefined
 

Macro Definition Documentation

#define def_generic (   fn,
  name 
)    virtual Value* fn##_vf(Value** arglist, int arg_count) { ABSTRACT_FUNCTION(_M(#name), this, Value*); }
#define def_visible_generic (   fn,
  name 
)    def_generic(fn, name)
#define def_struct_generic (   fn,
  name 
)    def_generic(fn, name)
#define def_node_generic (   fn,
  name 
)    def_generic(fn, name)
#define def_mapped_generic (   fn,
  name 
)    def_generic(fn, name)
#define use_generic (   fn,
  name 
)
#define def_generic_debug_ok (   fn,
  name 
)    def_generic(fn, name)
#define def_visible_generic_debug_ok (   fn,
  name 
)    def_generic(fn, name)
#define def_struct_generic_debug_ok (   fn,
  name 
)    def_generic(fn, name)
#define def_node_generic_debug_ok (   fn,
  name 
)    def_generic(fn, name)
#define def_mapped_generic_debug_ok (   fn,
  name 
)    def_generic(fn, name)
#define def_primitive (   fn,
  name 
)
#define def_visible_primitive (   fn,
  name 
)
#define def_mapped_primitive (   fn,
  name 
)
#define def_lazy_primitive (   fn,
  name 
)
#define def_visible_lazy_primitive (   fn,
  name 
)
#define def_struct_primitive (   fn,
  _struct,
  name 
)
#define def_primitive_debug_ok (   fn,
  name 
)
#define def_visible_primitive_debug_ok (   fn,
  name 
)
#define def_mapped_primitive_debug_ok (   fn,
  name 
)
#define def_lazy_primitive_debug_ok (   fn,
  name 
)
#define def_visible_lazy_primitive_debug_ok (   fn,
  name 
)
#define def_struct_primitive_debug_ok (   fn,
  _struct,
  name 
)
#define def_property (   p)
Value:
virtual Value* get_##p(Value** arg_list, int count) { return get_property(arg_list, count); } \
virtual Value* set_##p(Value** arg_list, int count) { return set_property(arg_list, count); }
Definition: value.h:106
#define def_property_alias (   p,
  real_p 
)
#define def_2_prop_path (   p1,
  p2 
)
Value:
virtual Value* get_##p1##_##p2(Value** arg_list, int count) \
{ \
two_value_locals(cont, result); \
vl.cont = get_##p1(&n_##p1, 1); \
vl.result = vl.cont->get_##p2(&n_##p2, 1); \
return_value(vl.result); \
} \
virtual Value* set_##p1##_##p2(Value** arg_list, int count) \
{ \
Value* args[2] = { arg_list[0], n_##p2 }; \
vl.cont = get_##p1(&n_##p1, 1); \
vl.cont->set_##p2(args, 2); \
args[0] = vl.cont; args[1] = n_##p1; \
set_##p1(args, 2); \
return arg_list[0]; \
}
#define one_value_local(n1)
Definition: value_locals.h:28
Definition: value.h:106
#define return_value(r)
Definition: value_locals.h:220
#define two_value_locals(n1, n2)
Definition: value_locals.h:56
#define def_2_prop_path_alias (   p1,
  p2,
  real_p1,
  real_p2 
)
#define def_nested_prop (   p1)
Value:
virtual Value* get_nested_##p1(Value** arg_list, int count) \
{ \
two_value_locals(cont, result); \
vl.cont = _get_property(arg_list[0]); \
vl.result = vl.cont->get_##p1(&n_##p1, 1); \
return_value(vl.result); \
} \
virtual Value* set_nested_##p1(Value** arg_list, int count) \
{ \
Value* args[2] = { arg_list[0], n_##p1 }; \
vl.cont = _get_property(arg_list[1]); \
vl.cont->set_##p1(args, 2); \
_set_property(arg_list[1], vl.cont); \
return arg_list[0]; \
}
#define one_value_local(n1)
Definition: value_locals.h:28
Definition: value.h:106
#define return_value(r)
Definition: value_locals.h:220
#define two_value_locals(n1, n2)
Definition: value_locals.h:56
#define def_nested_prop_alias (   p1,
  real_p1 
)
#define ABSTRACT_FUNCTION (   m,
  v,
 
)    throw NoMethodError (m, v); return (t)0
#define ABSTRACT_CONVERTER (   t,
 
)    throw ConversionError (this, _M(#l)); return (t)0
#define ABSTRACT_WIDENER (   a)    throw IncompatibleTypes (this, a); return (Value*)&undefined
#define ABSTRACT_GETTER ( )    throw AccessorError (this, arg_list[0]); return (Value*)&undefined
#define ABSTRACT_SETTER ( )    throw AccessorError (this, arg_list[1]); return (Value*)&undefined