예제 #1
0
        /// <summary>
        /// The method can be called to clear all current property values in the calendar.  The version is left
        /// unchanged.
        /// </summary>
        /// <remarks>Because time zone information is shared amongst all calendars, the <see cref="TimeZones"/>
        /// collection will not be cleared.  If you want it cleared, you must do it manually.</remarks>
        public override void ClearProperties()
        {
            prodId = null;
            calScale = null;
            method = null;
            geo = null;
            tz = null;
            daylight = null;

            events = null;
            todos = null;
            journals = null;
            freebusy = null;

            customProps = null;
        }
예제 #2
0
        /// <summary>
        /// This is overridden to allow copying of the additional properties
        /// </summary>
        /// <param name="p">The PDI object from which the settings are to be copied</param>
        protected override void Clone(PDIObject p)
        {
            VCalendar o = (VCalendar)p;

            this.ClearProperties();

            prodId = (ProductIdProperty)o.ProductId.Clone();
            calScale = (CalendarScaleProperty)o.CalendarScale.Clone();
            method = (MethodProperty)o.Method.Clone();
            geo = (GeographicPositionProperty)o.VCalendarGeographicPosition.Clone();
            tz = (TimeZoneProperty)o.VCalendarTimeZone.Clone();
            daylight = (DaylightProperty)o.VCalendarDaylightRule.Clone();

            this.Events.CloneRange(o.Events);
            this.ToDos.CloneRange(o.ToDos);
            this.Journals.CloneRange(o.Journals);
            this.FreeBusys.CloneRange(o.FreeBusys);
            this.CustomProperties.CloneRange(o.CustomProperties);
        }