/// <exception cref="ArgumentNullException"> /// <paramref name="comment"/> is null.-or- /// <paramref name="entity"/> is null. /// </exception> internal CommentRelationship(Comment comment, IEntity entity) { if (comment == null) throw new ArgumentNullException("comment"); if (entity == null) throw new ArgumentNullException("entity"); this.comment = comment; this.entity = entity; Attach(); }
/// <exception cref="ArgumentNullException"> /// <paramref name="comment"/> is null. /// </exception> internal CommentShape(Comment comment) : base(comment) { this.comment = comment; }
/// <exception cref="ArgumentNullException"> /// <paramref name="comment"/> is null.-or- /// <paramref name="entity"/> is null. /// </exception> internal CommentRelationship(Comment comment, IEntity entity) { this.comment = comment ?? throw new ArgumentNullException("comment"); this.entity = entity ?? throw new ArgumentNullException("entity"); Attach(); }
public CommentRelationship Clone(Comment comment, IEntity entity) { CommentRelationship relationship = new CommentRelationship(comment, entity); relationship.CopyFrom(this); return relationship; }