internal static TCollection GetCollectionBatch <TCollection, TResponse>( this ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, string prefix, string command, int offset, int limit) where TCollection : class, IEntityCollection <TResponse> { paginationValidator.Validate(offset, limit); return(soundCloudRawClient.Request <TCollection>(prefix, command, HttpMethod.Get, new Dictionary <string, object>().SetPagination(offset, limit))); }
internal PlaylistApi(string playlistId, ISoundCloudRawClient soundCloudRawClient, IPlaylistConverter playlistConverter) { this.playlistId = playlistId; this.soundCloudRawClient = soundCloudRawClient; this.playlistConverter = playlistConverter; prefix = string.Format("playlists/{0}", playlistId); }
internal CommentApi(string commentId, ISoundCloudRawClient soundCloudRawClient, ICommentConverter commentConverter) { this.soundCloudRawClient = soundCloudRawClient; this.commentConverter = commentConverter; prefix = string.Format("comments/{0}", commentId); }
internal ExploreApi(ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, IExploreCategoryConverter exploreCategoryConverter, ITrackConverter trackConverter) { this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.exploreCategoryConverter = exploreCategoryConverter; this.trackConverter = trackConverter; }
public SubresourceFactory( ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, ITrackConverter trackConverter, IUserConverter userConverter, IPlaylistConverter playlistConverter, ICommentConverter commentConverter, IGroupConverter groupConverter, IWebProfileConverter webProfileConverter, IConnectionConverter connectionConverter, IActivityResultConverter activityResultConverter, IApplicationConverter applicationConverter, IExploreCategoryConverter exploreCategoryConverter) { this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.trackConverter = trackConverter; this.userConverter = userConverter; this.playlistConverter = playlistConverter; this.commentConverter = commentConverter; this.groupConverter = groupConverter; this.webProfileConverter = webProfileConverter; this.connectionConverter = connectionConverter; this.activityResultConverter = activityResultConverter; this.applicationConverter = applicationConverter; this.exploreCategoryConverter = exploreCategoryConverter; }
internal TracksApi(ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, ITrackConverter trackConverter, ISearchParametersBuilder searchParametersBuilder) { this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.trackConverter = trackConverter; this.searchParametersBuilder = searchParametersBuilder; }
internal MeApi( ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, IUserConverter userConverter, ITrackConverter trackConverter, IPlaylistConverter playlistConverter, ICommentConverter commentConverter, IGroupConverter groupConverter, IWebProfileConverter webProfileConverter, IConnectionConverter connectionConverter, IActivityResultConverter activityResultConverter) : base( null, soundCloudRawClient, paginationValidator, userConverter, trackConverter, playlistConverter, commentConverter, groupConverter, webProfileConverter, prefix) { this.connectionConverter = connectionConverter; this.activityResultConverter = activityResultConverter; }
public Func <Dictionary <string, object>, Track[]> BuildGetter(ISoundCloudRawClient soundCloudRawClient) { return(parameters => { var tracks = soundCloudRawClient.Request <TrackCollection>(prefix, command, HttpMethod.Get, parameters, responseType: string.Empty, domain: Domain.ApiV2); return tracks.Collection; }); }
internal ResolveApi( ISoundCloudRawClient soundCloudRawClient, IGroupConverter groupConverter, IUserConverter userConverter, ITrackConverter trackConverter, IPlaylistConverter playlistConverter) { this.soundCloudRawClient = soundCloudRawClient; this.groupConverter = groupConverter; this.userConverter = userConverter; this.trackConverter = trackConverter; this.playlistConverter = playlistConverter; }
internal AppApi( string applicationId, IPaginationValidator paginationValidator, ISoundCloudRawClient soundCloudRawClient, IApplicationConverter applicationConverter, ITrackConverter trackConverter) { this.paginationValidator = paginationValidator; this.soundCloudRawClient = soundCloudRawClient; this.applicationConverter = applicationConverter; this.trackConverter = trackConverter; prefix = string.Format("apps/{0}", applicationId); }
public ISubresourceFactory CreateSubresourceFactory(ISoundCloudRawClient soundCloudRawClient) { return new SubresourceFactory( soundCloudRawClient, paginationValidator, trackConverter, userConverter, playlistConverter, commentConverter, groupConverter, webProfileConverter, connectionConverter, activityResultConverter, applicationConverter); }
public ISubresourceFactory CreateSubresourceFactory(ISoundCloudRawClient soundCloudRawClient) { return(new SubresourceFactory( soundCloudRawClient, paginationValidator, trackConverter, userConverter, playlistConverter, commentConverter, groupConverter, webProfileConverter, connectionConverter, activityResultConverter, applicationConverter)); }
internal GroupApi( string groupId, ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, IGroupConverter groupConverter, IUserConverter userConverter, ITrackConverter trackConverter) { this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.groupConverter = groupConverter; this.userConverter = userConverter; this.trackConverter = trackConverter; prefix = string.Format("groups/{0}", groupId); }
internal TrackApi( string trackId, ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, ITrackConverter trackConverter, IUserConverter userConverter, ICommentConverter commentConverter) { this.trackId = trackId; this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.trackConverter = trackConverter; this.userConverter = userConverter; this.commentConverter = commentConverter; prefix = string.Format("tracks/{0}", trackId); }
internal UserApi( string userId, ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, IUserConverter userConverter, ITrackConverter trackConverter, IPlaylistConverter playlistConverter, ICommentConverter commentConverter, IGroupConverter groupConverter, IWebProfileConverter webProfileConverter, string customPrefix = null) { this.userId = userId; this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.userConverter = userConverter; this.trackConverter = trackConverter; this.playlistConverter = playlistConverter; this.commentConverter = commentConverter; this.groupConverter = groupConverter; this.webProfileConverter = webProfileConverter; prefix = string.IsNullOrEmpty(customPrefix) ? string.Format("users/{0}", userId) : customPrefix; }
internal UsersApi(ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, IUserConverter userConverter) { this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.userConverter = userConverter; }
internal AuthApi(ISoundCloudRawClient soundCloudRawClient, IAccessTokenConverter accessTokenConverter) { this.soundCloudRawClient = soundCloudRawClient; this.accessTokenConverter = accessTokenConverter; }
public Func <Dictionary <string, object>, Track[]> BuildGetter(SCApiVersion version, ISoundCloudRawClient soundCloudRawClient) { var searchParametersBuilder = searchParametersBuilders.SingleOrDefault(x => x.Version == version); if (searchParametersBuilder == null) { throw new NotSupportedException(string.Format("Search for version {0} not supported", version)); } return(searchParametersBuilder.BuildGetter(soundCloudRawClient)); }
internal OEmbed(ISoundCloudRawClient soundCloudRawClient) { this.soundCloudRawClient = soundCloudRawClient; }
internal TracksApi(ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, ITrackConverter trackConverter) { this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.trackConverter = trackConverter; }
private static AuthApi CreateAuthApi(ISoundCloudRawClient soundCloudRawClient) { return new AuthApi(soundCloudRawClient, new AccessTokenConverter()); }
public ISoundCloudClient Build(ISoundCloudRawClient soundCloudRawClient) { return new SoundCloudClient(soundCloudRawClient.AccessToken, subresourceFactoryBuilder.CreateSubresourceFactory(soundCloudRawClient)); }
public ISoundCloudClient Build(ISoundCloudRawClient soundCloudRawClient) { return(new SoundCloudClient(soundCloudRawClient.AccessToken, subresourceFactoryBuilder.CreateSubresourceFactory(soundCloudRawClient))); }
public IUnauthorizedSoundCloudClient CreateUnauthorized(ISoundCloudRawClient soundCloudRawClient) { return new UnauthorizedSoundCloudClient(subresourceFactoryBuilder.CreateSubresourceFactory(soundCloudRawClient)); }
public IUnauthorizedSoundCloudClient CreateUnauthorized(ISoundCloudRawClient soundCloudRawClient) { return(new UnauthorizedSoundCloudClient(subresourceFactoryBuilder.CreateSubresourceFactory(soundCloudRawClient))); }
internal GroupsApi(ISoundCloudRawClient soundCloudRawClient, IPaginationValidator paginationValidator, IGroupConverter groupConverter) { this.soundCloudRawClient = soundCloudRawClient; this.paginationValidator = paginationValidator; this.groupConverter = groupConverter; }
private static AuthApi CreateAuthApi(ISoundCloudRawClient soundCloudRawClient) { return(new AuthApi(soundCloudRawClient, new AccessTokenConverter())); }
public Func <Dictionary <string, object>, Track[]> BuildGetter(ISoundCloudRawClient soundCloudRawClient) { return(parameters => soundCloudRawClient.Request <Track[]>(prefix, string.Empty, HttpMethod.Get, parameters)); }