Class: Google::Apis::DlpV2::GooglePrivacyDlpV2Regex

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/dlp_v2/classes.rb,
lib/google/apis/dlp_v2/representations.rb,
lib/google/apis/dlp_v2/representations.rb

Overview

Message defining a custom regular expression.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GooglePrivacyDlpV2Regex

Returns a new instance of GooglePrivacyDlpV2Regex.



8131
8132
8133
# File 'lib/google/apis/dlp_v2/classes.rb', line 8131

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#group_indexesArray<Fixnum>

The index of the submatch to extract as findings. When not specified, the entire match is returned. No more than 3 may be included. Corresponds to the JSON property groupIndexes

Returns:

  • (Array<Fixnum>)


8123
8124
8125
# File 'lib/google/apis/dlp_v2/classes.rb', line 8123

def group_indexes
  @group_indexes
end

#patternString

Pattern defining the regular expression. Its syntax (https://github.com/google/ re2/wiki/Syntax) can be found under the google/re2 repository on GitHub. Corresponds to the JSON property pattern

Returns:

  • (String)


8129
8130
8131
# File 'lib/google/apis/dlp_v2/classes.rb', line 8129

def pattern
  @pattern
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



8136
8137
8138
8139
# File 'lib/google/apis/dlp_v2/classes.rb', line 8136

def update!(**args)
  @group_indexes = args[:group_indexes] if args.key?(:group_indexes)
  @pattern = args[:pattern] if args.key?(:pattern)
end