In the example Tournament shown today in class, characterize the relationship between a team and its opponent using the concepts in section 2.4.2
package mar_13; /** * If opponent is null, team has not been assigned. Otherwise, it must * be that for two opposing teams, teamA and teamB, teamA.opponent=teamB * and teamB.opponent=teamA. * * @author George Heineman */ public class Team { /** Every team has an opponent. */ Team opponent; /** Every team has a name. */ String name; public Team (String name) { this.name = name; } /** Reasonable toString method. */ public String toString () { return name; } }
You should use the visual notation style shown in the section.