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.



1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
# File 'lib/google/cloud/dlp/v2/doc/google/privacy/dlp/v2/dlp.rb', line 1547

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