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
{{{
278 279 280 281 282 283 |
# File 'lib/ruby/riddl/wrapper.rb', line 278 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.
304 305 306 |
# File 'lib/ruby/riddl/wrapper.rb', line 304 def in @in end |
#interface ⇒ Object (readonly)
Returns the value of attribute interface.
304 305 306 |
# File 'lib/ruby/riddl/wrapper.rb', line 304 def interface @interface end |
#out ⇒ Object (readonly)
Returns the value of attribute out.
304 305 306 |
# File 'lib/ruby/riddl/wrapper.rb', line 304 def out @out end |
#route ⇒ Object (readonly)
Returns the value of attribute route.
304 305 306 |
# File 'lib/ruby/riddl/wrapper.rb', line 304 def route @route end |
Instance Method Details
#route? ⇒ Boolean
284 285 286 |
# File 'lib/ruby/riddl/wrapper.rb', line 284 def route? !(route.nil? || route.empty?) end |
#route_to_a ⇒ Object
287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 |
# File 'lib/ruby/riddl/wrapper.rb', line 287 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 |