diff --git a/Core/ServiceObjects/Items/Booking.cs b/Core/ServiceObjects/Items/Booking.cs new file mode 100644 index 00000000..a8e6eaf1 --- /dev/null +++ b/Core/ServiceObjects/Items/Booking.cs @@ -0,0 +1,39 @@ +/* + * Exchange Web Services Managed API + * + * Copyright (c) Microsoft Corporation + * All rights reserved. + * + * MIT License + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of this + * software and associated documentation files (the "Software"), to deal in the Software + * without restriction, including without limitation the rights to use, copy, modify, merge, + * publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons + * to whom the Software is furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all copies or + * substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, + * INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR + * PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE + * FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR + * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + * DEALINGS IN THE SOFTWARE. + */ + +namespace Microsoft.Exchange.WebServices.Data +{ + using System; + + [Attachable] + [ServiceObjectDefinition(XmlElementNames.Booking)] + public class Booking : Appointment + { + public Booking(ExchangeService service) + : base(service) + { + } + } +} \ No newline at end of file diff --git a/Core/ServiceObjects/ServiceObjectInfo.cs b/Core/ServiceObjects/ServiceObjectInfo.cs index 0145000b..86ebc0fc 100644 --- a/Core/ServiceObjects/ServiceObjectInfo.cs +++ b/Core/ServiceObjects/ServiceObjectInfo.cs @@ -72,6 +72,13 @@ private void InitializeServiceObjectClassMap() delegate(ExchangeService srv) { return new Appointment(srv); }, delegate(ItemAttachment itemAttachment, bool isNew) { return new Appointment(itemAttachment, isNew); }); + // Booking + this.AddServiceObjectType( + XmlElementNames.Booking, + typeof(Booking), + delegate (ExchangeService srv) { return new Booking(srv); }, + delegate (ItemAttachment itemAttachment, bool isNew) { return new Appointment(itemAttachment, isNew); }); + // CalendarFolder this.AddServiceObjectType( XmlElementNames.CalendarFolder, diff --git a/Core/XmlElementNames.cs b/Core/XmlElementNames.cs index 2b1bf60c..765d1053 100644 --- a/Core/XmlElementNames.cs +++ b/Core/XmlElementNames.cs @@ -207,6 +207,7 @@ internal static class XmlElementNames public const string AccessLevel = "AccessLevel"; public const string Presenters = "Presenters"; public const string CalendarItem = "CalendarItem"; + public const string Booking = "Booking"; public const string CalendarFolder = "CalendarFolder"; public const string Attendee = "Attendee"; public const string ResponseType = "ResponseType"; diff --git a/Microsoft.Exchange.WebServices.Data.csproj b/Microsoft.Exchange.WebServices.Data.csproj index 39f1a732..95688c7b 100644 --- a/Microsoft.Exchange.WebServices.Data.csproj +++ b/Microsoft.Exchange.WebServices.Data.csproj @@ -108,6 +108,7 @@ + @@ -879,41 +880,23 @@ - - - - - - - - - - - + ]]> - - - - - - - - \ No newline at end of file