Skip to content

Instantly share code, notes, and snippets.

@bullheadandplato
Created November 6, 2017 17:51
Show Gist options
  • Save bullheadandplato/bc61cdce8c5080ba4f40f70bcb576ee8 to your computer and use it in GitHub Desktop.
Save bullheadandplato/bc61cdce8c5080ba4f40f70bcb576ee8 to your computer and use it in GitHub Desktop.
love you!!! KS
package com.madhatters.novappback.data;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.index.Indexed;
import org.springframework.data.mongodb.core.mapping.Document;
import java.io.Serializable;
@Document(collection = "categories")
public class Category implements Serializable, Cloneable {
@Id
private String id;
@Indexed
private String name;
public Category() {
}
public Category(String name) {
this.name = name;
}
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment