StubPlayObjectStoreClient

uk.gov.hmrc.objectstore.client.play.test.stub.StubPlayObjectStoreClient
class StubPlayObjectStoreClient(val config: ObjectStoreClientConfig)(implicit m: Materializer, ec: ExecutionContext) extends PlayObjectStoreClient, StubObjectStoreClient[Future]

Attributes

Graph
Supertypes
trait StubObjectStoreClient[Future]
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

override def deleteObject(path: File, owner: String)(implicit hc: HeaderCarrier): Future[Unit]

Attributes

Definition Classes
Inherited from:
StubObjectStoreClient
override def getObject[CONTENT](path: File, owner: String)(implicit cr: ObjectStoreContentRead[Future, ResBody, CONTENT], hc: HeaderCarrier): Future[Option[Object[CONTENT]]]

Attributes

Definition Classes
Inherited from:
StubObjectStoreClient
override def listObjects(path: Directory, owner: String)(implicit hc: HeaderCarrier): Future[ObjectListing]

Attributes

Definition Classes
Inherited from:
StubObjectStoreClient
def presignedDownloadUrl(path: File, owner: String)(implicit hc: HeaderCarrier): Future[PresignedDownloadUrl]

Get a presigned download URL for an object

Get a presigned download URL for an object

Value parameters

owner

Owner service of this object

path

Path of the object in object-store under owner

Attributes

Returns

PresignedDownloadUrl wrapped in the effect F

Note

The downloadUrl has an expiration of 15 minutes.

Inherited from:
ObjectStoreClient
override def putObject[CONTENT](path: File, content: CONTENT, retentionPeriod: RetentionPeriod, contentType: Option[String], contentMd5: Option[Md5Hash], owner: String)(implicit w: ObjectStoreContentWrite[Future, CONTENT, Request], hc: HeaderCarrier): Future[ObjectSummaryWithMd5]

Attributes

Definition Classes
Inherited from:
StubObjectStoreClient
def uploadFromUrl(from: URL, to: File, retentionPeriod: RetentionPeriod, contentType: Option[String], contentMd5: Option[Md5Hash], contentSha256: Option[Sha256Checksum], owner: String)(implicit hc: HeaderCarrier): Future[ObjectSummaryWithMd5]

Upload object from a url

Upload object from a url

Value parameters

contentMd5

Optional Base64 encoded MD5 hash of content

contentSha256

Optional Base64 encoded SHA-256 checksum of content

contentType

Optional Content-Type

from

Path of the object in object-store under owner

owner

Owner service of this object

retentionPeriod

Retention period of the object in object-store

to

Url of content to upload

Attributes

Returns

ObjectSummaryWithMd5 wrapped in the effect F

Note

Storing an object on an existing path will overwrite the previously stored object on that path.

Inherited from:
ObjectStoreClient
def zip(from: Directory, to: File, retentionPeriod: RetentionPeriod, fromOwner: String, toOwner: String)(implicit hc: HeaderCarrier): Future[ObjectSummaryWithMd5]

Zip objects in a directory

Zip objects in a directory

Value parameters

from

Path of the directory to be zipped

fromOwner

Owner service of the directory to be zipped

retentionPeriod

Retention period of the object in object-store

to

Path of the target zip file

toOwner

Owner service of the target zip file

Attributes

Returns

ObjectSummaryWithMd5 wrapped in the effect F

Inherited from:
ObjectStoreClient

Concrete fields

val config: ObjectStoreClientConfig