@google-cloud/storage
Advanced tools
Comparing version 7.8.0 to 7.9.0
@@ -88,2 +88,3 @@ /// <reference types="node" /> | ||
pageToken?: string; | ||
softDeleted?: boolean; | ||
startOffset?: string; | ||
@@ -225,2 +226,6 @@ userProject?: string; | ||
rpo?: string; | ||
softDeletePolicy?: { | ||
retentionDurationSeconds?: string | number; | ||
readonly effectiveTime?: string; | ||
}; | ||
storageClass?: string; | ||
@@ -227,0 +232,0 @@ timeCreated?: string; |
@@ -16,3 +16,3 @@ /// <reference types="node" /> | ||
import { URL } from 'url'; | ||
import { BaseMetadata, DeleteCallback, DeleteOptions, RequestResponse, SetMetadataOptions } from './nodejs-common/service-object.js'; | ||
import { BaseMetadata, DeleteCallback, DeleteOptions, GetResponse, InstanceResponseCallback, RequestResponse, SetMetadataOptions } from './nodejs-common/service-object.js'; | ||
import * as r from 'teeny-request'; | ||
@@ -97,2 +97,4 @@ export type GetExpirationDateResponse = [Date]; | ||
userProject?: string; | ||
generation?: number; | ||
softDeleted?: boolean; | ||
} | ||
@@ -247,2 +249,6 @@ export type GetFileResponse = [File, unknown]; | ||
} | ||
export interface RestoreOptions extends PreconditionOptions { | ||
generation: number; | ||
projection?: 'full' | 'noAcl'; | ||
} | ||
export interface FileMetadata extends BaseMetadata { | ||
@@ -266,2 +272,3 @@ acl?: AclMetadata[] | null; | ||
generation?: string | number; | ||
hardDeleteTime?: string; | ||
kmsKeyName?: string; | ||
@@ -285,2 +292,3 @@ md5Hash?: string; | ||
size?: string | number; | ||
softDeleteTime?: string; | ||
storageClass?: string; | ||
@@ -831,2 +839,5 @@ temporaryHold?: boolean | null; | ||
setEncryptionKey(encryptionKey: string | Buffer): this; | ||
get(options?: GetFileOptions): Promise<GetResponse<File>>; | ||
get(callback: InstanceResponseCallback<File>): void; | ||
get(options: GetFileOptions, callback: InstanceResponseCallback<File>): void; | ||
getExpirationDate(): Promise<GetExpirationDateResponse>; | ||
@@ -873,2 +884,26 @@ getExpirationDate(callback: GetExpirationDateCallback): void; | ||
rename(destinationFile: string | File, options: RenameOptions, callback: RenameCallback): void; | ||
/** | ||
* @typedef {object} RestoreOptions Options for File#restore(). See an | ||
* {@link https://cloud.google.com/storage/docs/json_api/v1/objects#resource| Object resource}. | ||
* @param {string} [userProject] The ID of the project which will be | ||
* billed for the request. | ||
* @param {number} [generation] If present, selects a specific revision of this object. | ||
* @param {string} [projection] Specifies the set of properties to return. If used, must be 'full' or 'noAcl'. | ||
* @param {string | number} [ifGenerationMatch] Request proceeds if the generation of the target resource | ||
* matches the value used in the precondition. | ||
* If the values don't match, the request fails with a 412 Precondition Failed response. | ||
* @param {string | number} [ifGenerationNotMatch] Request proceeds if the generation of the target resource does | ||
* not match the value used in the precondition. If the values match, the request fails with a 304 Not Modified response. | ||
* @param {string | number} [ifMetagenerationMatch] Request proceeds if the meta-generation of the target resource | ||
* matches the value used in the precondition. | ||
* If the values don't match, the request fails with a 412 Precondition Failed response. | ||
* @param {string | number} [ifMetagenerationNotMatch] Request proceeds if the meta-generation of the target resource does | ||
* not match the value used in the precondition. If the values match, the request fails with a 304 Not Modified response. | ||
*/ | ||
/** | ||
* Restores a soft-deleted file | ||
* @param {RestoreOptions} options Restore options. | ||
* @returns {Promise<File>} | ||
*/ | ||
restore(options: RestoreOptions): Promise<File>; | ||
request(reqOpts: DecorateRequestOptions): Promise<RequestResponse>; | ||
@@ -875,0 +910,0 @@ request(reqOpts: DecorateRequestOptions, callback: BodyResponseCallback): void; |
@@ -88,2 +88,3 @@ /// <reference types="node" /> | ||
pageToken?: string; | ||
softDeleted?: boolean; | ||
startOffset?: string; | ||
@@ -225,2 +226,6 @@ userProject?: string; | ||
rpo?: string; | ||
softDeletePolicy?: { | ||
retentionDurationSeconds?: string | number; | ||
readonly effectiveTime?: string; | ||
}; | ||
storageClass?: string; | ||
@@ -227,0 +232,0 @@ timeCreated?: string; |
@@ -16,3 +16,3 @@ /// <reference types="node" /> | ||
import { URL } from 'url'; | ||
import { BaseMetadata, DeleteCallback, DeleteOptions, RequestResponse, SetMetadataOptions } from './nodejs-common/service-object.js'; | ||
import { BaseMetadata, DeleteCallback, DeleteOptions, GetResponse, InstanceResponseCallback, RequestResponse, SetMetadataOptions } from './nodejs-common/service-object.js'; | ||
import * as r from 'teeny-request'; | ||
@@ -97,2 +97,4 @@ export type GetExpirationDateResponse = [Date]; | ||
userProject?: string; | ||
generation?: number; | ||
softDeleted?: boolean; | ||
} | ||
@@ -247,2 +249,6 @@ export type GetFileResponse = [File, unknown]; | ||
} | ||
export interface RestoreOptions extends PreconditionOptions { | ||
generation: number; | ||
projection?: 'full' | 'noAcl'; | ||
} | ||
export interface FileMetadata extends BaseMetadata { | ||
@@ -266,2 +272,3 @@ acl?: AclMetadata[] | null; | ||
generation?: string | number; | ||
hardDeleteTime?: string; | ||
kmsKeyName?: string; | ||
@@ -285,2 +292,3 @@ md5Hash?: string; | ||
size?: string | number; | ||
softDeleteTime?: string; | ||
storageClass?: string; | ||
@@ -831,2 +839,5 @@ temporaryHold?: boolean | null; | ||
setEncryptionKey(encryptionKey: string | Buffer): this; | ||
get(options?: GetFileOptions): Promise<GetResponse<File>>; | ||
get(callback: InstanceResponseCallback<File>): void; | ||
get(options: GetFileOptions, callback: InstanceResponseCallback<File>): void; | ||
getExpirationDate(): Promise<GetExpirationDateResponse>; | ||
@@ -873,2 +884,26 @@ getExpirationDate(callback: GetExpirationDateCallback): void; | ||
rename(destinationFile: string | File, options: RenameOptions, callback: RenameCallback): void; | ||
/** | ||
* @typedef {object} RestoreOptions Options for File#restore(). See an | ||
* {@link https://cloud.google.com/storage/docs/json_api/v1/objects#resource| Object resource}. | ||
* @param {string} [userProject] The ID of the project which will be | ||
* billed for the request. | ||
* @param {number} [generation] If present, selects a specific revision of this object. | ||
* @param {string} [projection] Specifies the set of properties to return. If used, must be 'full' or 'noAcl'. | ||
* @param {string | number} [ifGenerationMatch] Request proceeds if the generation of the target resource | ||
* matches the value used in the precondition. | ||
* If the values don't match, the request fails with a 412 Precondition Failed response. | ||
* @param {string | number} [ifGenerationNotMatch] Request proceeds if the generation of the target resource does | ||
* not match the value used in the precondition. If the values match, the request fails with a 304 Not Modified response. | ||
* @param {string | number} [ifMetagenerationMatch] Request proceeds if the meta-generation of the target resource | ||
* matches the value used in the precondition. | ||
* If the values don't match, the request fails with a 412 Precondition Failed response. | ||
* @param {string | number} [ifMetagenerationNotMatch] Request proceeds if the meta-generation of the target resource does | ||
* not match the value used in the precondition. If the values match, the request fails with a 304 Not Modified response. | ||
*/ | ||
/** | ||
* Restores a soft-deleted file | ||
* @param {RestoreOptions} options Restore options. | ||
* @returns {Promise<File>} | ||
*/ | ||
restore(options: RestoreOptions): Promise<File>; | ||
request(reqOpts: DecorateRequestOptions): Promise<RequestResponse>; | ||
@@ -875,0 +910,0 @@ request(reqOpts: DecorateRequestOptions, callback: BodyResponseCallback): void; |
{ | ||
"name": "@google-cloud/storage", | ||
"description": "Cloud Storage Client Library for Node.js", | ||
"version": "7.8.0", | ||
"version": "7.9.0", | ||
"license": "Apache-2.0", | ||
@@ -6,0 +6,0 @@ "author": "Google Inc.", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1651808
36464