FPInterface Class Reference

#include <ifnpub.h>

Class Description

See also
Class BaseInterface, Class ClassDesc, Class FPInterfaceDesc, Class Interface_ID, Class ActionTable, FPStatus values, Function Publishing.

Description:
The Function Publishing system makes use of this class. Functions are published in one or more Interfaces by a plug-in. Each interface is represented by an instance of a class derived from this base class.

Note that the Function Publishing class hierarchy is as follows:

FPInterface: This is the base class for all interfaces, the prime client type for using interfaces.

FPInterfaceDesc: This is the class which contains interface metadata.

FPStaticInterface: This is the class to use as the base class for defining static or core virtual interface classes.

FPMixinInterface: This is for use as the base class for defining object-based mixin interface classes, in this case you also use FPInterfaceDesc for mixin interface descriptors.
+ Inheritance diagram for FPInterface:

Public Member Functions

virtual BaseInterfaceGetInterface (Interface_ID id)
 
virtual FPInterfaceDescGetDesc ()=0
 
virtual CoreExport FPStatus Invoke (FunctionID fid, TimeValue t=0, FPParams *params=NULL)
 
virtual FPStatus Invoke (FunctionID fid, FPParams *params)
 
virtual CoreExport FPStatus Invoke (FunctionID fid, TimeValue t, FPValue &result, FPParams *params=NULL)
 
virtual FPStatus Invoke (FunctionID fid, FPValue &result, FPParams *params=NULL)
 
virtual CoreExport FunctionID FindFn (const MCHAR *name)
 
virtual CoreExport BOOL IsEnabled (FunctionID actionID)
 
virtual CoreExport BOOL IsChecked (FunctionID actionID)
 
virtual CoreExport BOOL IsVisible (FunctionID actionID)
 
virtual CoreExport FunctionID GetIsEnabled (FunctionID actionID)
 
virtual CoreExport FunctionID GetIsChecked (FunctionID actionID)
 
virtual CoreExport FunctionID GetIsVisible (FunctionID actionID)
 
virtual ActionTableGetActionTable ()
 
virtual void EnableActions (BOOL onOff)
 
- Public Member Functions inherited from BaseInterface
virtual UtilExport ~BaseInterface ()
 Destructor. More...
 
virtual UtilExport Interface_ID GetID ()
 
virtual LifetimeType LifetimeControl ()
 
virtual bool RegisterNotifyCallback (InterfaceNotifyCallback *incb)
 
virtual void UnRegisterNotifyCallback (InterfaceNotifyCallback *incb)
 
virtual BaseInterfaceAcquireInterface ()
 
virtual void ReleaseInterface ()
 
virtual void DeleteInterface ()
 
virtual BaseInterfaceCloneInterface (void *remapDir=NULL)
 
- Public Member Functions inherited from InterfaceServer
virtual UtilExport ~InterfaceServer ()
 Destructor. More...
 

Static Public Attributes

static CoreExport FPInterfaceDesc nullInterface
 

Protected Member Functions

virtual FPStatus _dispatch_fn (FunctionID fid, TimeValue t, FPValue &result, FPParams *p)
 

Additional Inherited Members

- Public Types inherited from BaseInterface
enum  LifetimeType { noRelease, immediateRelease, wantsRelease, serverControlled }
 
- 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...
 
static UtilExport voidaligned_malloc (size_t size, size_t alignment)
 Allocates memory on a specified alignment boundary. More...
 
static UtilExport voidaligned_realloc (void *ptr, size_t size, size_t alignment)
 Reallocates memory on a specified alignment boundary. More...
 
static UtilExport void aligned_free (void *ptr)
 Frees a block of memory that was allocated with aligned_malloc/aligned_realloc. More...
 

Member Function Documentation

virtual FPStatus _dispatch_fn ( FunctionID  fid,
TimeValue  t,
FPValue result,
FPParams p 
)
inlineprotectedvirtual
136 { return FPS_NO_SUCH_FUNCTION; }
#define FPS_NO_SUCH_FUNCTION
The function called does not exist.
Definition: ifnpub.h:102
virtual BaseInterface* GetInterface ( Interface_ID  id)
inlinevirtual
Remarks
Returns a pointer to the interface whose ID is specified.
Parameters:
Interface_ID id

The ID of the interface to return.
Default Implementation:
{ return NULL; }

Reimplemented from BaseInterface.

Reimplemented in Interface, INode, SimpleManipulator, ITreeView, ActionTable, ITrackBar, FPMixinInterface, FPInterfaceDesc, ActionItem, UnifiedRenderer, AssetUser, PFSimpleTest, PFSimpleAction, IMaterialBrowserEntryInfo, PFSimpleOperator, and PFSimpleActionState.

143  {
144  if (id == FPINTERFACE_ID) return this;
145  else if (id == FPINTERFACEDESC_ID) return (BaseInterface*)GetDesc();
146  else return BaseInterface::GetInterface(id);
147  }
#define FPINTERFACEDESC_ID
Definition: ifnpub.h:62
Definition: baseinterface.h:67
#define FPINTERFACE_ID
Definition: ifnpub.h:60
virtual FPInterfaceDesc * GetDesc()=0
UtilExport BaseInterface * GetInterface(Interface_ID id)
virtual FPInterfaceDesc* GetDesc ( )
pure virtual
Remarks
Returns a pointer to the class which contains the interface metadata.

Implemented in ISplineIKControl, IListControl, ILinkCtrl, ILookAtConstRotation, IOrientConstRotation, IUnwrapMod4, IPosConstPosition, IUnwrapMod3, IPathPosition, IUnwrapMod2, IRotWindup, INode, IMXSParticleContainer, BitmapTex, ISimpleManipulator, ITrackBar, ActionTable, IUnwrapMod, IParticleObjectExt, ITreeViewOps, EPolyMod, EPoly, NodeAndAnims, FPInterfaceDesc, ILayerControl, XMLAnimTreeEntryList, ActionItem, ISkinPose, IPopulateFlow, IParticleChannelMapW, IXRefObject8, IScanRenderer2, IObjXRefRecord, IPFAction, ILagMod, IBaseWireControl, IParticleGroup, IPFSystem, IXRefItem, IMorphByBone, IParticleChannel, IPViewManager, IPViewItem, IParticleCache, GizmoShape, ITreeViewUI, XMLAnimTreeEntry, IChannelContainer, INodeExposure, IPointCacheWSM, IParticleChannelAmountW, AssetUser, IPFTest, IEditNormalsMod, IPFActionListMaterialHolder, IPFViewport, IPFIntegrator, IPFOperator, IParticleChannelIDW, IParticleChannelMeshMapW, IScriptCtrl, IParticleChannelMeshW, IParticleChannelNewW, IParticleChannelPTVW, IPFRender, IParticleChannelTabUVVertW, IPointCloud, IParticleChannelTabTVFaceW, IPointCache, IVisualMSCallback, IXRefProxy, IParticleChannelMapR, IParticleChannelQuatW, IParticleChannelAngAxisW, IParticleChannelMatrix3W, Plane, IParticleChannelIntW, IParticleChannelBoolW, IParticleChannelFloatW, IParticleChannelINodeW, IParticleChannelINodeHandleW, IParticleChannelVoidW, RealWorldMapSizeInterface, IParticleChannelPoint3W, IPFArrow, IParticleChannelIDR, IPFActionListPool, IBrowser, IVisualMSItem, IPFSystemPool, IParticleChannelPTVR, IContainerObject, IAnimTrack, IPFActionList, IPFActionState, CheckAbortCallback, INodeTransformMonitor, IParticleChannelMeshR, IPFActionExt, IParticleChannelNewR, IParticleChannelTabTVFaceR, IJiggle, IParticleChannelQuatR, IXRefAtmospheric, IParticleChannelAngAxisR, IParticleChannelMatrix3R, IParticleChannelIntR, IParticleChannelMeshMapR, IParticleChannelBoolR, IParticleChannelFloatR, IParticleChannelINodeR, IParticleChannelVoidR, IPFOperatorPhysXWorld, ILimitControl, IParticleChannelPoint3R, IParticleChannelTabUVVertR, IParticleChannelINodeHandleR, IXRefCtrl, IXRefMaterial, IParticleChannelAmountR, IRefTargMonitorClass, IParticleChannelExt, IParticleChannelTrueFalseIterator, IVisualMSForm, IBlobMesh, INodeMonitor, IParticleGroupExt, IPFActionListSet, IMaterialBrowserEntryInfo, IViewportShaderManager, IParticleChannelExt2, IPViewItemCreator, IParticleChannelTrueFalseIterator2, IPatchDeformPWMod, and IMeshDeformPWMod.

virtual CoreExport FPStatus Invoke ( FunctionID  fid,
TimeValue  t = 0,
FPParams params = NULL 
)
virtual
Remarks
Parameters:
FunctionID fid

The function ID of the function to invoke.

TimeValue t=0

The timevalue at which to invoke the function.

FPParams* params=NULL

The FPParams to pass.
Returns
The FPStatus. See FPStatus values for details
virtual FPStatus Invoke ( FunctionID  fid,
FPParams params 
)
inlinevirtual
Remarks
This method will invoke the specified function.
Parameters:
FunctionID fid

The function ID of the function to invoke.

FPParams* params

The FPParams to pass.
Returns
The FPStatus. See FPStatus values for details
172 { return Invoke(fid, 0, params); }
virtual CoreExport FPStatus Invoke(FunctionID fid, TimeValue t=0, FPParams *params=NULL)
virtual CoreExport FPStatus Invoke ( FunctionID  fid,
TimeValue  t,
FPValue result,
FPParams params = NULL 
)
virtual
Remarks
This method will invoke the specified function.
Parameters:
FunctionID fid

The function ID of the function to invoke.

TimeValue t

The timevalue at which to invoke the function.

FPValue& result

A reference to the resulting FPValue.

FPParams* params=NULL

The FPParams to pass.
Returns
The FPStatus. See FPStatus values for details
virtual FPStatus Invoke ( FunctionID  fid,
FPValue result,
FPParams params = NULL 
)
inlinevirtual
Remarks
This method will invoke the specified function.
Parameters:
FunctionID fid

The function ID of the function to invoke.

FPValue& result

A reference to the resulting FPValue.

FPParams* params=NULL

The FPParams to pass.
Returns
The FPStatus. See FPStatus values for details
194 { return Invoke(fid, 0, result, params); }
virtual CoreExport FPStatus Invoke(FunctionID fid, TimeValue t=0, FPParams *params=NULL)
virtual CoreExport FunctionID FindFn ( const MCHAR name)
virtual
Remarks
This method returns a function ID based on the name of the function specified.
Parameters:
MCHAR* name

The name of the function to retrieve the Function ID for.
virtual CoreExport BOOL IsEnabled ( FunctionID  actionID)
virtual
Remarks
This method allows you to check whether a specific action function is enabled, in which case the method will return TRUE. If the action function is not enabled FALSE will be returned.
Parameters:
FunctionID actionID

The function ID of the action you wish to check the enabled state for.
virtual CoreExport BOOL IsChecked ( FunctionID  actionID)
virtual
Remarks
This method allows you to check whether a specific action function is checked, in which case the method will return TRUE. If the action function is not checked FALSE will be returned.
Parameters:
FunctionID actionID

The function ID of the action you wish to check the checked state for.
virtual CoreExport BOOL IsVisible ( FunctionID  actionID)
virtual
Remarks
This method allows you to check whether a specific action function is visible, in which case the method will return TRUE. If the action function is not visible FALSE will be returned.
Parameters:
FunctionID actionID

The function ID of the action you wish to check the visibility state for.
virtual CoreExport FunctionID GetIsEnabled ( FunctionID  actionID)
virtual
Remarks
This method will return the isEnabled ID for the specified action function.
Parameters:
FunctionID actionID

The function ID of the action you wish to get the isEnabled ID for.
virtual CoreExport FunctionID GetIsChecked ( FunctionID  actionID)
virtual
Remarks
This method will return the isChecked ID for the specified action function.
Parameters:
FunctionID actionID

The function ID of the action you wish to get the isChecked ID for.
virtual CoreExport FunctionID GetIsVisible ( FunctionID  actionID)
virtual
Remarks
This method will return the isVisible ID for the specified action function.
Parameters:
FunctionID actionID

The function ID of the action you wish to get the isVisible ID for.
virtual ActionTable* GetActionTable ( )
inlinevirtual
Remarks
This method returns a pointer to the ActionTable.
Default Implementation:
{ return NULL; }

Reimplemented in FPInterfaceDesc.

248 { return NULL; }
#define NULL
Definition: autoptr.h:18
virtual void EnableActions ( BOOL  onOff)
inlinevirtual
Remarks
This method allows you to enable or disable the entire set of actions in the interface You might want to use this method if the actions are only to be active during certain periods in the running of 3ds Max. Usually, this control is achieved via ActionTable contexts.
Parameters:
BOOL onOff

TRUE to enable actions, FALSE to disable them.
Default Implementation:
{ }

Reimplemented in FPInterfaceDesc.

259 { UNUSED_PARAM(onOff); }
#define UNUSED_PARAM(x)
Definition: BuildWarnings.h:18

Member Data Documentation

CoreExport FPInterfaceDesc nullInterface
static