/// <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) { VJournal o = (VJournal)p; this.ClearProperties(); classification = (ClassificationProperty)o.Classification.Clone(); categories = (CategoriesProperty)o.Categories.Clone(); url = (UrlProperty)o.Url.Clone(); uid = (UniqueIdProperty)o.UniqueId.Clone(); lastMod = (LastModifiedProperty)o.LastModified.Clone(); dateCreated = (DateCreatedProperty)o.DateCreated.Clone(); startDate = (StartDateProperty)o.StartDateTime.Clone(); timeStamp = (TimeStampProperty)o.TimeStamp.Clone(); summary = (SummaryProperty)o.Summary.Clone(); desc = (DescriptionProperty)o.Description.Clone(); sequence = (SequenceProperty)o.Sequence.Clone(); comment = (CommentProperty)o.Comment.Clone(); organizer = (OrganizerProperty)o.Organizer.Clone(); recurId = (RecurrenceIdProperty)o.RecurrenceId.Clone(); status = (StatusProperty)o.Status.Clone(); this.Contacts.CloneRange(o.Contacts); this.Attendees.CloneRange(o.Attendees); this.RelatedTo.CloneRange(o.RelatedTo); this.Attachments.CloneRange(o.Attachments); this.RequestStatuses.CloneRange(o.RequestStatuses); this.CustomProperties.CloneRange(o.CustomProperties); base.Clone(p); }
//===================================================================== /// <summary> /// This is overridden to allow cloning of a PDI object /// </summary> /// <returns>A clone of the object</returns> public override object Clone() { CommentProperty o = new CommentProperty(); o.Clone(this); return(o); }
/// <summary> /// The method can be called to clear all current property values from the journal. The version is left /// unchanged. /// </summary> public override void ClearProperties() { classification = null; categories = null; url = null; uid = null; lastMod = null; dateCreated = null; startDate = null; timeStamp = null; summary = null; desc = null; sequence = null; comment = null; organizer = null; recurId = null; status = null; contacts = null; attendees = null; relatedTo = null; attachments = null; reqStats = null; customProps = null; base.ClearProperties(); }
public async Task <ActionResult <CommentProperty> > PostCommentProperty(CommentProperty commentProperty) { _context.CommentProperties.Add(commentProperty); await _context.SaveChangesAsync(); return(CreatedAtAction("GetCommentProperty", new { id = commentProperty.CommentID }, commentProperty)); }
public async Task <IActionResult> PutCommentProperty(int id, CommentProperty commentProperty) { if (id != commentProperty.CommentID) { return(BadRequest()); } _context.Entry(commentProperty).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!CommentPropertyExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
/// <summary> /// The method can be called to clear all current property values from the observance. The version and /// rule type are left unchanged. /// </summary> public override void ClearProperties() { startDate = null; offsetFrom = null; offsetTo = null; comment = null; rRules = null; rDates = null; tzNames = null; customProps = null; }
/// <summary> /// The method can be called to clear all current property values from the free/busy object. The version /// is left unchanged. /// </summary> public override void ClearProperties() { url = null; uid = null; startDate = null; endDate = null; timeStamp = null; comment = null; organizer = null; duration = null; contact = null; attendees = null; reqstats = null; freebusy = null; customProps = null; }
/// <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) { ObservanceRule o = (ObservanceRule)p; this.ClearProperties(); ruleType = o.RuleType; startDate = (StartDateProperty)o.StartDateTime.Clone(); offsetFrom = (TimeZoneOffsetProperty)o.OffsetFrom.Clone(); offsetTo = (TimeZoneOffsetProperty)o.OffsetTo.Clone(); comment = (CommentProperty)o.Comment.Clone(); this.RecurrenceRules.CloneRange(o.RecurrenceRules); this.RecurDates.CloneRange(o.RecurDates); this.TimeZoneNames.CloneRange(o.TimeZoneNames); this.CustomProperties.CloneRange(o.CustomProperties); }
private void SetProperty(int type, object value) { Property current = _firstProperty; Property previous = null; while (current != null && current.GetType() != type) { previous = current; current = current._next; } if (current != null) { current._value = value; } else { switch (type) { case Property.COMMENT: { current = new CommentProperty(value); break; } case Property.HYPERLINK: { current = new HyperlinkProperty(value); break; } default: { throw new ArgumentException("Invalid type: " + type); } } if (previous != null) { previous._next = current; } else { _firstProperty = current; } } }
/// <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) { VFreeBusy o = (VFreeBusy)p; this.ClearProperties(); url = (UrlProperty)o.Url.Clone(); uid = (UniqueIdProperty)o.UniqueId.Clone(); startDate = (StartDateProperty)o.StartDateTime.Clone(); endDate = (EndDateProperty)o.EndDateTime.Clone(); timeStamp = (TimeStampProperty)o.TimeStamp.Clone(); comment = (CommentProperty)o.Comment.Clone(); organizer = (OrganizerProperty)o.Organizer.Clone(); duration = (DurationProperty)o.Duration.Clone(); contact = (ContactProperty)o.Contact.Clone(); this.Attendees.CloneRange(o.Attendees); this.RequestStatuses.CloneRange(o.RequestStatuses); this.FreeBusy.CloneRange(o.FreeBusy); this.CustomProperties.CloneRange(o.CustomProperties); }
/// <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) { VEvent o = (VEvent)p; this.ClearProperties(); classification = (ClassificationProperty)o.Classification.Clone(); categories = (CategoriesProperty)o.Categories.Clone(); resources = (ResourcesProperty)o.Resources.Clone(); url = (UrlProperty)o.Url.Clone(); uid = (UniqueIdProperty)o.UniqueId.Clone(); geo = (GeographicPositionProperty)o.GeographicPosition.Clone(); lastMod = (LastModifiedProperty)o.LastModified.Clone(); dateCreated = (DateCreatedProperty)o.DateCreated.Clone(); startDate = (StartDateProperty)o.StartDateTime.Clone(); endDate = (EndDateProperty)o.EndDateTime.Clone(); dateStamp = (TimeStampProperty)o.TimeStamp.Clone(); summary = (SummaryProperty)o.Summary.Clone(); desc = (DescriptionProperty)o.Description.Clone(); location = (LocationProperty)o.Location.Clone(); priority = (PriorityProperty)o.Priority.Clone(); sequence = (SequenceProperty)o.Sequence.Clone(); transp = (TimeTransparencyProperty)o.Transparency.Clone(); rNum = (RecurrenceCountProperty)o.RecurrenceCount.Clone(); comment = (CommentProperty)o.Comment.Clone(); organizer = (OrganizerProperty)o.Organizer.Clone(); recurId = (RecurrenceIdProperty)o.RecurrenceId.Clone(); status = (StatusProperty)o.Status.Clone(); duration = (DurationProperty)o.Duration.Clone(); this.Contacts.CloneRange(o.Contacts); this.Attendees.CloneRange(o.Attendees); this.RelatedTo.CloneRange(o.RelatedTo); this.Attachments.CloneRange(o.Attachments); this.RequestStatuses.CloneRange(o.RequestStatuses); this.Alarms.CloneRange(o.Alarms); this.CustomProperties.CloneRange(o.CustomProperties); base.Clone(p); }
//===================================================================== /// <summary> /// This is overridden to allow cloning of a PDI object /// </summary> /// <returns>A clone of the object</returns> public override object Clone() { CommentProperty o = new CommentProperty(); o.Clone(this); return o; }
set => SetValue(CommentProperty, value);