Class: Google::Privacy::Dlp::V2::CloudStorageOptions

Inherits:
Object
  • Object
show all
Defined in:
lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/storage.rb

Overview

Options defining a file or a set of files (path ending with *) within a Google Cloud Storage bucket.

Defined Under Namespace

Modules: SampleMethod Classes: FileSet

Instance Attribute Summary collapse

Instance Attribute Details

#bytes_limit_per_fileInteger

Returns Max number of bytes to scan from a file. If a scanned file's size is bigger than this value then the rest of the bytes are omitted. Only one of bytes_limit_per_file and bytes_limit_per_file_percent can be specified.

Returns:

  • (Integer)

    Max number of bytes to scan from a file. If a scanned file's size is bigger than this value then the rest of the bytes are omitted. Only one of bytes_limit_per_file and bytes_limit_per_file_percent can be specified.



246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/storage.rb', line 246

class CloudStorageOptions
  # Set of files to scan.
  # @!attribute [rw] url
  #   @return [String]
  #     The url, in the format +gs://<bucket>/<path>+. Trailing wildcard in the
  #     path is allowed.
  class FileSet; end

  # How to sample bytes if not all bytes are scanned. Meaningful only when used
  # in conjunction with bytes_limit_per_file. If not specified, scanning would
  # start from the top.
  module SampleMethod
    SAMPLE_METHOD_UNSPECIFIED = 0

    # Scan from the top (default).
    TOP = 1

    # For each file larger than bytes_limit_per_file, randomly pick the offset
    # to start scanning. The scanned bytes are contiguous.
    RANDOM_START = 2
  end
end

#bytes_limit_per_file_percentInteger

Returns Max percentage of bytes to scan from a file. The rest are omitted. The number of bytes scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of bytes_limit_per_file and bytes_limit_per_file_percent can be specified.

Returns:

  • (Integer)

    Max percentage of bytes to scan from a file. The rest are omitted. The number of bytes scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of bytes_limit_per_file and bytes_limit_per_file_percent can be specified.



246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/storage.rb', line 246

class CloudStorageOptions
  # Set of files to scan.
  # @!attribute [rw] url
  #   @return [String]
  #     The url, in the format +gs://<bucket>/<path>+. Trailing wildcard in the
  #     path is allowed.
  class FileSet; end

  # How to sample bytes if not all bytes are scanned. Meaningful only when used
  # in conjunction with bytes_limit_per_file. If not specified, scanning would
  # start from the top.
  module SampleMethod
    SAMPLE_METHOD_UNSPECIFIED = 0

    # Scan from the top (default).
    TOP = 1

    # For each file larger than bytes_limit_per_file, randomly pick the offset
    # to start scanning. The scanned bytes are contiguous.
    RANDOM_START = 2
  end
end

#file_setGoogle::Privacy::Dlp::V2::CloudStorageOptions::FileSet



246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/storage.rb', line 246

class CloudStorageOptions
  # Set of files to scan.
  # @!attribute [rw] url
  #   @return [String]
  #     The url, in the format +gs://<bucket>/<path>+. Trailing wildcard in the
  #     path is allowed.
  class FileSet; end

  # How to sample bytes if not all bytes are scanned. Meaningful only when used
  # in conjunction with bytes_limit_per_file. If not specified, scanning would
  # start from the top.
  module SampleMethod
    SAMPLE_METHOD_UNSPECIFIED = 0

    # Scan from the top (default).
    TOP = 1

    # For each file larger than bytes_limit_per_file, randomly pick the offset
    # to start scanning. The scanned bytes are contiguous.
    RANDOM_START = 2
  end
end

#file_typesArray<Google::Privacy::Dlp::V2::FileType>

Returns List of file type groups to include in the scan. If empty, all files are scanned and available data format processors are applied.

Returns:

  • (Array<Google::Privacy::Dlp::V2::FileType>)

    List of file type groups to include in the scan. If empty, all files are scanned and available data format processors are applied.



246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/storage.rb', line 246

class CloudStorageOptions
  # Set of files to scan.
  # @!attribute [rw] url
  #   @return [String]
  #     The url, in the format +gs://<bucket>/<path>+. Trailing wildcard in the
  #     path is allowed.
  class FileSet; end

  # How to sample bytes if not all bytes are scanned. Meaningful only when used
  # in conjunction with bytes_limit_per_file. If not specified, scanning would
  # start from the top.
  module SampleMethod
    SAMPLE_METHOD_UNSPECIFIED = 0

    # Scan from the top (default).
    TOP = 1

    # For each file larger than bytes_limit_per_file, randomly pick the offset
    # to start scanning. The scanned bytes are contiguous.
    RANDOM_START = 2
  end
end

#files_limit_percentInteger

Returns Limits the number of files to scan to this percentage of the input FileSet. Number of files scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0.

Returns:

  • (Integer)

    Limits the number of files to scan to this percentage of the input FileSet. Number of files scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0.



246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/storage.rb', line 246

class CloudStorageOptions
  # Set of files to scan.
  # @!attribute [rw] url
  #   @return [String]
  #     The url, in the format +gs://<bucket>/<path>+. Trailing wildcard in the
  #     path is allowed.
  class FileSet; end

  # How to sample bytes if not all bytes are scanned. Meaningful only when used
  # in conjunction with bytes_limit_per_file. If not specified, scanning would
  # start from the top.
  module SampleMethod
    SAMPLE_METHOD_UNSPECIFIED = 0

    # Scan from the top (default).
    TOP = 1

    # For each file larger than bytes_limit_per_file, randomly pick the offset
    # to start scanning. The scanned bytes are contiguous.
    RANDOM_START = 2
  end
end

#sample_methodGoogle::Privacy::Dlp::V2::CloudStorageOptions::SampleMethod



246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/storage.rb', line 246

class CloudStorageOptions
  # Set of files to scan.
  # @!attribute [rw] url
  #   @return [String]
  #     The url, in the format +gs://<bucket>/<path>+. Trailing wildcard in the
  #     path is allowed.
  class FileSet; end

  # How to sample bytes if not all bytes are scanned. Meaningful only when used
  # in conjunction with bytes_limit_per_file. If not specified, scanning would
  # start from the top.
  module SampleMethod
    SAMPLE_METHOD_UNSPECIFIED = 0

    # Scan from the top (default).
    TOP = 1

    # For each file larger than bytes_limit_per_file, randomly pick the offset
    # to start scanning. The scanned bytes are contiguous.
    RANDOM_START = 2
  end
end