2000-05-30 10:30 UTC+0300 Chen Kedem <niki@actcom.co.il>
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2000-05-30 10:30 UTC+0300 Chen Kedem <niki@actcom.co.il>
|
||||
|
||||
* doc/en/objfunc.txt
|
||||
+ Documentation for __objDerivedFrom()
|
||||
|
||||
2000-05-29 21:00 GMT -3 Luiz Rafaek Culik <culik@sl.conex.net>
|
||||
*contrib/libmisc/doc/gendoc.bat
|
||||
contrib/libmisc/doc/gendoc.cmd
|
||||
|
||||
@@ -6,13 +6,13 @@
|
||||
* The following parts are Copyright of the individual authors.
|
||||
* www - http://www.harbour-project.org
|
||||
*
|
||||
* Copyright 1999 Chen Kedem <niki@actcom.co.il>
|
||||
* Copyright 1999-2000 Chen Kedem <niki@actcom.co.il>
|
||||
* Documentation for: __objHasData(), __objHasMethod(), __objGetMsgList(),
|
||||
* __objGetMethodList(), __objGetValueList(),
|
||||
* __ObjSetValueList(), __objAddMethod(),
|
||||
* __objAddInline(), __objAddData(), __objModMethod(),
|
||||
* __objModInline(), __objDelMethod(), __objDelInline(),
|
||||
* __objDelData()
|
||||
* __objDelData(), __objDerivedFrom()
|
||||
*
|
||||
* See doc/license.txt for licensing terms.
|
||||
*
|
||||
@@ -28,15 +28,15 @@
|
||||
* $SYNTAX$
|
||||
* __objHasData( <oObject>, <cSymbol> ) --> lExist
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is an object to scan.
|
||||
* <oObject> is an object to scan.
|
||||
*
|
||||
* <cSymbol> is the name of the symbol to look for.
|
||||
* <cSymbol> is the name of the symbol to look for.
|
||||
* $RETURNS$
|
||||
* __objHasData() return .T. if the given <cSymbol> exist as DATA
|
||||
* (instance variable) in object <oObject), .F. if it does not exist.
|
||||
* (instance variable) in object <oObject), .F. if it does not exist.
|
||||
* $DESCRIPTION$
|
||||
* __objHasData() is a low level class support function that let you
|
||||
* find out if a symbol is an instance variable in a given object.
|
||||
* find out if a symbol is an instance variable in a given object.
|
||||
* $EXAMPLES$
|
||||
* oB := TBrowseNew( 0, 0, 24, 79 )
|
||||
* ? __objHasData( oB, "nLeft" ) // this should return .T.
|
||||
@@ -46,7 +46,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objHasData() is a Harbour extension.
|
||||
* __objHasData() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -64,15 +64,15 @@
|
||||
* $SYNTAX$
|
||||
* __objHasMethod( <oObject>, <cSymbol> ) --> lExist
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is an object to scan.
|
||||
* <oObject> is an object to scan.
|
||||
*
|
||||
* <cSymbol> is the name of the symbol to look for.
|
||||
* <cSymbol> is the name of the symbol to look for.
|
||||
* $RETURNS$
|
||||
* __objHasMethod() return .T. if the given <cSymbol> exist as METHOD
|
||||
* (class function) in object <oObject), .F. if it does not exist.
|
||||
* (class function) in object <oObject), .F. if it does not exist.
|
||||
* $DESCRIPTION$
|
||||
* __objHasMethod() is a low level class support function that let you
|
||||
* find out if a symbol is a class function in a given object.
|
||||
* find out if a symbol is a class function in a given object.
|
||||
* $EXAMPLES$
|
||||
* oB := TBrowseNew( 0, 0, 24, 79 )
|
||||
* ? __objHasMethod( oB, "nLeft" ) // .F. since this is a DATA
|
||||
@@ -82,7 +82,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objHasMethod() is a Harbour extension.
|
||||
* __objHasMethod() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -100,21 +100,21 @@
|
||||
* $SYNTAX$
|
||||
* __objGetMsgList( <oObject>, [<lData>] ) --> aNames
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is an object to scan.
|
||||
* <oObject> is an object to scan.
|
||||
*
|
||||
* <lData> is an optional logical value that specifies the information
|
||||
* to return. A value of .T. instruct the function to return list of
|
||||
* all DATA names, .F. return list of all METHOD names. Default value
|
||||
* is .T.
|
||||
* is .T.
|
||||
* $RETURNS$
|
||||
* __objGetMsgList() return an array of character stings with all DATA
|
||||
* names or all METHOD names for a given object. __objGetMsgList()
|
||||
* would return an empty array {} if the given object does not contain
|
||||
* the requested information.
|
||||
* the requested information.
|
||||
* $DESCRIPTION$
|
||||
* __objGetMsgList() is a low level class support function that let you
|
||||
* find all instance variable or class functions names for a given
|
||||
* object.
|
||||
* object.
|
||||
* $EXAMPLES$
|
||||
* // show information about TBrowse class
|
||||
* oB := TBrowseNew( 0, 0, 24, 79 )
|
||||
@@ -130,7 +130,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objGetMsgList() is a Harbour extension.
|
||||
* __objGetMsgList() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -148,15 +148,15 @@
|
||||
* $SYNTAX$
|
||||
* __objGetMethodList( <oObject> ) --> aMethodNames
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is an object to scan.
|
||||
* <oObject> is an object to scan.
|
||||
* $RETURNS$
|
||||
* __objGetMethodList() return an array of character stings with all
|
||||
* METHOD names for a given object. __objGetMethodList() would return
|
||||
* an empty array {} if the given object does not contain any METHOD.
|
||||
* an empty array {} if the given object does not contain any METHOD.
|
||||
* $DESCRIPTION$
|
||||
* __objGetMethodList() is a low level class support function that let
|
||||
* you find all class functions names for a given object.
|
||||
* It is equivalent to __objGetMsgList( oObject, .F. ).
|
||||
* you find all class functions names for a given object.
|
||||
* It is equivalent to __objGetMsgList( oObject, .F. ).
|
||||
* $EXAMPLES$
|
||||
* // show information about TBrowse class
|
||||
* oB := TBrowseNew( 0, 0, 24, 79 )
|
||||
@@ -168,7 +168,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objGetMethodList() is a Harbour extension.
|
||||
* __objGetMethodList() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -186,20 +186,20 @@
|
||||
* $SYNTAX$
|
||||
* __objGetValueList( <oObject>, [<aExcept>] ) --> aData
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is an object to scan.
|
||||
* <oObject> is an object to scan.
|
||||
*
|
||||
* <aExcept> is an optional array with DATA names you want to exclude
|
||||
* from the scan.
|
||||
* from the scan.
|
||||
* $RETURNS$
|
||||
* __objGetValueList() return a 2D array that contain pairs of a DATA
|
||||
* symbol name and the value of DATA. __objGetValueList() would return
|
||||
* an empty array {} if the given object does not contain the requested
|
||||
* information.
|
||||
* information.
|
||||
* $DESCRIPTION$
|
||||
* __objGetValueList() is a low level class support function that
|
||||
* return an array with DATA names and value, each array element is a
|
||||
* pair of: aData[ i, HB_OO_DATA_SYMBOL ] contain the symbol name
|
||||
* aData[ i, HB_OO_DATA_VALUE ] contain the value of DATA
|
||||
* pair of: aData[ i, HB_OO_DATA_SYMBOL ] contain the symbol name
|
||||
* aData[ i, HB_OO_DATA_VALUE ] contain the value of DATA
|
||||
* $EXAMPLES$
|
||||
* // show information about TBrowse class
|
||||
* oB := TBrowseNew( 0, 0, 24, 79 )
|
||||
@@ -212,9 +212,9 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objGetValueList() is a Harbour extension.
|
||||
* __objGetValueList() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Header file is hboo.ch
|
||||
* Header file is hboo.ch
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
* __objGetMethodList(),__objGetMsgList(),__objHasData(),__objHasMethod(),__ObjSetValueList()
|
||||
@@ -231,18 +231,18 @@
|
||||
* $SYNTAX$
|
||||
* __ObjSetValueList( <oObject>, <aData> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is an object to set.
|
||||
* <oObject> is an object to set.
|
||||
*
|
||||
* <aData> is a 2D array with a pair of instance variables and values
|
||||
* for setting those variable.
|
||||
* for setting those variable.
|
||||
* $RETURNS$
|
||||
* __ObjSetValueList() return a reference to <oObject>.
|
||||
* __ObjSetValueList() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __ObjSetValueList() is a low level class support function that let
|
||||
* you set a group of instance variables with values. each array
|
||||
* element in <aData> is a pair of:
|
||||
* aData[ i, HB_OO_DATA_SYMBOL ] which contain the variable name to set
|
||||
* aData[ i, HB_OO_DATA_VALUE ] contain the new variable value.
|
||||
* element in <aData> is a pair of:
|
||||
* aData[ i, HB_OO_DATA_SYMBOL ] which contain the variable name to set
|
||||
* aData[ i, HB_OO_DATA_VALUE ] contain the new variable value.
|
||||
* $EXAMPLES$
|
||||
* // set some TBrowse instance variable
|
||||
* oB := TBrowse():New()
|
||||
@@ -264,9 +264,9 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __ObjSetValueList() is a Harbour extension.
|
||||
* __ObjSetValueList() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Header file is hboo.ch
|
||||
* Header file is hboo.ch
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
* __ObjGetValueList()
|
||||
@@ -283,20 +283,20 @@
|
||||
* $SYNTAX$
|
||||
* __objAddMethod( <oObject>, <cMethodName>, <nFuncPtr> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cMethodName> is the symbol name of the new METHOD to add.
|
||||
* <cMethodName> is the symbol name of the new METHOD to add.
|
||||
*
|
||||
* <nFuncPtr> is a pointer to a function to associate with the method.
|
||||
* <nFuncPtr> is a pointer to a function to associate with the method.
|
||||
* $RETURNS$
|
||||
* __objAddMethod() return a reference to <oObject>.
|
||||
* __objAddMethod() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objAddMethod() is a low level class support function that add a
|
||||
* new METHOD to an object. <oObject> is unchanged if a symbol with the
|
||||
* name <cMethodName> already exist in <oObject>.
|
||||
* name <cMethodName> already exist in <oObject>.
|
||||
*
|
||||
* Note that <nFuncPtr> is a special pointer to a function that was
|
||||
* created using the @ operator, see example below.
|
||||
* created using the @ operator, see example below.
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a Smile method
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -318,9 +318,9 @@
|
||||
* RETURN cSmile
|
||||
* </fixed>
|
||||
* $STATUS$
|
||||
* R
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objAddMethod() is a Harbour extension.
|
||||
* __objAddMethod() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -338,17 +338,17 @@
|
||||
* $SYNTAX$
|
||||
* __objAddInline( <oObject>, <cInlineName>, <bInline> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cInlineName> is the symbol name of the new INLINE to add.
|
||||
* <cInlineName> is the symbol name of the new INLINE to add.
|
||||
*
|
||||
* <bInline> is a code block to associate with the INLINE method.
|
||||
* <bInline> is a code block to associate with the INLINE method.
|
||||
* $RETURNS$
|
||||
* __objAddInline() return a reference to <oObject>.
|
||||
* __objAddInline() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objAddInline() is a low level class support function that add a
|
||||
* new INLINE method to an object. <oObject> is unchanged if a symbol
|
||||
* with the name <cInlineName> already exist in <oObject>.
|
||||
* with the name <cInlineName> already exist in <oObject>.
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a Smile INLINE method
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -361,7 +361,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objAddInline() is a Harbour extension.
|
||||
* __objAddInline() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -379,15 +379,15 @@
|
||||
* $SYNTAX$
|
||||
* __objAddData( <oObject>, <cDataName> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cDataName> is the symbol name of the new DATA to add.
|
||||
* <cDataName> is the symbol name of the new DATA to add.
|
||||
* $RETURNS$
|
||||
* __objAddData() return a reference to <oObject>.
|
||||
* __objAddData() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objAddData() is a low level class support function that add a new
|
||||
* DATA to an object. <oObject> is unchanged if a symbol with the name
|
||||
* <cDataName> already exist in <oObject>.
|
||||
* <cDataName> already exist in <oObject>.
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a lHappy DATA
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -402,7 +402,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objAddData() is a Harbour extension.
|
||||
* __objAddData() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -420,22 +420,22 @@
|
||||
* $SYNTAX$
|
||||
* __objModMethod( <oObject>, <cMethodName>, <nFuncPtr> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cMethodName> is the symbol name of the METHOD to modify.
|
||||
* <cMethodName> is the symbol name of the METHOD to modify.
|
||||
*
|
||||
* <nFuncPtr> is a pointer to a new function to associate with the
|
||||
* method.
|
||||
* method.
|
||||
* $RETURNS$
|
||||
* __objModMethod() return a reference to <oObject>.
|
||||
* __objModMethod() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objModMethod() is a low level class support function that modify
|
||||
* a METHOD in an object and replace it with a new function. <oObject>
|
||||
* is unchanged if a symbol with the name <cMethodName> does not exist
|
||||
* in <oObject>. __objModMethod() is used in inheritance mechanism.
|
||||
* in <oObject>. __objModMethod() is used in inheritance mechanism.
|
||||
*
|
||||
* Note that <nFuncPtr> is a special pointer to a function that was
|
||||
* created using the @ operator, see example below.
|
||||
* created using the @ operator, see example below.
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a Smile method
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -470,7 +470,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objModMethod() is a Harbour extension.
|
||||
* __objModMethod() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -488,19 +488,19 @@
|
||||
* $SYNTAX$
|
||||
* __objModInline( <oObject>, <cInlineName>, <bInline> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cInlineName> is the symbol name of the INLINE method to modify.
|
||||
* <cInlineName> is the symbol name of the INLINE method to modify.
|
||||
*
|
||||
* <bInline> is a new code block to associate with the INLINE method.
|
||||
* <bInline> is a new code block to associate with the INLINE method.
|
||||
* $RETURNS$
|
||||
* __objModInline() return a reference to <oObject>.
|
||||
* __objModInline() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objModInline() is a low level class support function that modify
|
||||
* an INLINE method in an object and replace it with a new code block.
|
||||
* <oObject> is unchanged if a symbol with the name <cInlineName> does
|
||||
* not exist in <oObject>. __objModInline() is used in inheritance
|
||||
* mechanism.
|
||||
* mechanism.
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a Smile INLINE method
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -517,7 +517,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objModInline() is a Harbour extension.
|
||||
* __objModInline() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -535,19 +535,19 @@
|
||||
* $SYNTAX$
|
||||
* __objDelMethod( <oObject>, <cSymbol> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cSymbol> is the symbol name of METHOD or INLINE method to be
|
||||
* deleted (removed) from the object.
|
||||
* deleted (removed) from the object.
|
||||
* $RETURNS$
|
||||
* __objDelMethod() return a reference to <oObject>.
|
||||
* __objDelMethod() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objDelMethod() is a low level class support function that delete
|
||||
* (remove) a METHOD or an INLINE method from an object. <oObject> is
|
||||
* unchanged if a symbol with the name <cSymbol> does not exist in
|
||||
* <oObject>.
|
||||
* <oObject>.
|
||||
*
|
||||
* __objDelInline() is exactly the same as __objDelMethod().
|
||||
* __objDelInline() is exactly the same as __objDelMethod().
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a Smile method
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -570,7 +570,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objDelMethod() is a Harbour extension.
|
||||
* __objDelMethod() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -588,17 +588,17 @@
|
||||
* $SYNTAX$
|
||||
* __objDelInline( <oObject>, <cSymbol> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cSymbol> is the symbol name of METHOD or INLINE method to be
|
||||
* deleted (removed) from the object.
|
||||
* deleted (removed) from the object.
|
||||
* $RETURNS$
|
||||
* __objDelInMethod() return a reference to <oObject>.
|
||||
* __objDelInMethod() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objDelInMethod() is a low level class support function that delete
|
||||
* (remove) a METHOD or an INLINE method from an object. <oObject> is
|
||||
* unchanged if a symbol with the name <cSymbol> does not exist in
|
||||
* <oObject>.
|
||||
* <oObject>.
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a Smile method
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -621,7 +621,7 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objDelMethod() is a Harbour extension.
|
||||
* __objDelMethod() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
@@ -639,16 +639,16 @@
|
||||
* $SYNTAX$
|
||||
* __objDelMethod( <oObject>, <cDataName> ) --> oObject
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to work on.
|
||||
* <oObject> is the object to work on.
|
||||
*
|
||||
* <cDataName> is the symbol name of DATA to be deleted (removed) from
|
||||
* the object.
|
||||
* the object.
|
||||
* $RETURNS$
|
||||
* __objDelData() return a reference to <oObject>.
|
||||
* __objDelData() return a reference to <oObject>.
|
||||
* $DESCRIPTION$
|
||||
* __objDelData() is a low level class support function that delete
|
||||
* (remove) a DATA from an object. <oObject> is unchanged if a symbol
|
||||
* with the name <cDataName> does not exist in <oObject>.
|
||||
* with the name <cDataName> does not exist in <oObject>.
|
||||
* $EXAMPLES$
|
||||
* // create a new THappy class and add a lHappy DATA
|
||||
* oHappy := TClass():New( "THappy" )
|
||||
@@ -661,10 +661,70 @@
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objDelData() is a Harbour extension.
|
||||
* __objDelData() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
* __objAddData(),__objGetMsgList(),__ObjGetValueList(),__objHasData(),__ObjSetValueList()
|
||||
* __objAddData(),__objGetMsgList(),__ObjGetValueList(),__objHasData(),__ObjSetValueList()
|
||||
* $END$
|
||||
*/
|
||||
|
||||
/* $DOC$
|
||||
* $FUNCNAME$
|
||||
* __objDerivedFrom()
|
||||
* $CATEGORY$
|
||||
* Object manipulation
|
||||
* $ONELINER$
|
||||
* Determine whether a class is derived from another class
|
||||
* $SYNTAX$
|
||||
* __objDerivedFrom( <oObject>, <xSuper> ) --> lIsParent
|
||||
* $ARGUMENTS$
|
||||
* <oObject> is the object to check.
|
||||
*
|
||||
* <xSuper> is the object that may be a parent. <xSuper> can be either
|
||||
* an Object or a Character string with the class name.
|
||||
* $RETURNS$
|
||||
* __objDerivedFrom() return a logical TRUE (.T.) if <oObject> is
|
||||
* derived from <xSuper>.
|
||||
* $DESCRIPTION$
|
||||
* __objDerivedFrom() is a low level class support function that check
|
||||
* is one class is a super class of the other, or in other words, does
|
||||
* class <oObject> a child or descendant of <xSuper>.
|
||||
* $EXAMPLES$
|
||||
* // Create three classes and check their relations
|
||||
*
|
||||
* #include "hbclass.ch"
|
||||
* FUNCTION main()
|
||||
* local oSuper, oObject, oDress
|
||||
* oSuper := TMood():New()
|
||||
* oObject := THappy():New()
|
||||
* oDress := TShirt():New()
|
||||
* ? __objDerivedFrom( oObject, oSuper ) // .T.
|
||||
* ? __objDerivedFrom( oSuper, oObject ) // .F.
|
||||
* ? __objDerivedFrom( oObject, oDress ) // .F.
|
||||
* RETURN NIL
|
||||
*
|
||||
* CLASS TMood
|
||||
* METHOD New() INLINE Self
|
||||
* ENDCLASS
|
||||
*
|
||||
* CLASS THappy FROM TMood
|
||||
* METHOD Smile() INLINE qout( "*smile*" )
|
||||
* ENDCLASS
|
||||
*
|
||||
* CLASS TShirt
|
||||
* DATA Color
|
||||
* DATA Size
|
||||
* METHOD New() INLINE Self
|
||||
* ENDCLASS
|
||||
* </fixed>
|
||||
* $STATUS$
|
||||
* R
|
||||
* $COMPLIANCE$
|
||||
* __objDerivedFrom() is a Harbour extension.
|
||||
* $FILES$
|
||||
* Library is rtl
|
||||
* $SEEALSO$
|
||||
* __objHasData(),__ObjHasMethod()
|
||||
* $END$
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user