You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
61 lines
1.9 KiB
61 lines
1.9 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Runtime.Serialization;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using System.Xml.Linq;
|
|
|
|
namespace Model
|
|
{
|
|
[DataContract(Name = "bateau")]
|
|
public class Bateau : ObjetOhara
|
|
{
|
|
[DataMember(Name = "nomromanise")]
|
|
public string NomRomanise { get; set; }
|
|
[DataMember(Name = "affiliation", EmitDefaultValue = false)]
|
|
public Equipage? Affiliation { get; set; }
|
|
[DataMember(Name = "premierchap")]
|
|
public int PremierChap { get; set; }
|
|
[DataMember(Name = "premierep")]
|
|
public int PremierEp { get; set; }
|
|
[DataMember(Name = "description")]
|
|
public string Description { get; set; }
|
|
[DataMember(Name = "caracteristique")]
|
|
public string Caracteristique { get; set; }
|
|
|
|
|
|
|
|
public Bateau(string nom, string nomRomanise, int premierChap, int premierEp, string description, string caracteristique, string image = "baseimage.png") : base(nom,image)
|
|
{
|
|
|
|
NomRomanise = nomRomanise;
|
|
|
|
if (premierEp < 0)
|
|
{
|
|
PremierEp = 0;
|
|
}
|
|
else
|
|
{
|
|
PremierEp = premierEp;
|
|
}
|
|
if (premierChap < 0)
|
|
{
|
|
premierChap = 0;
|
|
}
|
|
else
|
|
{
|
|
PremierChap = premierChap;
|
|
}
|
|
Description = description;
|
|
Caracteristique = caracteristique;
|
|
|
|
}
|
|
|
|
public Bateau(string nom, string nomRomanise, Equipage affiliation, int premierChap, int premierEp, string description, string caracteristique, string image) : this(nom,nomRomanise,premierChap,premierEp,description,caracteristique,image)
|
|
{
|
|
Affiliation = affiliation;
|
|
}
|
|
}
|
|
}
|