Class: Lara::Models::ProfanitiesResult
- Defined in:
- lib/lara/models/text.rb
Overview
Wraps profanity detection results for both target and (optionally) source text. Returned in TextResult#profanities when profanities_detect is set.
Instance Attribute Summary collapse
- #source ⇒ ProfanityDetectResult, ... readonly
- #target ⇒ ProfanityDetectResult, ... readonly
Instance Method Summary collapse
-
#initialize(target: nil, source: nil) ⇒ ProfanitiesResult
constructor
A new instance of ProfanitiesResult.
Methods inherited from Base
Constructor Details
#initialize(target: nil, source: nil) ⇒ ProfanitiesResult
Returns a new instance of ProfanitiesResult.
80 81 82 83 84 |
# File 'lib/lara/models/text.rb', line 80 def initialize(target: nil, source: nil) super() @target = target @source = source end |
Instance Attribute Details
#source ⇒ ProfanityDetectResult, ... (readonly)
78 79 80 |
# File 'lib/lara/models/text.rb', line 78 def source @source end |
#target ⇒ ProfanityDetectResult, ... (readonly)
76 77 78 |
# File 'lib/lara/models/text.rb', line 76 def target @target end |