somGetNthMethodData
From EDM2
This method returns method information for the nth (static or dynamic) method known to a given class. Not generally overridden.
For backward compatibility, this method does not take an Environment parameter.
- Original Class
- SOMClass
Contents
Syntax
boolean somGetNthMethodData (SOMClass receiver, long index, somMethodData md)
Parameters
- receiver (SOMClass)
- A pointer to the class that produced the index value.
- index (long)
- An index returned as a result of a previous call of somGetMethodIndex.
- md (somMethodData)
- A pointer to a somMethodData structure.
Return Code
- rc (boolean)
- true Returns boolean true if successful.
- false Returns false if not successful.
Remarks
This method loads a somMethodData structure with data describing the method identified by the passed index. The index must have been produced by a previous call to exactly the same receiver class; the same method will in general have different indexes in different classes. If the index does not identify a method known to this class, then false is returned; otherwise, true is returned after loading the somMethodData structure with data corresponding to the indicated method.
Example Code
#include <somcls.xh> main { somEnvironmentNew(); somId gmiId = somIdFromString("somGetMethodIndex"); long index = _SOMClass->somGetMethodIndex(gmiId); somMethodData md; boolean rc = _SOMClass->somGetNthMethodData(index,&md); SOM_Test(rc && somCompareIds(gmiId, md.id)); }
Related
Data Structures
- somMethodData (somapi.h)