![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: May 2005
Posts: 8
Rep Power: 0
![]() |
Abstract problem!
Hi
I have an abstract class with abstract methods and non abstract methods. Among those non abstract methods one of them is setSensorID(mutator). Well I wanted to know how we use that method from it's descendant. My setSensorID is like this: public void setSensorID(int inSensorID)
{
sensorID=inSensorID;
}So if someone could help me I would be very grateful. |
|
|
|
|
|
#2 |
|
Programmer
Join Date: Mar 2005
Location: different places. constantly on the run.
Posts: 57
Rep Power: 4
![]() |
calling it like normal doesn't work? "anObject.setSensorID( 7 )" doesn't do it for you? (i'm slightly rusty)
__________________
There's got to be more to life than being really, really ridiculously good looking |
|
|
|
|
|
#3 | |
|
Resident Grouch
![]() ![]() ![]() ![]() ![]() ![]() Join Date: Jun 2005
Posts: 6,453
Rep Power: 10
![]() |
Quote:
![]()
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code. Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers |
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|