A fork of https://github.com/Synerty/SOAPpy-py3 This is a working tree till fixes get imported upstream.
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.
 
 
 
 

49 lines
1.0 KiB

  1. #!/usr/bin/python2
  2. #standard imports
  3. import syslog, sys
  4. #domain specific imports
  5. sys.path.insert (1, '..')
  6. import SOAPpy
  7. class test_service:
  8. run = 1
  9. def test_integer(self,pass_integer):
  10. print type(pass_integer)
  11. return pass_integer
  12. def test_string(self,pass_string):
  13. print type(pass_string)
  14. return pass_string
  15. def test_float(self,pass_float):
  16. print type(pass_float)
  17. return pass_float
  18. def test_tuple(self,pass_tuple):
  19. print type(pass_tuple), pass_tuple
  20. return pass_tuple
  21. def test_list(self,pass_list):
  22. print type(pass_list), pass_list
  23. return pass_list
  24. def test_dictionary(self,pass_dictionary):
  25. print type(pass_dictionary), pass_dictionary
  26. return pass_dictionary
  27. def quit(self):
  28. self.run = 0
  29. server = SOAPpy.SOAPServer(("localhost",9999))
  30. SOAPpy.Config.simplify_objects=1
  31. access_object = test_service()
  32. server.registerObject(access_object)
  33. while access_object.run:
  34. server.handle_request()