示例#1
0
 public void Add(Footballer footballer)
 {
     if (Count == FOOTBALLERS_CAPACITY)
     {
         throw new ArgumentOutOfRangeException();
     }
     footballers[Count] = footballer;
     Count++;
 }
示例#2
0
        public override bool Equals(object obj)
        {
            if (obj == null || GetType() != obj.GetType())
            {
                return(false);
            }
            Footballer second = obj as Footballer;

            if (Name != second.Name)
            {
                return(false);
            }
            if (Club != second.Club)
            {
                return(false);
            }
            return(GoalCount == second.GoalCount);
        }
示例#3
0
 public Footballer(Footballer source)
 {
     Name      = source.Name;
     Club      = source.Club;
     GoalCount = source.GoalCount;
 }