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
Detected type of the high-level topic 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.
1499 1500 1501 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 1499 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
1476 1477 1478 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 1476 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
1482 1483 1484 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 1482 def score @score end |
#section_type ⇒ String
Detected type of the high-level topic in the policy.
Corresponds to the JSON property sectionType
1487 1488 1489 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 1487 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
1492 1493 1494 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 1492 def start_offset @start_offset end |
#text_content ⇒ String
Actual text content in the section.
Corresponds to the JSON property textContent
1497 1498 1499 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 1497 def text_content @text_content end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1504 1505 1506 1507 1508 1509 1510 |
# File 'lib/google/apis/checks_v1alpha/classes.rb', line 1504 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 |