Class: Google::Apis::ChecksV1alpha::PolicySectionAnnotation
- Inherits:
-
Object
- Object
- Google::Apis::ChecksV1alpha::PolicySectionAnnotation
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- lib/google/apis/checks_v1alpha/classes.rb,
lib/google/apis/checks_v1alpha/representations.rb,
lib/google/apis/checks_v1alpha/representations.rb
Instance Attribute Summary collapse
-
#end_offset ⇒ Fixnum
Byte offsets for the end of the section inside the full text.
-
#score ⇒ Float
Score given by the model representing how confident it was regarding this
text_contentbeing ofsection_type. -
#section_type ⇒ String
Type of the high-level category in the policy.
-
#start_offset ⇒ Fixnum
Byte offsets for the start of the section inside the full text.
-
#text_content ⇒ String
Actual text content in the section.
Instance Method Summary collapse
-
#initialize(**args) ⇒ PolicySectionAnnotation
constructor
A new instance of PolicySectionAnnotation.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ PolicySectionAnnotation
Returns a new instance of PolicySectionAnnotation.
369 370 371 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 369 def initialize(**args) update!(**args) end |
Instance Attribute Details
#end_offset ⇒ Fixnum
Byte offsets for the end of the section inside the full text.
Corresponds to the JSON property endOffset
344 345 346 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 344 def end_offset @end_offset end |
#score ⇒ Float
Score given by the model representing how confident it was regarding this
text_content being of section_type.
Corresponds to the JSON property score
350 351 352 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 350 def score @score end |
#section_type ⇒ String
Type of the high-level category in the policy.
Corresponds to the JSON property sectionType
355 356 357 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 355 def section_type @section_type end |
#start_offset ⇒ Fixnum
Byte offsets for the start of the section inside the full text.
Corresponds to the JSON property startOffset
360 361 362 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 360 def start_offset @start_offset end |
#text_content ⇒ String
Actual text content in the section. This makes it much easier to consume the
information. NOTE: This field might contain HTML and does not guarantee a
SafeHtml security contract go/safehtmltypecontracts#safehtml.
Corresponds to the JSON property textContent
367 368 369 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 367 def text_content @text_content end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
374 375 376 377 378 379 380 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 374 def update!(**args) @end_offset = args[:end_offset] if args.key?(:end_offset) @score = args[:score] if args.key?(:score) @section_type = args[:section_type] if args.key?(:section_type) @start_offset = args[:start_offset] if args.key?(:start_offset) @text_content = args[:text_content] if args.key?(:text_content) end |