FindMAXWrapperEnum Class Reference

FindMAXWrapperEnum Class Reference

#include <mxsobjects.h>

+ Inheritance diagram for FindMAXWrapperEnum:

Public Member Functions

 FindMAXWrapperEnum (ReferenceTarget *ref, ValueMetaClass *tag, bool(*finalCheckProc)(MAXWrapper *, void *)=NULL, void *arg=NULL)
 
int proc (ReferenceMaker *rm)
 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

Valueresult
 

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

FindMAXWrapperEnum ( ReferenceTarget ref,
ValueMetaClass tag,
bool(*)(MAXWrapper *, void *)  finalCheckProc = NULL,
void arg = NULL 
)
inline
742  {
743  mytag = tag;
744  myref = ref;
745  result = NULL;
746  this->finalCheckProc = finalCheckProc;
747  this->arg = arg;
748  }
#define NULL
Definition: autoptr.h:18
Value * result
Definition: mxsobjects.h:764

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.

750  {
751  if (rm == myref)
752  return DEP_ENUM_CONTINUE;
753  if (rm->SuperClassID() == MAXSCRIPT_WRAPPER_CLASS_ID &&
754  ((MAXWrapper*)rm)->tag == mytag &&
755  rm->NumRefs() && rm->GetReference(0) == myref &&
756  (finalCheckProc == NULL || (*finalCheckProc)((MAXWrapper*)rm, arg))
757  )
758  {
759  result = (MAXWrapper*)rm;
760  return DEP_ENUM_HALT;
761  }
762  return DEP_ENUM_SKIP; // just look at direct dependents
763  }
#define DEP_ENUM_SKIP
Skip enumeration.
Definition: ref.h:942
#define NULL
Definition: autoptr.h:18
Definition: mxsobjects.h:93
#define DEP_ENUM_HALT
Halts enumeration.
Definition: ref.h:940
#define MAXSCRIPT_WRAPPER_CLASS_ID
Definition: plugapi.h:345
#define DEP_ENUM_CONTINUE
Continues enumeration.
Definition: ref.h:938
Value * result
Definition: mxsobjects.h:764

Member Data Documentation

Value* result