google-code-export / umple

Automatically exported from code.google.com/p/umple
1 stars 0 forks source link

Ruby method declaration - Boolean methods should have ? at the end #390

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Choose Ruby to be the language for code generation
2. Create an arbitrary class
3. Add method "isClassified?"

What is the expected output? What do you see instead?
class Arbitrary

What version of the product are you using? On what operating system?
Chrome 27 on Mountain Lion

Please provide any additional information below.

Original issue reported on code.google.com by xigba...@gmail.com on 28 May 2013 at 5:03

GoogleCodeExporter commented 9 years ago
The expected output section was not completed. It's meant to read:

Expected:
class Arbitrary
  def isClassified?
  end
end

Got:
The "isClassified?" input got ignored. It was not even added as an attribute

Original comment by xigba...@gmail.com on 28 May 2013 at 5:08

GoogleCodeExporter commented 9 years ago
The following code
class X {
   Boolean classified;
}
Will generate an is_classified method in Ruby. However, it ought to have a ? on 
the end of its name

Simply specifying a method is_classified can, however be done thus; this will 
create a valid ruby method
class X {
  Boolean isclassified?() {};
}

So the real issue is that the Boolean generated method should have a ?

Original comment by TimothyCLethbridge on 17 Jun 2013 at 3:37

GoogleCodeExporter commented 9 years ago

Original comment by TimothyCLethbridge on 12 Sep 2013 at 2:39

GoogleCodeExporter commented 9 years ago

Original comment by jc.jaysee314 on 21 Sep 2013 at 1:35

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r3030.

Original comment by jc.jaysee314 on 22 Sep 2013 at 2:22