Back to project page spring-for-android-starter-book.
The source code is released under:
Apache License
If you think the Android project spring-for-android-starter-book listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package net.dahanne.spring.android.ch3.restful.example.recipeapp; /*from w w w .j a va2 s . co m*/ public class Recipe { private Long id; private String title; private String description; private String type; private String author; public Recipe() { super(); } public Recipe(Long id, String title, String description, String type, String author) { super(); this.id = id; this.title = title; this.description = description; this.type = type; this.author = author; } public Long getId() { return id; } public void setId(Long id) { this.id = id; } public String getTitle() { return title; } public void setTitle(String title) { this.title = title; } public String getDescription() { return description; } public void setDescription(String description) { this.description = description; } public String getType() { return type; } public void setType(String type) { this.type = type; } public String getAuthor() { return author; } public void setAuthor(String author) { this.author = author; } @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((id == null) ? 0 : id.hashCode()); return result; } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; Recipe other = (Recipe) obj; if (id == null) { if (other.id != null) return false; } else if (!id.equals(other.id)) return false; return true; } }