ApiCore.Wall.WallFactory.AddComment C# (CSharp) Метод

AddComment() публичный Метод

public AddComment ( int ownerId, int postId, string msg, int replyToCid ) : int
ownerId int
postId int
msg string
replyToCid int
Результат int
        public int AddComment(int? ownerId, int postId, string msg, int? replyToCid)
        {
            this.Manager.Method("wall.addComment");
            if (ownerId != null)
            {
                this.Manager.Params("owner_id", ownerId);//((type == MessageType.Outgoing) ? "1" : "0"));;
            }
            this.Manager.Params("post_id", postId);
            this.Manager.Params("text", msg);
            if (replyToCid != null)
            {
                this.Manager.Params("reply_to_cid", replyToCid);
            }
            string resp = this.Manager.Execute().GetResponseString();
            if (this.Manager.MethodSuccessed)
            {
                XmlDocument x = this.Manager.GetXmlDocument(resp);
                XmlUtils.UseNode(x.SelectSingleNode("/response"));
                return XmlUtils.Int("cid");
            }
            return -1;
        }