Class: Riddl::Wrapper::IOMessages
- Inherits:
-
Object
- Object
- Riddl::Wrapper::IOMessages
- Defined in:
- lib/ruby/riddl/wrapper.rb
Instance Attribute Summary collapse
-
#in ⇒ Object
readonly
Returns the value of attribute in.
-
#interface ⇒ Object
readonly
Returns the value of attribute interface.
-
#out ⇒ Object
readonly
Returns the value of attribute out.
-
#route ⇒ Object
readonly
Returns the value of attribute route.
Instance Method Summary collapse
-
#initialize(min, mout, route = nil, interface = nil) ⇒ IOMessages
constructor
{{{.
- #route? ⇒ Boolean
- #route_to_a ⇒ Object
Constructor Details
#initialize(min, mout, route = nil, interface = nil) ⇒ IOMessages
{{{
301 302 303 304 305 306 |
# File 'lib/ruby/riddl/wrapper.rb', line 301 def initialize(min,mout,route=nil,interface=nil) @in = min @out = mout @route = route @interface = interface end |
Instance Attribute Details
#in ⇒ Object (readonly)
Returns the value of attribute in.
327 328 329 |
# File 'lib/ruby/riddl/wrapper.rb', line 327 def in @in end |
#interface ⇒ Object (readonly)
Returns the value of attribute interface.
327 328 329 |
# File 'lib/ruby/riddl/wrapper.rb', line 327 def interface @interface end |
#out ⇒ Object (readonly)
Returns the value of attribute out.
327 328 329 |
# File 'lib/ruby/riddl/wrapper.rb', line 327 def out @out end |
#route ⇒ Object (readonly)
Returns the value of attribute route.
327 328 329 |
# File 'lib/ruby/riddl/wrapper.rb', line 327 def route @route end |
Instance Method Details
#route? ⇒ Boolean
307 308 309 |
# File 'lib/ruby/riddl/wrapper.rb', line 307 def route? !(route.nil? || route.empty?) end |
#route_to_a ⇒ Object
310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 |
# File 'lib/ruby/riddl/wrapper.rb', line 310 def route_to_a if route? @route.map do |m| if m.class == Riddl::Wrapper::Description::RequestInOut Riddl::Wrapper::IOMessages.new(m.in, m.out,nil,m.interface) elsif m.class == Riddl::Wrapper::Description::RequestTransformation Riddl::Wrapper::IOMessages.new(Riddl::Wrapper::Description::Star.new, Riddl::Wrapper::Description::Star.new,nil,m.interface) elsif m.class == Riddl::Wrapper::Description::RequestStarOut Riddl::Wrapper::IOMessages.new(Riddl::Wrapper::Description::Star.new, m.out,nil,m.interface) elsif m.class == Riddl::Wrapper::Description::RequestPass Riddl::Wrapper::IOMessages.new(Riddl::Wrapper::Description::Star.new, Riddl::Wrapper::Description::Star.new,nil,m.interface) end end else [self] end end |