Class Notification (5.9.0)

A Notification object is created from your Bucket object using . Use it to interact with Cloud Pub/Sub notifications.

[Cloud Pub/Sub Notifications for Google Cloud Storage] https://cloud.google.com/storage/docs/pubsub-notifications

Inheritance

ServiceObject > Notification

Package

@google-cloud/storage!

Constructors

(constructor)(bucket, id)

  constructor 
 ( 
 bucket 
 : 
  
 Bucket 
 , 
  
 id 
 : 
  
 string 
 ); 
 

Constructs a new instance of the Notification class

Parameters
Name Description
bucket Bucket
id string

Methods

delete(options)

  delete 
 ( 
 options 
 ?: 
  
 DeleteNotificationOptions 
 ) 
 : 
  
 Promise 
< [ 
 Metadata 
 ]>; 
 
Parameter
Name Description
options DeleteNotificationOptions
Returns
Type Description
Promise <[ Metadata ]>

delete(options, callback)

  delete 
 ( 
 options 
 : 
  
 DeleteNotificationOptions 
 , 
  
 callback 
 : 
  
 DeleteNotificationCallback 
 ) 
 : 
  
 void 
 ; 
 
Parameters
Name Description
options DeleteNotificationOptions
callback DeleteNotificationCallback
Returns
Type Description
void

delete(callback)

  delete 
 ( 
 callback 
 : 
  
 DeleteNotificationCallback 
 ) 
 : 
  
 void 
 ; 
 
Parameter
Name Description
callback DeleteNotificationCallback
Returns
Type Description
void

get(options)

  get 
 ( 
 options 
 ?: 
  
 GetNotificationOptions 
 ) 
 : 
  
 Promise<GetNotificationResponse> 
 ; 
 
Parameter
Name Description
options GetNotificationOptions
Returns
Type Description
Promise < GetNotificationResponse >

get(options, callback)

  get 
 ( 
 options 
 : 
  
 GetNotificationOptions 
 , 
  
 callback 
 : 
  
 GetNotificationCallback 
 ) 
 : 
  
 void 
 ; 
 
Parameters
Name Description
options GetNotificationOptions
callback GetNotificationCallback
Returns
Type Description
void

get(callback)

  get 
 ( 
 callback 
 : 
  
 GetNotificationCallback 
 ) 
 : 
  
 void 
 ; 
 
Parameter
Name Description
callback GetNotificationCallback
Returns
Type Description
void
  getMetadata 
 ( 
 options 
 ?: 
  
 GetNotificationMetadataOptions 
 ) 
 : 
  
 Promise<GetNotificationMetadataResponse> 
 ; 
 
Parameter
Name Description
options GetNotificationMetadataOptions
Returns
Type Description
Promise < GetNotificationMetadataResponse >
  getMetadata 
 ( 
 options 
 : 
  
 GetNotificationMetadataOptions 
 , 
  
 callback 
 : 
  
 MetadataCallback 
 ) 
 : 
  
 void 
 ; 
 
Parameters
Name Description
options GetNotificationMetadataOptions
callback MetadataCallback
Returns
Type Description
void
  getMetadata 
 ( 
 callback 
 : 
  
 MetadataCallback 
 ) 
 : 
  
 void 
 ; 
 
Parameter
Name Description
callback MetadataCallback
Returns
Type Description
void
Design a Mobile Site
View Site in Mobile | Classic
Share by: