Guest User

Expenses

a guest
Sep 2nd, 2016
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.93 KB | None | 0 0
  1. package HomePlanner;
  2.  
  3. import javafx.beans.property.DoubleProperty;
  4. import javafx.beans.property.StringProperty;
  5.  
  6. import java.time.LocalDate;
  7. import java.util.Date;
  8. import java.util.Set;
  9. import java.util.TreeSet;
  10.  
  11. /**
  12.  * Created by mscib on 11.08.2016.
  13.  */
  14. public class Expenses {
  15.     private String category;
  16.  
  17.     public String getCategory() {
  18.         return category;
  19.     }
  20.     LocalDate date;
  21.  
  22.     private String name;
  23.  
  24.     public String getName() {
  25.         return name;
  26.     }
  27.  
  28.     private DoubleProperty cost;
  29.  
  30.     public double getCost() {
  31.         return cost.get();
  32.     }
  33.  
  34.     public DoubleProperty costProperty() {
  35.         return cost;
  36.     }
  37.  
  38.     public void setCost(double cost) {
  39.         this.cost.set(cost);
  40.     }
  41.  
  42.     public Expenses(String cat, String name, double cost,LocalDate date){
  43.         this.date= date;
  44.         category = cat;
  45.         this.name=name;
  46.         setCost(cost);
  47.     }
  48. }
Add Comment
Please, Sign In to add comment