/* * 2012-3 Red Hat Inc. and/or its affiliates and other contributors. * * 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.overlord.gadgets.server.model; import java.io.Serializable; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.Id; import javax.persistence.Table; /** * @author: Jeff Yu * @date: 12/04/12 */ @Entity @Table(name="GS_GADGET") public class Gadget implements Serializable{ private static final long serialVersionUID = -3288676630965488450L; @Id @GeneratedValue @Column(name="GAGET_ID") private long id; @Column(name="GADGET_TITLE") private String title; @Column(name="GADGET_TITLE_URL") private String titleUrl; @Column(name="GADGET_AUTHOR") private String author; @Column(name="GADGET_AUTHOR_EMAIL") private String authorEmail; @Column(name="GADGET_DESCRIPTION") private String description; @Column(name="GADGET_URL") private String url; @Column(name="GADGET_THUMBNAIL_URL") private String thumbnailUrl; @Column(name="GADGET_SCREENSHOT_URL") private String screenshotUrl; @Column(name="GADGET_TYPE") private String type; @Column(name="GADGET_GROUP") private Group group; 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 getTitleUrl() { return titleUrl; } public void setTitleUrl(String titleUrl) { this.titleUrl = titleUrl; } public String getAuthor() { return author; } public void setAuthor(String author) { this.author = author; } public String getAuthorEmail() { return authorEmail; } public void setAuthorEmail(String authorEmail) { this.authorEmail = authorEmail; } public String getDescription() { return description; } public void setDescription(String description) { this.description = description; } public String getUrl() { return url; } public void setUrl(String url) { this.url = url; } public String getThumbnailUrl() { return thumbnailUrl; } public void setThumbnailUrl(String thumbnailUrl) { this.thumbnailUrl = thumbnailUrl; } public String getScreenshotUrl() { return screenshotUrl; } public void setScreenshotUrl(String screenshotUrl) { this.screenshotUrl = screenshotUrl; } public String getType() { return type; } public void setType(String type) { this.type = type; } /** * @return the group */ public Group getGroup() { return group; } /** * @param group the group to set */ public void setGroup(Group group) { this.group = group; } }