Access over 20 million homework & study documents

search

IT210 - Week 8 Object Oriented Design

Type

Homework

Rating

Showing Page:
1/5
Class MediaCollection
Name As String
Type As String
Quantity As Integer
Subprogram NewItem(name)
Call SetName(name)
Call SetQuantity(Quantity + 1)
End Subprogram
Function getName() As String
Set getName = Name
End Function
Function getType() As String
Set getType = Type
End Function
Function getQuantity() As Integer
Set getQuantity = Quantity
End Function
Subprogram setName(name)
Set Name = name
End Subprogram
Subprogram setType(type)
Set Type = Type
End Subprogram
Subprogram setQuantity(Quantity)
Set Quantity = Quantity

Sign up to view the full document!

lock_open Sign Up
End Subprogram
End Class
Class CDMedia
Length as Real
Genre as String
Rating as String
Subprogram NewCD(length, genre, rating)
Call SetLength(length)
Call SetGenre(genre)
Call SetRating(rating)
End Subprogram
Function getLength() As Real
Set getLength = Length
End Function
Function getGenre() As String
Set getGenre = Genre
End Function
Function getRating() As String
Set getRating = Rating
End Function
Subprogram setLength(length)

Sign up to view the full document!

lock_open Sign Up
Set Length = Length
End Subprogram
Subprogram setGenre(genre)
Set Genre = Genre
End Subprogram
Subprogram setRating(Rating)
Set Rating = Rating
End Subprogram
End Class
Class DVDMedia
Length as Real
Genre as String
Rating as String
Subprogram NewDVD(length, genre, rating)
Call SetLength(length)
Call SetGenre(genre)
Call SetRating(rating)
End Subprogram
Function getLength() As Real
Set getLength = Length
End Function
Function getGenre() As String
Set getGenre = Genre
End Function

Sign up to view the full document!

lock_open Sign Up
User generated content is uploaded by users for the purposes of learning and should be used following Studypool's honor code & terms of service.

Anonymous
Great study resource, helped me a lot.

Studypool
4.7
Trustpilot
4.5
Sitejabber
4.4