/tutorial/external/C++/Foo.cpp

http://github.com/tybor/Liberty · C++ · 19 lines · 13 code · 5 blank · 1 comment · 0 complexity · 6acd538e7e007856281d04a242f31778 MD5 · raw file

  1. // Basic C++ class to test the Liberty Eiffel C++ interface
  2. #include "Foo.h"
  3. int Foo::get_integer() {
  4. return integer_attribute;
  5. }
  6. float Foo::get_real() {
  7. return real_attribute;
  8. }
  9. void Foo::set_integer(int i) {
  10. integer_attribute = i;
  11. }
  12. void Foo::set_real(float r) {
  13. real_attribute = r;
  14. }