Class GenomeAssemblyRemoteRepositoryImpl
- java.lang.Object
-
- ca.corefacility.bioinformatics.irida.repositories.remote.impl.RemoteRepositoryImpl<UploadedAssembly>
-
- ca.corefacility.bioinformatics.irida.repositories.remote.impl.GenomeAssemblyRemoteRepositoryImpl
-
- All Implemented Interfaces:
GenomeAssemblyRemoteRepository
,RemoteRepository<UploadedAssembly>
@Repository public class GenomeAssemblyRemoteRepositoryImpl extends RemoteRepositoryImpl<UploadedAssembly> implements GenomeAssemblyRemoteRepository
A repository implementaion for readingGenomeAssembly
from remote locations using aOAuthTokenRestTemplate
-
-
Field Summary
Fields Modifier and Type Field Description static org.springframework.http.MediaType
DEFAULT_DOWNLOAD_MEDIA_TYPE
-
Constructor Summary
Constructors Constructor Description GenomeAssemblyRemoteRepositoryImpl(RemoteAPITokenService tokenService, UserService userService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.nio.file.Path
downloadRemoteAssembly(java.lang.String uri, RemoteAPI remoteAPI)
java.nio.file.Path
downloadRemoteAssembly(java.lang.String uri, RemoteAPI remoteAPI, org.springframework.http.MediaType... mediaTypes)
Download aGenomeAssembly
fom the givenRemoteAPI
-
Methods inherited from class ca.corefacility.bioinformatics.irida.repositories.remote.impl.RemoteRepositoryImpl
getServiceStatus, list, read, setRemoteStatus
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface ca.corefacility.bioinformatics.irida.repositories.remote.RemoteRepository
getServiceStatus, list, read
-
-
-
-
Constructor Detail
-
GenomeAssemblyRemoteRepositoryImpl
@Autowired public GenomeAssemblyRemoteRepositoryImpl(RemoteAPITokenService tokenService, UserService userService)
-
-
Method Detail
-
downloadRemoteAssembly
public java.nio.file.Path downloadRemoteAssembly(java.lang.String uri, RemoteAPI remoteAPI, org.springframework.http.MediaType... mediaTypes)
Download aGenomeAssembly
fom the givenRemoteAPI
- Specified by:
downloadRemoteAssembly
in interfaceGenomeAssemblyRemoteRepository
- Parameters:
uri
- URI of the assembly to downloadremoteAPI
- theRemoteAPI
for the requestmediaTypes
- theMediaType
to use for the request- Returns:
- a
Path
to the downloaded file
-
downloadRemoteAssembly
public java.nio.file.Path downloadRemoteAssembly(java.lang.String uri, RemoteAPI remoteAPI)
- Specified by:
downloadRemoteAssembly
in interfaceGenomeAssemblyRemoteRepository
- Parameters:
uri
- URI of the assembly to downloadremoteAPI
- theRemoteAPI
for the request- Returns:
- a
Path
to the downloaded file
-
-