/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package ejb;

import java.io.Serializable;
import java.sql.Date;
import java.sql.Time;
import java.util.Vector;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;

/**
 *
 * @author zwergnase
 */
@Entity
public class SeyirDefteri implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    private Long id;

    // to whom it belongs
    private Long userId;
    private Date travelDate;
    private Vector<Long> trainId;
    private Vector<String> places; //both departure and arrival
    private Vector<Time> departureTime;
    private Vector<Time> arrivalTime;
    private float travelLength;
    private Vector<Float> cost;
    private float change;
    private int isTicket;

    public int getIsTicket() {
        return isTicket;
    }

    public void setIsTicket(int isTicket) {
        this.isTicket = isTicket;
    }

    public Vector<String> getPlaces() {
        return places;
    }

    public void setPlaces(Vector<String> places) {
        this.places = places;
    }

  

    public Vector<Time> getArrivalTime() {
        return arrivalTime;
    }

    public void setArrivalTime(Vector<Time> arrivalTime) {
        this.arrivalTime = arrivalTime;
    }

    public Vector<Float> getCost() {
        return cost;
    }

    public void setCost(Vector<Float> cost) {
        this.cost = cost;
    }


    public Vector<Time> getDepartureTime() {
        return departureTime;
    }

    public void setDepartureTime(Vector<Time> departureTime) {
        this.departureTime = departureTime;
    }

    public Vector<Long> getTrainId() {
        return trainId;
    }

    public void setTrainId(Vector<Long> trainId) {
        this.trainId = trainId;
    }

   
    public float getChange() {
        return change;
    }

    public void setChange(float change) {
        this.change = change;
    }
   
    public Date getTravelDate() {
        return travelDate;
    }

    public void setTravelDate(Date travelDate) {
        this.travelDate = travelDate;
    }

    public float getTravelLength() {
        return travelLength;
    }

    public void setTravelLength(float travelLength) {
        this.travelLength = travelLength;
    }


    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }



    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (id != null ? id.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof SeyirDefteri)) {
            return false;
        }
        SeyirDefteri other = (SeyirDefteri) object;
        if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "ejb.SeyirDefteri[id=" + id + "]";
    }

}