Class: ActiveFacts::Metamodel::LinkFactType::ImplicitReading

Inherits:
Object
  • Object
show all
Defined in:
lib/activefacts/vocabulary/extensions.rb

Overview

This is only used for debugging, from RoleRef#describe

Defined Under Namespace

Classes: ImplicitReadingRoleSequence

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(fact_type, text) ⇒ ImplicitReading

Returns a new instance of ImplicitReading.



864
865
866
867
# File 'lib/activefacts/vocabulary/extensions.rb', line 864

def initialize(fact_type, text)
  @fact_type = fact_type
  @text = text
end

Instance Attribute Details

#fact_typeObject

Returns the value of attribute fact_type.



861
862
863
# File 'lib/activefacts/vocabulary/extensions.rb', line 861

def fact_type
  @fact_type
end

#is_negativeObject (readonly)

Never true



862
863
864
# File 'lib/activefacts/vocabulary/extensions.rb', line 862

def is_negative
  @is_negative
end

#textObject

Returns the value of attribute text.



861
862
863
# File 'lib/activefacts/vocabulary/extensions.rb', line 861

def text
  @text
end

Instance Method Details

#expandObject



907
908
909
# File 'lib/activefacts/vocabulary/extensions.rb', line 907

def expand
  @fact_type.default_reading
end

#ordinalObject



905
# File 'lib/activefacts/vocabulary/extensions.rb', line 905

def ordinal; 0; end

#role_sequenceObject



901
902
903
# File 'lib/activefacts/vocabulary/extensions.rb', line 901

def role_sequence
  ImplicitReadingRoleSequence.new([@fact_type.implying_role, @fact_type.all_role.single])
end