Files
win8phoneApp/CampusAppWP8/CampusAppWPortalLib8/Model/Person/PersonFunctionModel.cs
2013-10-01 16:34:03 +02:00

188 lines
4.8 KiB
C#

//-----------------------------------------------------------------------------
// <copyright file="PersonFunctionModel.cs" company="BTU/IIT">
// Company copyright tag.
// </copyright>
// <author>stubbfel</author>
// <sience>05.09.2013</sience>
//-----------------------------------------------------------------------------
namespace CampusAppWPortalLib8.Model.Person
{
using System.Xml.Serialization;
using CampusAppWPortalLib8.Utility;
/// <summary>Person function model.</summary>
/// <remarks>Stubbfel, 05.09.2013.</remarks>
public class PersonFunctionModel : IPersonFunctionModel
{
#region Member
/// <summary>The first tel.</summary>
private string tel1;
/// <summary>The second tel.</summary>
private string tel2;
/// <summary>The fax.</summary>
private string fax;
/// <summary>The mail.</summary>
private string mail;
/// <summary>The function.</summary>
private string function;
/// <summary>The appointment.</summary>
private string appointment;
/// <summary>The building.</summary>
private string building;
#endregion
#region Property
/// <summary>Gets or sets the tel 1.</summary>
/// <value>The tel 1.</value>
[XmlAttribute("telefon")]
public string Tel1
{
get
{
return this.tel1;
}
set
{
if (value != null && value != string.Empty && value != this.tel1)
{
this.tel1 = DefaultStringManager.CreateUniTelefonNumber(value);
}
}
}
/// <summary>Gets or sets the tel 2.</summary>
/// <value>The tel 2.</value>
[XmlAttribute("telefon2")]
public string Tel2
{
get
{
return this.tel2;
}
set
{
if (value != null && value != string.Empty && value != this.tel2)
{
this.tel2 = DefaultStringManager.CreateUniTelefonNumber(value);
}
}
}
/// <summary>Gets or sets the fax.</summary>
/// <value>The fax.</value>
[XmlAttribute("fax")]
public string Fax
{
get
{
return this.fax;
}
set
{
if (value != null && value != string.Empty && value != this.fax)
{
this.fax = DefaultStringManager.CreateUniTelefonNumber(value);
}
}
}
/// <summary>Gets or sets the function.</summary>
/// <value>The function.</value>
[XmlAttribute("funktion")]
public string Function
{
get
{
return this.function;
}
set
{
if (value != this.function)
{
this.function = value;
}
}
}
/// <summary>Gets or sets the appointment.</summary>
/// <value>The appointment.</value>
[XmlAttribute("einrichtung")]
public string Appointment
{
get
{
return this.appointment;
}
set
{
if (value != this.appointment)
{
this.appointment = value;
}
}
}
/// <summary>Gets or sets the building.</summary>
/// <value>The building.</value>
[XmlAttribute("gebaeude")]
public string Building
{
get
{
return this.building;
}
set
{
if (value != this.building)
{
this.building = value;
}
}
}
/// <summary>Gets or sets the mail.</summary>
/// <value>The mail.</value>
[XmlAttribute("mail")]
public string Mail
{
get
{
return this.mail;
}
set
{
if (value != null && value != this.mail && DefaultStringManager.IsValidEmail(value))
{
this.mail = value;
}
}
}
/// <summary>Gets or sets the identifier of the person.</summary>
/// <value>The identifier of the person.</value>
public string PersonID { get; set; }
/// <summary>Gets or sets zero-based index of the function.</summary>
/// <value>The function index.</value>
public int FunctionIndex { get; set; }
#endregion
}
}