{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Assignment Week 8 - Set getRating = Rating End Function...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
Assignment Week 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
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
End Subprogram Subprogram setQuantity(Quantity) Set Quantity = Quantity 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
Background image of page 2
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Background image of page 4
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Set getRating = Rating End Function Subprogram setLength(Length) 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 Function getRating() As String Set getRating = Rating End Function Subprogram setLength(Length) Set Length = Length End Subprogram Subprogram setGenre(Genre) Set Genre = Genre End Subprogram Subprogram setRating(Rating) Set Rating = Rating End Subprogram End Class...
View Full Document

{[ snackBarMessage ]}