public override GraphChangeStatus DeleteComment(CommentID commentId) { var pair = HostSet.AssignHost(commentId.G_Volume); return(Contracts.ServiceClientHub .CallWithRetry <IGraphCommentSystemClient, GraphChangeStatus>( commentSystem => commentSystem.DeleteComment(commentId), pair.Select(host => host.RegionPath) )); }
public override IEnumerable <Complaint> FetchComplaints(CommentID commentId) { var pair = HostSet.AssignHost(commentId.G_Volume); return(Contracts.ServiceClientHub .CallWithRetry <IGraphCommentSystemClient, IEnumerable <Complaint> >( commentSystem => commentSystem.FetchComplaints(commentId), pair.Select(host => host.RegionPath) )); }
public override GraphChangeStatus Update(CommentID ratingId, RatingValue value, string content, byte[] data) { var pair = HostSet.AssignHost(ratingId.G_Volume); return(Contracts.ServiceClientHub .CallWithRetry <IGraphCommentSystemClient, GraphChangeStatus>( commentSystem => commentSystem.Update(ratingId, value, content, data), pair.Select(host => host.RegionPath) )); }
public override GraphChangeStatus Complain(CommentID commentId, GDID gAuthorNode, string kind, string message) { var pair = HostSet.AssignHost(commentId.G_Volume); return(Contracts.ServiceClientHub .CallWithRetry <IGraphCommentSystemClient, GraphChangeStatus>( commentSystem => commentSystem.Complain(commentId, gAuthorNode, kind, message), pair.Select(host => host.RegionPath) )); }
public override Comment Respond(GDID gAuthorNode, CommentID parent, string content, byte[] data) { var pair = HostSet.AssignHost(parent.G_Volume); return(Contracts.ServiceClientHub .CallWithRetry <IGraphCommentSystemClient, Comment>( commentSystem => commentSystem.Respond(gAuthorNode, parent, content, data), pair.Select(host => host.RegionPath) )); }
public override GraphChangeStatus Like(CommentID commentId, int deltaLike, int deltaDislike) { var pair = HostSet.AssignHost(commentId.G_Volume); return(Contracts.ServiceClientHub .CallWithRetry <IGraphCommentSystemClient, GraphChangeStatus>( commentSystem => commentSystem.Like(commentId, deltaLike, deltaDislike), pair.Select(host => host.RegionPath) )); }
public Complaint(CommentID commentID, GDID gComplaint, GraphNode authorNode, string kind, string message, DateTime createDate, bool inUse) { CommentID = commentID; GDID = gComplaint; AuthorNode = authorNode; Kind = kind; Message = message; Create_Date = createDate; In_Use = inUse; }
/// <summary> /// Comment /// </summary> /// <param name="id">ID</param> /// <param name="parentId">Parent comment ID</param> /// <param name="authorNode">Author node</param> /// <param name="targetNode">Target node</param> /// <param name="createDate">Creation Date</param> /// <param name="dimension">Scope of comments</param> /// <param name="publicationState">Publication state</param> /// <param name="rating">Rating (0,1,2,3,4,5)</param> /// <param name="message">Message</param> /// <param name="data">Data</param> /// <param name="likes">Likes count</param> /// <param name="dislikes">Dislikes count</param> /// <param name="complaintCount">Complaint count</param> /// <param name="responseCount">Response count</param> /// <param name="inUse">In use (InUse = false - comment has been deleted)</param> /// <param name="editable">Can be edited</param> public Comment(CommentID id, CommentID?parentId, GraphNode authorNode, GraphNode targetNode, DateTime createDate, string dimension, PublicationState publicationState, RatingValue rating, string message, byte[] data, uint likes, uint dislikes, uint complaintCount, uint responseCount, bool inUse, bool editable) { ID = id; ParentID = parentId; AuthorNode = authorNode; TargetNode = targetNode; Create_Date = createDate; Dimension = dimension; PublicationState = publicationState; Rating = rating; Message = message; Data = data; Likes = likes; Dislikes = dislikes; ComplaintCount = complaintCount; ResponseCount = responseCount; IsRoot = !parentId.HasValue; In_Use = inUse; Editable = editable; }
public abstract IEnumerable <Complaint> FetchComplaints(CommentID commentId);
public abstract Comment GetComment(CommentID commentId);
public abstract GraphChangeStatus Like(CommentID commentId, int deltaLike, int deltaDislike);
public abstract IEnumerable <Comment> FetchResponses(CommentID commentId);
public override GraphChangeStatus Complain(CommentID commentId, GDID gAuthorNode, string kind, string message) { return(GraphChangeStatus.NotFound); }
public abstract GraphChangeStatus DeleteComment(CommentID commentId);
public override GraphChangeStatus DeleteComment(CommentID commentId) { return(GraphChangeStatus.NotFound); }
/// <summary> /// Make new Comment /// </summary> internal static Comment MakeNew(CommentID commentID, CommentID?parentID, GraphNode authorNode, GraphNode targetNode, DateTime create_Date, string dimension, PublicationState publicationState, RatingValue rating, string message, byte[] data) { return(new Comment(commentID, parentID, authorNode, targetNode, create_Date, dimension, publicationState, rating, message, data, 0, 0, 0, 0, true, true)); }
public override GraphChangeStatus Like(CommentID commentId, int deltaLike, int deltaDislike) { return(GraphChangeStatus.NotFound); }
public override GraphChangeStatus Update(CommentID ratingId, RatingValue value, string content, byte[] data) { return(GraphChangeStatus.NotFound); }
public override IEnumerable <Comment> FetchResponses(CommentID commentId) { yield break; }
public override IEnumerable <Complaint> FetchComplaints(CommentID commentId) { yield break; }
public override GraphChangeStatus Justify(CommentID commentID) { return(GraphChangeStatus.NotFound); }
public abstract GraphChangeStatus Complain(CommentID commentId, GDID gAuthorNode, string kind, string message);
public abstract Comment Respond(GDID gAuthorNode, CommentID parent, string content, byte[] data);
public abstract GraphChangeStatus Justify(CommentID commentId);
public abstract GraphChangeStatus Update(CommentID ratingId, RatingValue value, string content, byte[] data);
public override Comment Respond(GDID gAuthorNode, CommentID parent, string content, byte[] data) { return(default(Comment)); }
public override Comment GetComment(CommentID commentId) { return(default(Comment)); }