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.
mchsamples-.net-core/ex_042_007_EF_CF_One_to_One.../CarnetDeSante.cs

43 lines
1.1 KiB

// ========================================================================
//
// Copyright (C) 2016-2017 MARC CHEVALDONNE
// marc.chevaldonne.free.fr
//
// Module : CarnetDeSante.cs
// Author : Marc Chevaldonné
// Creation date : 2016-10-19
//
// ========================================================================
using System;
namespace ex_042_007_EF_CF_One_to_One_FluentAPI
{
/// <summary>
/// CarnetDeSante est une classe POCO, i.e. Plain Old CLR Object
/// Elle a une relation 1-1 avec la classe Nounours via la propriété Owner.
/// </summary>
public class CarnetDeSante
{
public Guid UniqueId
{
get; set;
}
public DateTime LastModified
{
get; set;
}
public virtual Nounours Owner
{
get; set;
}
public override string ToString()
{
return $"{UniqueId} : carnet de {Owner.Nom}, modifié la dernière fois le {LastModified.ToString("d")}";
}
}
}