Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Look up keyword
Like this
4Activity
0 of .
Results for:
No results containing your search query
P. 1
Lecture 12 - Shared Class Resources (VB 2008)

Lecture 12 - Shared Class Resources (VB 2008)

Ratings:

5.0

(1)
|Views: 164|Likes:
Published by curlicue

More info:

Published by: curlicue on Oct 21, 2008
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as PPT, PDF, TXT or read online from Scribd
See more
See less

09/17/2010

pdf

text

original

 
Lecture 12: Shared Class Resources
 
Outline
In the last lecture,we continued our discussion of Overriding
WithPolymorphism, a simple but powerful concept
Form 1 : Overriding Base Class Methods and Properties.
Form 2 : The Ability of Methods to Accept
Related
Classes.
And then illustrated with a generalizedMultiple-JTrainExample
That uses both
forms
of Polymorphism.
We also learned the basics of creating our own customCollections:
Similar to Collections.ArrayList, but defined by us
By inheriting from the .NET System Class,CollectionBase.
And defined our ownCollectioncalledJTrainCollection.
In this lecture, we first continue by updating Module1:
Add two utility Methods:
AddTrain()
FindTrain()
Update our Main()Method to use these withJTrainCollection
Then, we discussShared Members and Methods
Which allow us to share resources amongst all Object Instances.
Example (JFreightTrain) : A Shared WagonWeight Member 
 
 
Last time, we had just added theCommandTrain() Method

Activity (4)

You've already reviewed this. Edit your review.
1 thousand reads
1 hundred reads
Zohane liked this
ashokk_jal22 liked this

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->