PageRenderTime 203ms CodeModel.GetById 121ms app.highlight 5ms RepoModel.GetById 75ms app.codeStats 0ms

/src/main/java/com/google/ie/business/domain/IdeaComment.java

http://thoughtsite.googlecode.com/
Java | 112 lines | 48 code | 20 blank | 44 comment | 0 complexity | d79447ea5bda944b44f46d86f82fbb39 MD5 | raw file
  1/* Copyright 2010 Google Inc.
  2 * 
  3 * Licensed under the Apache License, Version 2.0 (the "License");
  4 * you may not use this file except in compliance with the License.
  5 * You may obtain a copy of the License at
  6 * 
  7 *      http://www.apache.org/licenses/LICENSE-2.0
  8 * 
  9 * Unless required by applicable law or agreed to in writing, software
 10 * distributed under the License is distributed on an "AS IS" BASIS.
 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 12 * See the License for the specific language governing permissions and
 13 * limitations under the License
 14 */
 15
 16package com.google.ie.business.domain;
 17
 18import org.compass.annotations.Searchable;
 19import org.compass.annotations.SearchableProperty;
 20
 21import java.io.Serializable;
 22
 23import javax.jdo.annotations.IdentityType;
 24import javax.jdo.annotations.PersistenceCapable;
 25import javax.jdo.annotations.Persistent;
 26
 27/**
 28 * 
 29 * @author asirohi
 30 * 
 31 */
 32@PersistenceCapable(identityType = IdentityType.APPLICATION, detachable = "true")
 33@Searchable(alias = "IdeaComment")
 34public class IdeaComment extends Comment implements Serializable {
 35    public static final String STATUS_SAVED = "Saved";
 36    /** A unique identifier for the class */
 37    private static final long serialVersionUID = 8728151976934031986L;
 38
 39    @Persistent
 40    private long totalNegativeVotes;
 41
 42    @Persistent
 43    private long totalVotes;
 44
 45    @Persistent
 46    private long totalPositiveVotes;
 47
 48    @Persistent
 49    @SearchableProperty
 50    private String ideaKey;
 51
 52    public IdeaComment() {
 53
 54    }
 55
 56    /**
 57     * @return the totalNegativeVotes
 58     */
 59    public long getTotalNegativeVotes() {
 60        return totalNegativeVotes;
 61    }
 62
 63    /**
 64     * @param totalNegativeVotes the totalNegativeVotes to set
 65     */
 66    public void setTotalNegativeVotes(long totalNegativeVotes) {
 67        this.totalNegativeVotes = totalNegativeVotes;
 68    }
 69
 70    /**
 71     * @return the totalPositiveVotes
 72     */
 73    public long getTotalPositiveVotes() {
 74        return totalPositiveVotes;
 75    }
 76
 77    /**
 78     * @param totalPositiveVotes the totalPositiveVotes to set
 79     */
 80    public void setTotalPositiveVotes(long totalPositiveVotes) {
 81        this.totalPositiveVotes = totalPositiveVotes;
 82    }
 83
 84    /**
 85     * @param totalVotes the totalVotes to set
 86     */
 87    public void setTotalVotes(long totalVotes) {
 88        this.totalVotes = totalVotes;
 89    }
 90
 91    /**
 92     * @return the totalVotes
 93     */
 94    public long getTotalVotes() {
 95        return totalVotes;
 96    }
 97
 98    /**
 99     * @return the ideaKey
100     */
101    public String getIdeaKey() {
102        return ideaKey;
103    }
104
105    /**
106     * @param ideaKey the ideaKey to set
107     */
108    public void setIdeaKey(String ideaKey) {
109        this.ideaKey = ideaKey;
110    }
111}
112