object GCStorage
- Alphabetic
- By Inheritance
- GCStorage
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def createBucket(bucketName: String, location: String, system: ActorSystem, attributes: Attributes): CompletionStage[Bucket]
Creates a new bucket
Creates a new bucket
- bucketName
the name of the bucket
- location
the region to put the bucket in
- returns
a
CompletionStage
ofBucket
with created bucket
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/insert
- def createBucketSource(bucketName: String, location: String): Source[Bucket, NotUsed]
Creates a new bucket
Creates a new bucket
- bucketName
the name of the bucket
- location
the region to put the bucket in
- returns
a
Source
ofBucket
with created bucket
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/insert
- def deleteBucket(bucketName: String, system: ActorSystem, attributes: Attributes): CompletionStage[Done]
Deletes bucket
Deletes bucket
- bucketName
the name of the bucket
- returns
a
CompletionStage
ofDone
on successful deletion
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/delete
- def deleteBucketSource(bucketName: String): Source[Done, NotUsed]
Deletes bucket
Deletes bucket
- bucketName
the name of the bucket
- returns
a
Source
ofDone
on successful deletion
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/delete
- def deleteObject(bucketName: String, objectName: String, generation: Long): Source[Boolean, NotUsed]
Deletes object in bucket
Deletes object in bucket
- bucketName
the name of the bucket
- objectName
the name of the object
- generation
the generation of the object
- returns
a
Source
ofBoolean
withtrue
if object is deleted,false
if object that we want to deleted doesn't exist
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/delete
- def deleteObject(bucketName: String, objectName: String): Source[Boolean, NotUsed]
Deletes object in bucket
Deletes object in bucket
- bucketName
the name of the bucket
- objectName
the name of the object
- returns
a
Source
ofBoolean
withtrue
if object is deleted,false
if object that we want to deleted doesn't exist
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/delete
- def deleteObjects(bucket: String): Source[Boolean, NotUsed]
Deletes folder and its content.
Deletes folder and its content.
- bucket
the bucket name
- returns
a
Source
ofjava.lang.Boolean
with alltrue
if everything is deleted
- def deleteObjectsByPrefix(bucket: String, prefix: String): Source[Boolean, NotUsed]
Deletes folder and its content.
Deletes folder and its content.
- bucket
the bucket name
- prefix
the object prefix
- returns
a
Source
ofjava.lang.Boolean
with alltrue
if everything is deleted
- def download(bucket: String, objectName: String, generation: Long): Source[Optional[Source[ByteString, NotUsed]], NotUsed]
Downloads object from bucket.
Downloads object from bucket.
- bucket
the bucket name
- objectName
the bucket prefix
- generation
the generation of the object
- returns
The source will emit an empty Option if an object can not be found. Otherwise Option will contain a source of object's data.
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/get
- def download(bucket: String, objectName: String): Source[Optional[Source[ByteString, NotUsed]], NotUsed]
Downloads object from bucket.
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def getBucket(bucketName: String, system: ActorSystem, attributes: Attributes): CompletionStage[Optional[Bucket]]
Gets information on a bucket
Gets information on a bucket
- bucketName
the name of the bucket to look up
- system
actor system to run with
- attributes
attributes to run request with
- returns
a
CompletionStage
containingBucket
if it exists
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/get
- def getBucketSource(bucketName: String): Source[Optional[Bucket], NotUsed]
Gets information on a bucket
Gets information on a bucket
- bucketName
the name of the bucket to look up
- returns
a
Source
containingBucket
if it exists
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/get
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def getObject(bucket: String, objectName: String, generation: Long): Source[Optional[StorageObject], NotUsed]
Get storage object
Get storage object
- bucket
the name of the bucket
- objectName
the name of the object
- generation
the generation of the object
- returns
a
Source
containingStorageObject
if it exists
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/get
- def getObject(bucket: String, objectName: String): Source[Optional[StorageObject], NotUsed]
Get storage object
Get storage object
- bucket
the name of the bucket
- objectName
the name of the object
- returns
a
Source
containingStorageObject
if it exists
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/get
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def listBucket(bucket: String, prefix: String, versions: Boolean): Source[StorageObject, NotUsed]
Lists the bucket contents
Lists the bucket contents
- bucket
the bucket name
- prefix
the bucket prefix
- versions
if
true
list both live and archived bucket contents- returns
a
Source
ofStorageObject
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/list
- def listBucket(bucket: String, prefix: String): Source[StorageObject, NotUsed]
Lists the bucket contents
Lists the bucket contents
- bucket
the bucket name
- prefix
the bucket prefix
- returns
a
Source
ofStorageObject
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/list
- def listBucket(bucket: String): Source[StorageObject, NotUsed]
Lists the bucket contents
Lists the bucket contents
- bucket
the bucket name
- returns
a
Source
ofStorageObject
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/list
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def resumableUpload(bucket: String, objectName: String, contentType: ContentType): Sink[ByteString, CompletionStage[StorageObject]]
Uploads object by making multiple requests with default chunk size of 5MB
Uploads object by making multiple requests with default chunk size of 5MB
- bucket
the bucket name
- objectName
the object name
- contentType
ContentType
- returns
a
Sink
that acceptsByteString
's and materializes to ascala.concurrent.Future Future
ofStorageObject
- See also
https://cloud.google.com/storage/docs/json_api/v1/how-tos/resumable-upload
- def resumableUpload(bucket: String, objectName: String, contentType: ContentType, chunkSize: Integer): Sink[ByteString, CompletionStage[StorageObject]]
Uploads object by making multiple requests
Uploads object by making multiple requests
- bucket
the bucket name
- objectName
the object name
- contentType
ContentType
- chunkSize
the size of the request sent to google cloud storage in bytes, must be a multiple of 256KB
- returns
a
Sink
that acceptsByteString
's and materializes to aFuture
ofStorageObject
- See also
https://cloud.google.com/storage/docs/json_api/v1/how-tos/resumable-upload
- def resumableUpload(bucket: String, objectName: String, contentType: ContentType, chunkSize: Integer, metadata: Map[String, String]): Sink[ByteString, CompletionStage[StorageObject]]
Uploads object by making multiple requests
Uploads object by making multiple requests
- bucket
the bucket name
- objectName
the object name
- contentType
ContentType
- chunkSize
the size of the request sent to google cloud storage in bytes, must be a multiple of 256KB
- metadata
custom metadata for the object
- returns
a
Sink
that acceptsByteString
's and materializes to aFuture
ofStorageObject
- See also
https://cloud.google.com/storage/docs/json_api/v1/how-tos/resumable-upload
- def rewrite(sourceBucket: String, sourceObjectName: String, destinationBucket: String, destinationObjectName: String): RunnableGraph[CompletionStage[StorageObject]]
Rewrites object to wanted destination by making multiple requests.
Rewrites object to wanted destination by making multiple requests.
- sourceBucket
the source bucket
- sourceObjectName
the source object name
- destinationBucket
the destination bucket
- destinationObjectName
the destination bucket name
- returns
a runnable graph which upon materialization will return a
CompletionStage
containing theStorageObject
with info about rewritten file
- See also
https://cloud.google.com/storage/docs/json_api/v1/objects/rewrite
- def simpleUpload(bucket: String, objectName: String, data: Source[ByteString, _], contentType: ContentType): Source[StorageObject, NotUsed]
Uploads object, use this for small files and
resumableUpload
for big onesUploads object, use this for small files and
resumableUpload
for big ones- bucket
the bucket name
- objectName
the object name
- data
a
Source
ofByteString
- contentType
the number of bytes that will be uploaded (required!)
- returns
a
Source
containing theStorageObject
of the uploaded object
- See also
https://cloud.google.com/storage/docs/json_api/v1/how-tos/simple-upload
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
Deprecated Value Members
- def createBucket(bucketName: String, location: String, materializer: Materializer, attributes: Attributes): CompletionStage[Bucket]
Creates a new bucket
Creates a new bucket
- bucketName
the name of the bucket
- location
the region to put the bucket in
- returns
a
CompletionStage
ofBucket
with created bucket
- Annotations
- @deprecated
- Deprecated
(Since version 3.0.0) pass in the actor system instead of the materializer
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/insert
- def deleteBucket(bucketName: String, materializer: Materializer, attributes: Attributes): CompletionStage[Done]
Deletes bucket
Deletes bucket
- bucketName
the name of the bucket
- returns
a
CompletionStage
ofDone
on successful deletion
- Annotations
- @deprecated
- Deprecated
(Since version 3.0.0) pass in the actor system instead of the materializer
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/delete
- def getBucket(bucketName: String, materializer: Materializer, attributes: Attributes): CompletionStage[Optional[Bucket]]
Gets information on a bucket
Gets information on a bucket
- bucketName
the name of the bucket to look up
- materializer
materializer to run with
- attributes
attributes to run request with
- returns
a
CompletionStage
containingBucket
if it exists
- Annotations
- @deprecated
- Deprecated
(Since version 3.0.0) pass in the actor system instead of the materializer
- See also
https://cloud.google.com/storage/docs/json_api/v1/buckets/get