o1.football1
Type members
Classlikes
The class Club
represents football clubs in a match statistics system.
Only some very basic information for each club is recorded.
A club object is immutable once created.
The class Club
represents football clubs in a match statistics system.
Only some very basic information for each club is recorded.
A club object is immutable once created.
- Value parameters:
- name
the name of the club
- stadium
the name of the home stadium of the club
The class Match
represents match results in a football match statistics program.
A match is played between teams from two clubs: a home club and an away club.
Goals scored by either team can be added to the match object.
The class Match
represents match results in a football match statistics program.
A match is played between teams from two clubs: a home club and an away club.
Goals scored by either team can be added to the match object.
The class is expected to be used so that a match object with no goals is initially created as a real-life match starts. Goals are added incrementally as the match progresses. (A match object has mutable state.)
- Value parameters:
- away
the club whose team plays away in the match
- home
the club whose team plays at home in the match