PIbd-21_Valitov_D.F_Sailboa.../Sailboat/Sailboat.cs

36 lines
1.2 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Sailboat
{
internal class Sailboat : Boat
{
/// <summary>
/// Признак наличия усиленного корпуса
/// </summary>
public bool ExtendedBody { get; private set; }
/// <summary>
/// Признак наличия паруса
/// </summary>
public bool Sail { get; private set; }
/// <summary>
/// Инициализация свойств
/// </summary>
/// <param name="speed">Скорость</param>
/// <param name="weight">Вес автомобиля</param>
/// <param name="bodyColor">Цвет кузова</param>
/// <param name="sail">Признак наличия паруса</param>
/// <param name="extendedBody">Признак наличия усиленного корпуса</param>
public Sailboat(int speed, float weight, Color bodyColor, bool sail, bool extendedBody) :
base(speed, weight, bodyColor)
{
Sail = sail;
ExtendedBody = extendedBody;
}
}
}