public static Tuple <Broadcast.Broadcast_Channel, ApiCallResponse> get(string access_token, string id) { Channels.channelParameters parameters = new Channels.channelParameters(); parameters.channel_types = "net.app.core.broadcast"; parameters.include_annotations = true; Tuple <Channel, ApiCallResponse> channel = Channels.get(access_token, id); if (channel.Item2.success) { return(new Tuple <Broadcast.Broadcast_Channel, ApiCallResponse>(new Broadcast.Broadcast_Channel(channel.Item1), channel.Item2)); } else { return(new Tuple <Broadcast.Broadcast_Channel, ApiCallResponse>(null, channel.Item2)); } }
public static Tuple <List <Broadcast.Broadcast_Channel>, ApiCallResponse> getOfCurrentUser(string access_token) { Channels.channelParameters parameters = new Channels.channelParameters(); parameters.channel_types = "net.app.core.broadcast"; parameters.include_annotations = true; Tuple <List <Channel>, ApiCallResponse> channels = Channels.Subscriptions.getOfCurrentUser(access_token, parameters); if (channels.Item2.success) { List <Broadcast.Broadcast_Channel> broadcast_channels = new List <Broadcast.Broadcast_Channel>(); foreach (Channel channel in channels.Item1) { broadcast_channels.Add(new Broadcast.Broadcast_Channel(channel)); } return(new Tuple <List <Broadcast.Broadcast_Channel>, ApiCallResponse>(broadcast_channels, channels.Item2)); } else { return(new Tuple <List <Broadcast.Broadcast_Channel>, ApiCallResponse>(null, channels.Item2)); } }