Beispiel #1
0
        public static YoutubeChannelSections ForChannelId(this YoutubeChannelSections channelSections, string id)
        {
            var settings = channelSections.Settings.Clone();

            settings.ChannelId = id;
            return(ChannelSections(settings, channelSections.PartTypes.ToArray()));
        }
Beispiel #2
0
        public static YoutubeChannelSections RequestId(this YoutubeChannelSections channelSections, params string[] ids)
        {
            var settings = channelSections.Settings.Clone();

            settings.Id = settings.Id.AddItems(ids);
            return(ChannelSections(settings, channelSections.PartTypes.ToArray()));
        }
Beispiel #3
0
 public static YoutubeChannelSections RequestAllParts(this YoutubeChannelSections channelSections)
 {
     return(channelSections.RequestContentDetails()
            .RequestLocalizations()
            .RequestTargeting()
            .RequestSnippet());
 }
Beispiel #4
0
 public static YoutubeChannelSections RequestLocalizations(this YoutubeChannelSections channelSections)
 {
     return(channelSections.RequestPart(PartType.Localizations));
 }
Beispiel #5
0
 public static YoutubeChannelSections RequestContentDetails(this YoutubeChannelSections channelSections)
 {
     return(channelSections.RequestPart(PartType.ContentDetails));
 }
Beispiel #6
0
 public static IEnumerable <YoutubeChannelSection> TakePages(this YoutubeChannelSections channelSections, int pageCount)
 {
     return(channelSections.Take(channelSections.ResultsPerPage.GetValueOrDefault(ResultsPerPage) * pageCount));
 }
Beispiel #7
0
 public static YoutubeChannelSections RequestPart(this YoutubeChannelSections channelSections, PartType partType)
 {
     return(ChannelSections(channelSections.Settings.Clone(), channelSections.PartTypes.Append(partType).ToArray()));
 }
Beispiel #8
0
 public static IEnumerable <YoutubeChannelSection> TakePage(this YoutubeChannelSections channelSections)
 {
     return(channelSections.TakePages(1));
 }
Beispiel #9
0
 public static YoutubeChannelSections RequestSnippet(this YoutubeChannelSections channelSections)
 {
     return(channelSections.RequestPart(PartType.Snippet));
 }
Beispiel #10
0
 public static YoutubeChannelSections RequestTargeting(this YoutubeChannelSections channelSections)
 {
     return(channelSections.RequestPart(PartType.Targeting));
 }