Sha256: 268b56d4298f6b9f31d9c1e9ed3d8c76ae034342086e349634715d3777f39bb9
Contents?: true
Size: 718 Bytes
Versions: 2
Compression:
Stored size: 718 Bytes
Contents
class Term attr_reader :label def initialize(termname) @label = termname end def opposite opposite = Term.new("non-#{@label}") return opposite end def distribution_subject(quantity) if quantity.label == 'universal' @distribution = Distribution.new('distributed') elsif quantity.label == 'particular' @distribution = Distribution.new('undistributed') end return @distribution end def distribution_predicate(quality) if quality.label == 'affirmative' @distribution = Distribution.new('undistributed') elsif quality.label == 'negative' @distribution = Distribution.new('distributed') end return @distribution end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
catlogic-0.0.2 | lib/catlogic/term.rb |
catlogic-0.0.1 | lib/catlogic/term.rb |