TimeInfo.js 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. function TimeInfo() {
  2. if(arguments[0] != "__skip_ptr__") {
  3. this.__ptr = Polycode.TimeInfo()
  4. }
  5. Object.defineProperties(this, {
  6. 'seconds': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_seconds, set: TimeInfo.prototype.__set_seconds},
  7. 'minutes': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_minutes, set: TimeInfo.prototype.__set_minutes},
  8. 'hours': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_hours, set: TimeInfo.prototype.__set_hours},
  9. 'month': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_month, set: TimeInfo.prototype.__set_month},
  10. 'monthDay': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_monthDay, set: TimeInfo.prototype.__set_monthDay},
  11. 'weekDay': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_weekDay, set: TimeInfo.prototype.__set_weekDay},
  12. 'year': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_year, set: TimeInfo.prototype.__set_year},
  13. 'yearDay': { enumerable: true, configurable: true, get: TimeInfo.prototype.__get_yearDay, set: TimeInfo.prototype.__set_yearDay}
  14. })
  15. }
  16. TimeInfo.prototype.__get_seconds = function() {
  17. return Polycode.TimeInfo__get_seconds(this.__ptr)
  18. }
  19. TimeInfo.prototype.__set_seconds = function(val) {
  20. Polycode.TimeInfo__set_seconds(this.__ptr, val)
  21. }
  22. TimeInfo.prototype.__get_minutes = function() {
  23. return Polycode.TimeInfo__get_minutes(this.__ptr)
  24. }
  25. TimeInfo.prototype.__set_minutes = function(val) {
  26. Polycode.TimeInfo__set_minutes(this.__ptr, val)
  27. }
  28. TimeInfo.prototype.__get_hours = function() {
  29. return Polycode.TimeInfo__get_hours(this.__ptr)
  30. }
  31. TimeInfo.prototype.__set_hours = function(val) {
  32. Polycode.TimeInfo__set_hours(this.__ptr, val)
  33. }
  34. TimeInfo.prototype.__get_month = function() {
  35. return Polycode.TimeInfo__get_month(this.__ptr)
  36. }
  37. TimeInfo.prototype.__set_month = function(val) {
  38. Polycode.TimeInfo__set_month(this.__ptr, val)
  39. }
  40. TimeInfo.prototype.__get_monthDay = function() {
  41. return Polycode.TimeInfo__get_monthDay(this.__ptr)
  42. }
  43. TimeInfo.prototype.__set_monthDay = function(val) {
  44. Polycode.TimeInfo__set_monthDay(this.__ptr, val)
  45. }
  46. TimeInfo.prototype.__get_weekDay = function() {
  47. return Polycode.TimeInfo__get_weekDay(this.__ptr)
  48. }
  49. TimeInfo.prototype.__set_weekDay = function(val) {
  50. Polycode.TimeInfo__set_weekDay(this.__ptr, val)
  51. }
  52. TimeInfo.prototype.__get_year = function() {
  53. return Polycode.TimeInfo__get_year(this.__ptr)
  54. }
  55. TimeInfo.prototype.__set_year = function(val) {
  56. Polycode.TimeInfo__set_year(this.__ptr, val)
  57. }
  58. TimeInfo.prototype.__get_yearDay = function() {
  59. return Polycode.TimeInfo__get_yearDay(this.__ptr)
  60. }
  61. TimeInfo.prototype.__set_yearDay = function(val) {
  62. Polycode.TimeInfo__set_yearDay(this.__ptr, val)
  63. }
  64. Duktape.fin(TimeInfo.prototype, function (x) {
  65. if (x === TimeInfo.prototype) {
  66. return;
  67. }
  68. Polycode.TimeInfo__delete(x.__ptr)
  69. })