FindCustAttribOwnerDEP Class Reference

FindCustAttribOwnerDEP Class Reference

#include <mxsCustomAttributes.h>

+ Inheritance diagram for FindCustAttribOwnerDEP:

Public Member Functions

 FindCustAttribOwnerDEP (CustAttrib *ca)
 
int proc (ReferenceMaker *rmaker)
 This is the method called by system from ReferenceTarget::DoEnumDependentsImpl(). More...
 
- Public Member Functions inherited from DependentEnumProc
CoreExport bool CheckIfAndSetAsVisited (ReferenceMaker *rmaker)
 This method sets and checks whether a ReferenceMaker was visited. More...
 

Public Attributes

ReferenceMakerrm
 
CustAttribtarg_ca
 

Additional Inherited Members

- Static Public Member Functions inherited from MaxHeapOperators
static UtilExport voidoperator new (size_t size)
 Standard new operator used to allocate objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e)
 Standard new operator used to allocate objects if there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate objects that takes the type of memory, filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate arrays of objects. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport void operator delete (void *ptr)
 Standard delete operator used to deallocate an object If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an object If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an object that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, void *placement_ptr)
 Placement new operator. More...
 
static UtilExport void operator delete (void *ptr, void *placement_ptr)
 Placement delete operator. More...
 
- Protected Member Functions inherited from DependentEnumProc
CoreExport DependentEnumProc ()
 
virtual CoreExport ~DependentEnumProc ()
 
 DependentEnumProc (const DependentEnumProc &)
 
DependentEnumProcoperator= (const DependentEnumProc &rhs)
 

Constructor & Destructor Documentation

205 { rm = NULL; targ_ca = ca; }
ReferenceMaker * rm
Definition: mxsCustomAttributes.h:203
#define NULL
Definition: autoptr.h:18
CustAttrib * targ_ca
Definition: mxsCustomAttributes.h:204

Member Function Documentation

int proc ( ReferenceMaker rmaker)
inlinevirtual

This is the method called by system from ReferenceTarget::DoEnumDependentsImpl().

Parameters
rmaker- A pointer to the reference maker
Returns
One of the following values:
  • DEP_ENUM_CONTINUE: This continues the enumeration
  • DEP_ENUM_HALT: This stops the enumeration.
  • DEP_ENUM_SKIP: Reference Targets can have multiple Reference Makers (dependents). In certain instances when DoEnumDependents() is used to enumerate them you may not want to travel up all of the "branches". By returning DEP_ENUM_SKIP from this method you tell the enumerator to not enumerate the current Reference Maker's dependents but not to halt the enumeration completely.
See also
ReferenceTarget::DoEnumDependentsImpl(DependentEnumProc* dep)
ReferenceTarget::DoEnumDependents(DependentEnumProc* dep)

Implements DependentEnumProc.

207  {
208  if (rmaker == targ_ca)
209  return DEP_ENUM_CONTINUE;
210 
211  // russom - 08/27/04 - 579271
212  // Make sure we only eval real dependencies.
213  // Note: We might need to also add a SKIP for restore class ids, but that
214  // is not part of this defect fix.
215  if( !rmaker->IsRealDependency(targ_ca) )
216  return DEP_ENUM_SKIP;
217 
218  if (rmaker->ClassID() == CUSTATTRIB_CONTAINER_CLASS_ID )
219  {
221  Animatable* owner = cac->GetOwner();
222  if (owner)
223  {
224  SClass_ID sid = owner->SuperClassID();
226  {
227  for (int j = 0; j < cac->GetNumCustAttribs(); j++)
228  {
229  CustAttrib* ca = cac->GetCustAttrib(j);
230  if (ca == targ_ca)
231  {
232  rm = (ReferenceMaker*)owner;
233  return DEP_ENUM_HALT;
234  }
235  }
236  }
237  }
238  }
239  return DEP_ENUM_SKIP; // only need to look at immediate dependents
240  }
#define DEP_ENUM_SKIP
Skip enumeration.
Definition: ref.h:942
virtual CoreExport Class_ID ClassID()
Retrieves a constant that uniquely identifies the plugin class.
Definition: custattrib.h:32
ReferenceMaker * rm
Definition: mxsCustomAttributes.h:203
#define DEP_ENUM_HALT
Halts enumeration.
Definition: ref.h:940
Definition: Animatable.h:121
virtual CustAttrib * GetCustAttrib(int i)=0
ULONG SClass_ID
Definition: maxtypes.h:191
#define CUSTATTRIB_CONTAINER_CLASS_ID
Definition: plugapi.h:487
virtual Animatable * GetOwner()=0
virtual BOOL IsRealDependency(ReferenceTarget *rtarg)
Returns whether this is a "real" (strong) dependency or not.
Definition: ref.h:1639
#define DELREF_REST_CLASS_ID
Definition: plugapi.h:348
A scene entity that owns other scene entities and listens to messages from them.
Definition: ref.h:1116
#define MAKEREF_REST_CLASS_ID
Definition: plugapi.h:347
virtual int GetNumCustAttribs()=0
CustAttrib * targ_ca
Definition: mxsCustomAttributes.h:204
#define MAXSCRIPT_WRAPPER_CLASS_ID
Definition: plugapi.h:345
#define DEP_ENUM_CONTINUE
Continues enumeration.
Definition: ref.h:938
virtual CoreExport SClass_ID SuperClassID()=0
Retrieves a constant representing the type of the plugin.
Definition: icustattribcontainer.h:25

Member Data Documentation

CustAttrib* targ_ca