1-96 SOMobjects Base Toolkit: Programmer’s Reference Manual
somGetNumStaticMethods Method
Purpose
Obtains the number of static methods available for a class. Not generally overridden.
IDL Syntax
long somGetNumStaticMethods ( );
Note: For backward compatibility, this method does not take an Environment parameter.
Description
The somGetNumStaticMethods method returns the number of static methods available in
the specified class, including inherited ones. Static methods are those that are represented
by entries in the class’s instance method table, and which can be invoked using method
tokens and offset resolution.
Parameters
receiver A pointer to the class whose static method count is desired.
Return Value
The somGetNumStaticMethods method returns the total number of static methods that
are available for instances of the receiving class.
C Example
#include <animal.h>
main()
{
int numMethods;
AnimalNewClass(Animal_MajorVersion, Animal_MinorVersion);
numMethods = _somGetNumStaticMethods(_Animal);
somPrintf(”Number of static methods supported by class:
%d\n”,
numMethods);
}
Original Class
SOMClass
Related Information
Methods: somGetNumMethods
Komentarze do niniejszej Instrukcji