Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Private Attributes
XPCDispInterface::Member::ParamInfo Class Reference

Parameter Information. More...

#include <XPCDispPrivate.h>

List of all members.

Public Member Functions

 ParamInfo (const ELEMDESC *paramInfo)
 Initializes mParamInfo to the element description passed in.
JSBool InitializeOutputParam (void *varBuffer, VARIANT &var) const
 Initializes an output parameter.
PRBool IsFlagSet (unsigned short flag) const
 Tests if a specific flag is set.
PRBool IsIn () const
 Returns true if this is an input parameter.
PRBool IsOut () const
 Returns true if this is an output parameter.
PRBool IsOptional () const
 Returns true if this is an optional parameter.
PRBool IsRetVal () const
 Returns true if this is a return value parameter.
VARTYPE GetType () const
 Returns the type of the parameter.

Private Attributes

const ELEMDESC * mParamInfo

Detailed Description

Parameter Information.

This class is mainly a wrapper around ELEMDESC that allows easier inspection

Definition at line 701 of file XPCDispPrivate.h.


Constructor & Destructor Documentation

XPCDispInterface::Member::ParamInfo::ParamInfo ( const ELEMDESC *  paramInfo) [inline]

Initializes mParamInfo to the element description passed in.

Parameters:
paramInfothe parameter information being wrapped

Definition at line 54 of file XPCDispInlines.h.

                                : mParamInfo(paramInfo) 
{
}

Member Function Documentation

VARTYPE XPCDispInterface::Member::ParamInfo::GetType ( void  ) const [inline]

Returns the type of the parameter.

Returns:
VARTYPE, the type of the parameter

Definition at line 101 of file XPCDispInlines.h.

{
    return mParamInfo->tdesc.vt == VT_PTR ? mParamInfo->tdesc.lptdesc->vt : mParamInfo->tdesc.vt;
}
JSBool XPCDispInterface::Member::ParamInfo::InitializeOutputParam ( void varBuffer,
VARIANT &  var 
) const [inline]

Initializes an output parameter.

Parameters:
varBuffera pointer to the variant's buffer
varPointer to the variant being initialized

Definition at line 60 of file XPCDispInlines.h.

{
    var.vt = GetType() | VT_BYREF;
    var.byref = varBuffer;
    return JS_TRUE;
}

Here is the caller graph for this function:

PRBool XPCDispInterface::Member::ParamInfo::IsFlagSet ( unsigned short  flag) const [inline]

Tests if a specific flag is set.

Parameters:
flagthe flag to be tested
Returns:
true if the flag is set

Definition at line 69 of file XPCDispInlines.h.

{
    return mParamInfo->paramdesc.wParamFlags & flag ? PR_TRUE : PR_FALSE; 
}

Returns true if this is an input parameter.

Returns:
true if this is an input parameter

Definition at line 76 of file XPCDispInlines.h.

{
    return IsFlagSet(PARAMFLAG_FIN) || mParamInfo->paramdesc.wParamFlags == 0;
}

Here is the call graph for this function:

Here is the caller graph for this function:

Returns true if this is an optional parameter.

Returns:
true if this is an optional parameter

Definition at line 88 of file XPCDispInlines.h.

{
    return IsFlagSet(PARAMFLAG_FOPT);
}

Here is the call graph for this function:

Returns true if this is an output parameter.

Returns:
true if this is an output parameter

Definition at line 82 of file XPCDispInlines.h.

{
    return IsFlagSet(PARAMFLAG_FOUT);
}

Here is the call graph for this function:

Here is the caller graph for this function:

Returns true if this is a return value parameter.

Returns:
true if this is a return value parameter

Definition at line 94 of file XPCDispInlines.h.

{
    return IsFlagSet(PARAMFLAG_FRETVAL);
}

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Definition at line 749 of file XPCDispPrivate.h.


The documentation for this class was generated from the following files: