Class: OCL::UDeref

Inherits:
CUnary show all
Defined in:
lib/dbc/ocl.rb

Instance Method Summary collapse

Methods inherited from Unary

#to_cexp, #to_exp

Methods inherited from Block

check_condition, result, #to_s

Constructor Details

#initialize(exp) ⇒ UDeref

Returns a new instance of UDeref.

Raises:

  • (ParseError)

281
282
283
284
# File 'lib/dbc/ocl.rb', line 281

def initialize(exp)
	raise ParseError, "cannot dereference a condition" unless exp.cexp?
	super
end

Instance Method Details

#cexp?Boolean

Returns:

  • (Boolean)

286
# File 'lib/dbc/ocl.rb', line 286

def cexp?; true end

#csymbolObject


285
# File 'lib/dbc/ocl.rb', line 285

def csymbol; '*' end