Class: Google::Apis::CloudsearchV1::AppsDynamiteSharedTextSegment
- Inherits:
-
Object
- Object
- Google::Apis::CloudsearchV1::AppsDynamiteSharedTextSegment
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/cloudsearch_v1/classes.rb,
lib/google/apis/cloudsearch_v1/representations.rb,
lib/google/apis/cloudsearch_v1/representations.rb
Overview
Defines a segment in a text.
Instance Attribute Summary collapse
-
#length ⇒ Fixnum
Length of the segment in the text.
-
#start_index ⇒ Fixnum
Start index (0-indexed and inclusive) of the segment in the text.
Instance Method Summary collapse
-
#initialize(**args) ⇒ AppsDynamiteSharedTextSegment
constructor
A new instance of AppsDynamiteSharedTextSegment.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ AppsDynamiteSharedTextSegment
Returns a new instance of AppsDynamiteSharedTextSegment.
2511 2512 2513 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 2511 def initialize(**args) update!(**args) end |
Instance Attribute Details
#length ⇒ Fixnum
Length of the segment in the text.
Corresponds to the JSON property length
2504 2505 2506 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 2504 def length @length end |
#start_index ⇒ Fixnum
Start index (0-indexed and inclusive) of the segment in the text.
Corresponds to the JSON property startIndex
2509 2510 2511 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 2509 def start_index @start_index end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2516 2517 2518 2519 |
# File 'lib/google/apis/cloudsearch_v1/classes.rb', line 2516 def update!(**args) @length = args[:length] if args.key?(:length) @start_index = args[:start_index] if args.key?(:start_index) end |