aRts audio server
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

77 lines
1.7KB

  1. /*
  2. Copyright (C) 1999 Stefan Westerfeld
  3. stefan@space.twc.de
  4. Modified by Nicolas Brodu, nicolas.brodu@free.fr
  5. This program is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 2 of the License, or
  8. (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program; if not, write to the Free Software
  15. Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  16. Permission is also granted to link this program with the Qt
  17. library, treating Qt like a library that normally accompanies the
  18. operating system kernel, whether or not that is in fact the case.
  19. */
  20. #include "hello_impl.h"
  21. #include <stdio.h>
  22. using namespace std;
  23. void Hello_impl::hellobase(const string& s)
  24. {
  25. printf("Hellobase '%s'!\n",s.c_str());
  26. }
  27. void Hello_impl::hello(const string& s)
  28. {
  29. printf("Hello '%s'!\n",s.c_str());
  30. }
  31. void Hello_impl::constructor(long i)
  32. {
  33. myvalue=i;
  34. }
  35. long Hello_impl::myValue()
  36. {
  37. return myvalue;
  38. }
  39. void Hello_impl::myValue(long newValue)
  40. {
  41. myvalue=newValue;
  42. }
  43. void Hello_impl::add(long a)
  44. {
  45. myvalue += a;
  46. }
  47. void Hello_impl::printTotal()
  48. {
  49. printf("Total=%ld\n",myvalue);
  50. }
  51. long Hello_impl::sum(long a, long b)
  52. {
  53. return a+b;
  54. }
  55. string Hello_impl::concat(const string& s1, const string& s2)
  56. {
  57. return s1+s2;
  58. }
  59. REGISTER_IMPLEMENTATION(Hello_impl);