/// <summary> /// Привести к типу VkParameters. /// </summary> /// <param name="p">Параметры.</param> /// <returns></returns> public static VkParameters ToVkParameters(VideoEditParams p) { var parameters = new VkParameters { { "owner_id", p.OwnerId }, { "video_id", p.VideoId }, { "name", p.Name }, { "desc", p.Desc }, { "privacy_view", p.PrivacyView }, { "privacy_comment", p.PrivacyComment }, { "no_comments", p.NoComments }, { "repeat", p.Repeat } }; return(parameters); }
public bool Edit(long videoId, long? ownerId = null, string name = null, string description = null, IEnumerable<Privacy> privacyView = null, IEnumerable<Privacy> privacyComment = null, bool isRepeat = false) { VkErrors.ThrowIfNumberIsNegative(() => videoId); var parameters = new VideoEditParams { VideoId = videoId, OwnerId = ownerId, Name = name, Desc = description, PrivacyComment = privacyComment, PrivacyView = privacyView, Repeat = isRepeat }; return Edit(parameters); }
public bool Edit(VideoEditParams @params) { VkErrors.ThrowIfNumberIsNegative(() => @params.VideoId); return _vk.Call("video.edit", @params); }
/// <summary> /// Привести к типу VkParameters. /// </summary> /// <param name="p">Параметры.</param> /// <returns></returns> internal static VkParameters ToVkParameters(VideoEditParams p) { var parameters = new VkParameters { { "owner_id", p.OwnerId }, { "video_id", p.VideoId }, { "name", p.Name }, { "desc", p.Desc }, { "privacy_view", p.PrivacyView }, { "privacy_comment", p.PrivacyComment }, { "no_comments", p.NoComments }, { "repeat", p.Repeat } }; return parameters; }