Advertisement
Guest User

Untitled

a guest
Apr 25th, 2019
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package ch.makery.address.model;
  2.  
  3. import java.io.Serializable;
  4. import java.time.LocalDate;
  5. import javafx.beans.property.IntegerProperty;
  6. import javafx.beans.property.SimpleIntegerProperty;
  7. import javafx.beans.property.SimpleStringProperty;
  8. import javafx.beans.property.StringProperty;
  9.  
  10. public class Dogovor implements Serializable {
  11. transient private IntegerProperty nomerProperty;
  12. transient private StringProperty kontrProperty;
  13.  
  14. private int nomer;
  15. private String tip;
  16. private String kontr;
  17. private String otvl;
  18. private String form;
  19. private LocalDate data;
  20.  
  21. public Dogovor() {
  22. this.kontr = "";
  23. this.tip = "";
  24. this.otvl = "";
  25. this.nomer = -1;
  26. this.form = "";
  27. this.data = LocalDate.of(1999, 2, 21);
  28.  
  29. this.nomerProperty = new SimpleIntegerProperty(this.nomer);
  30. this.kontrProperty = new SimpleStringProperty(this.kontr);
  31. }
  32.  
  33. @Override
  34. private Object readResolve() {
  35. this.nomerProperty = new SimpleIntegerProperty(this.nomer);
  36. this.kontrProperty = new SimpleStringProperty(this.kontr);
  37. return this;
  38. }
  39.  
  40. public int getNomer() {
  41. return nomer;
  42. }
  43.  
  44. public void setNomer(int nomer) {
  45. this.nomerProperty.setValue(nomer);
  46. this.nomer = nomer;
  47. }
  48.  
  49. public String getTip() {
  50. return tip;
  51. }
  52.  
  53. public void setTip(String tip) {
  54. this.tip = tip;
  55. }
  56.  
  57. public String getKontr() {
  58. return kontr;
  59. }
  60.  
  61. public void setKontr(String kontr) {
  62. this.kontrProperty.setValue(kontr);
  63. this.kontr = kontr;
  64. }
  65.  
  66. public String getOtvl() {
  67. return otvl;
  68. }
  69.  
  70. public void setOtvl(String otvl) {
  71. this.otvl = otvl;
  72. }
  73.  
  74. public String getForm() {
  75. return form;
  76. }
  77.  
  78. public void setForm(String form) {
  79. this.form = form;
  80. }
  81.  
  82. public LocalDate getData() {
  83. return data;
  84. }
  85.  
  86. public void setData(LocalDate data) {
  87. this.data = data;
  88. }
  89.  
  90. public IntegerProperty getNomerProperty() {
  91. return nomerProperty;
  92. }
  93.  
  94. public StringProperty getKontrProperty() {
  95. return kontrProperty;
  96. }
  97. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement