Class: Google::Privacy::Dlp::V2::RecordCondition

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

Overview

A condition for determining whether a transformation should be applied to a field.

Defined Under Namespace

Classes: Condition, Conditions, Expressions

Instance Attribute Summary collapse

Instance Attribute Details

#expressionsGoogle::Privacy::Dlp::V2::RecordCondition::Expressions

Returns An expression.



1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/dlp.rb', line 1357

class RecordCondition
  # The field type of +value+ and +field+ do not need to match to be
  # considered equal, but not all comparisons are possible.
  #
  # A +value+ of type:
  #
  # * +string+ can be compared against all other types
  # * +boolean+ can only be compared against other booleans
  # * +integer+ can be compared against doubles or a string if the string value
  #   can be parsed as an integer.
  # * +double+ can be compared against integers or a string if the string can
  #   be parsed as a double.
  # * +Timestamp+ can be compared against strings in RFC 3339 date string
  #   format.
  # * +TimeOfDay+ can be compared against timestamps and strings in the format
  #   of 'HH:mm:ss'.
  #
  # If we fail to compare do to type mismatch, a warning will be given and
  # the condition will evaluate to false.
  # @!attribute [rw] field
  #   @return [Google::Privacy::Dlp::V2::FieldId]
  #     Field within the record this condition is evaluated against. [required]
  # @!attribute [rw] operator
  #   @return [Google::Privacy::Dlp::V2::RelationalOperator]
  #     Operator used to compare the field or infoType to the value. [required]
  # @!attribute [rw] value
  #   @return [Google::Privacy::Dlp::V2::Value]
  #     Value to compare against. [Required, except for +EXISTS+ tests.]
  class Condition; end

  # A collection of conditions.
  # @!attribute [rw] conditions
  #   @return [Array<Google::Privacy::Dlp::V2::RecordCondition::Condition>]
  class Conditions; end

  # An expression, consisting or an operator and conditions.
  # @!attribute [rw] logical_operator
  #   @return [Google::Privacy::Dlp::V2::RecordCondition::Expressions::LogicalOperator]
  #     The operator to apply to the result of conditions. Default and currently
  #     only supported value is +AND+.
  # @!attribute [rw] conditions
  #   @return [Google::Privacy::Dlp::V2::RecordCondition::Conditions]
  class Expressions
    module LogicalOperator
      LOGICAL_OPERATOR_UNSPECIFIED = 0

      AND = 1
    end
  end
end