Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VB usage declining
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00506987
Message ID:
00509156
Views:
27
>>>>>>Yup. Positive. I remember going to a meeting at the offices of dlesko, the company that made funcky. Dirk Lesko was talking about what is OOP and compared it to the procedural code we were used to developing.
>>>>>
>>>>>Clipper 5.O OOP??? I don't think so. I've used Clipper Summer 87 until 5.0. The latter wasn't even an Object Based one. No inheritance, etc.
>>>>
>>>
>>>Craig,
>>>
>>>I will believe you if you based your claim on your personal experience. If you did used it, then I challenge you to educate me with kindness by explaining how Inheritance/Subclassing, Polymorphism, and Encapsulation/Abstraction works with Clipper 5.0 that makes it OOP. :)

Sure!
Here is a pgm that uses classes and OOP. Notice the "Create Class" syntax and the "INHERIT" syntax...
#INCLUDE "CLASSY2.CH"
#INCLUDE "FUNCKY.CH"


#DEFINE DEFAULT_INITIAL_COUNTER 1


// ÚÄ Class ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
// ³         Name: CntNumeric                                                 ³
// ³  Description:                                                            ³
// ³       Author: Chris Pels                                                 ³
// ³ Date created: 05-03-94              Date updated: þ05-03-94              ³
// ³ Time created: 01:22:06pm            Time updated: þ01:22:06pm            ³
// ³    Copyright: Greenwich Bay Technologies, Inc.                           ³
// ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
// ³ Parent class: Counter                                                    ³
// ³     See Also:                                                            ³
// ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
//       History: $History: CNTNUM.PRG $
/**/
/******************  Version 3  ******************/
/*User: Chris        Date: 5/03/94    Time: 1:28p */
/*Updated in /GBTLib*/
/*Added History keyword for version control and changed copyright to GBT.*/
/**/
/******************  Version 2  ******************/
/*User: Chris        Date: 5/02/94    Time: 3:09p */
/*Updated in /GBTLib*/
/*Standardized and improved documentation.*/
/**/
/******************  Version 1  ******************/
/*User: Chris        Date: 4/13/94    Time: 3:36p */
/*Updated in /GBTLib*/
/*Initial version.*/
//
CREATE CLASS CntNumeric INHERIT Counter

PROTECTED:

	VAR nCounter                         // Current counter value.

EXPORT:

	METHOD Init                          // Initialize class.
	METHOD Inc                           // Increment the counter.
	METHOD Dec                           // Decrement the counter.
	METHOD Assign                        // Set the counter.
	METHOD Get                           // Get current counter value.
	METHOD Reset                         // Reset counter to standard default.

END CLASS

// ÚÄ Method ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
// ³         Name: Init()                                                     ³
// ³  Description: Initialize the class.                                      ³
// ³       Author: Chris Pels                                                 ³
// ³ Date created: 04-13-94              Date updated: þ04-13-94              ³
// ³ Time created: 03:18:49pm            Time updated: þ03:18:49pm            ³
// ³    Copyright: Greenwich Bay Technologies                                 ³
// ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
// ³    Arguments: nInitial                                                   ³
// ³ Return Value: (self)                                                     ³
// ³     See Also:                                                            ³
// ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
METHOD Init( nInitial )

	DEFAULT nInitial TO DEFAULT_INITIAL_COUNTER // Initial counter is 1.
	::Assign( nInitial )

RETURN (self)

// ÚÄ Method ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
// ³         Name: Inc()                                                ³
// ³  Description: Increment the counter.                                     ³
// ³       Author: Chris Pels                                                 ³
// ³ Date created: 04-13-94              Date updated: þ04-13-94              ³
// ³ Time created: 03:18:41pm            Time updated: þ03:18:41pm            ³
// ³    Copyright: Greenwich Bay Technologies                                 ³
// ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
// ³    Arguments: None                                                       ³
// ³ Return Value: (self)                                                     ³
// ³     See Also:                                                            ³
// ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
METHOD Inc( nIncrement )

	DEFAULT nIncrement TO 1              // Increment by 1 by default.

	::nCounter += nIncrement

RETURN ( ::nCounter )

// ÚÄ Method ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
// ³         Name: Dec()                                                ³
// ³  Description: Decrement the counter.                                     ³
// ³       Author: Chris Pels                                                 ³
// ³ Date created: 04-13-94              Date updated: þ04-13-94              ³
// ³ Time created: 03:18:34pm            Time updated: þ03:18:34pm            ³
// ³    Copyright: Greenwich Bay Technologies                                 ³
// ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
// ³    Arguments: None                                                       ³
// ³ Return Value: (self)                                                     ³
// ³     See Also:                                                            ³
// ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
METHOD Dec( nDecrement )

	DEFAULT nDecrement TO 1              // Decrement by 1 by default.

	::nCounter -= nDecrement

RETURN ( ::nCounter )

// ÚÄ Method ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
// ³         Name: Assign()                                               ³
// ³  Description: Set the current value of the counter.                      ³
// ³       Author: Chris Pels                                                 ³
// ³ Date created: 04-13-94              Date updated: þ04-13-94              ³
// ³ Time created: 03:18:25pm            Time updated: þ03:18:25pm            ³
// ³    Copyright: Greenwich Bay Technologies                                 ³
// ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
// ³    Arguments: nCounter                                                   ³
// ³ Return Value: (self)                                                     ³
// ³     See Also:                                                            ³
// ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
METHOD Assign( nCounter )

	ASSERT( valtype(nCounter)=="N" )
	::nCounter := nCounter

RETURN (self)

// ÚÄ Method ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
// ³         Name: Get()                                               ³
// ³  Description: Return current counter value.                              ³
// ³       Author: Chris Pels                                                 ³
// ³ Date created: 04-13-94              Date updated: þ04-13-94              ³
// ³ Time created: 03:18:12pm            Time updated: þ03:18:12pm            ³
// ³    Copyright: Greenwich Bay Technologies                                 ³
// ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
// ³    Arguments: nCounter                                                   ³
// ³ Return Value: @( nCounter @)                                              ³
// ³     See Also:                                                            ³
// ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
METHOD Get( nCounter )
RETURN( ::nCounter )

// ÚÄ Method ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
// ³         Name: Reset()                                                    ³
// ³  Description: Reset counter to standard default.                         ³
// ³       Author: Chris Pels                                                 ³
// ³ Date created: 04-15-94              Date updated: þ04-15-94              ³
// ³ Time created: 12:21:42pm            Time updated: þ12:21:42pm            ³
// ³    Copyright: Greenwich Bay Technologies, Inc.                           ³
// ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
// ³    Arguments: None                                                       ³
// ³ Return Value: (self)                                                   ³
// ³     See Also:                                                            ³
// ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
METHOD Reset()
	::nCounter := DEFAULT_INITIAL_COUNTER
RETURN (self)
>>
>>Before there were so called object languages, object programing was a conceptual tool that some developers used to generalize their solutions. Of course they didn't have all these poly sylabic terms. One can develop object solutions with out necessarily using an object language, just as on can write non-object solutions using obect programming languages.
>
>C++ has been OOP even during the time Clipper is popular. OOP methodology is not changing ever since. Some programming tools i.e. VB are just Object Based not Object Oriented. I just can not find the book reiterating that Clipper 5.0 is not Object Oriented but just merely a misconception because it does not have the attributes of a true OOP language.
Nebraska Dept of Revenue
Previous
Reply
Map
View

Click here to load this message in the networking platform