org.primefaces.extensions.showcase.model.Vehicle Maven / Gradle / Ivy
/*
* Copyright 2011-2020 PrimeFaces Extensions
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.primefaces.extensions.showcase.model;
import java.io.*;
import java.util.*;
/**
* Vehicle
*
* @author Sudheer Jonna / last modified by $Author$
* @version $Revision: 1.0 $
* @since 0.7.0
*/
public class Vehicle implements Serializable {
private static final long serialVersionUID = 1L;
private int model;
private String manufacturer;
private String color;
private int speed;
private int price;
private int year;
private List customers = new ArrayList<>();
public Vehicle(int model, String manufacturer, String color, int speed, int price, int year, List customers) {
this.model = model;
this.manufacturer = manufacturer;
this.color = color;
this.speed = speed;
this.price = price;
this.year = year;
this.customers = customers;
}
public int getModel() {
return model;
}
public void setModel(int model) {
this.model = model;
}
public String getManufacturer() {
return manufacturer;
}
public void setManufacturer(String manufacturer) {
this.manufacturer = manufacturer;
}
public String getColor() {
return color;
}
public void setColor(String color) {
this.color = color;
}
public int getSpeed() {
return speed;
}
public void setSpeed(int speed) {
this.speed = speed;
}
public int getPrice() {
return price;
}
public void setPrice(int price) {
this.price = price;
}
public int getYear() {
return year;
}
public void setYear(int year) {
this.year = year;
}
public List getCustomers() {
return customers;
}
public void setCustomers(List customers) {
this.customers = customers;
}
@Override
public boolean equals(Object obj) {
return super.equals(obj); // To change body of overridden methods use File | Settings | File Templates.
}
@Override
public int hashCode() {
return super.hashCode(); // To change body of overridden methods use File | Settings | File Templates.
}
@Override
public String toString() {
return "Car{" +
"model=" + model +
", manufacturer='" + manufacturer + '\'' +
", color='" + color + '\'' +
", speed=" + speed +
", price=" + price +
", year=" + year +
'}';
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy