001: /*
002: * Copyright (c) 2001 - 2005 ivata limited.
003: * All rights reserved.
004: * -----------------------------------------------------------------------------
005: * ivata groupware may be redistributed under the GNU General Public
006: * License as published by the Free Software Foundation;
007: * version 2 of the License.
008: *
009: * These programs are free software; you can redistribute them and/or
010: * modify them under the terms of the GNU General Public License
011: * as published by the Free Software Foundation; version 2 of the License.
012: *
013: * These programs are distributed in the hope that they will be useful,
014: * but WITHOUT ANY WARRANTY; without even the implied warranty of
015: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
016: *
017: * See the GNU General Public License in the file LICENSE.txt for more
018: * details.
019: *
020: * If you would like a copy of the GNU General Public License write to
021: *
022: * Free Software Foundation, Inc.
023: * 59 Temple Place - Suite 330
024: * Boston, MA 02111-1307, USA.
025: *
026: *
027: * To arrange commercial support and licensing, contact ivata at
028: * http://www.ivata.com/contact.jsp
029: * -----------------------------------------------------------------------------
030: * $Log: FAQDO.java,v $
031: * Revision 1.1 2005/04/26 15:21:53 colinmacleod
032: * Renamed Faq to FAQ.
033: *
034: * Revision 1.3 2005/04/10 20:09:44 colinmacleod
035: * Added new themes.
036: * Changed id type to String.
037: * Changed i tag to em and b tag to strong.
038: * Improved PicoContainerFactory with NanoContainer scripts.
039: *
040: * Revision 1.2 2005/04/09 17:19:45 colinmacleod
041: * Changed copyright text to GPL v2 explicitly.
042: *
043: * Revision 1.1.1.1 2005/03/10 17:51:59 colinmacleod
044: * Restructured ivata op around Hibernate/PicoContainer.
045: * Renamed ivata groupware.
046: *
047: * Revision 1.1 2004/07/13 19:47:28 colinmacleod
048: * Moved project to POJOs from EJBs.
049: * Applied PicoContainer to services layer (replacing session EJBs).
050: * Applied Hibernate to persistence layer (replacing entity EJBs).
051: *
052: * Revision 1.2 2004/03/21 21:16:29 colinmacleod
053: * Shortened name to ivata op.
054: *
055: * Revision 1.1.1.1 2004/01/27 20:58:38 colinmacleod
056: * Moved ivata openportal to SourceForge..
057: *
058: * Revision 1.5 2003/11/03 11:29:44 jano
059: * commiting library,
060: * tryinjg to fix deploying problem
061: *
062: * Revision 1.4 2003/10/28 13:16:14 jano
063: * commiting library,
064: * still fixing compile and building openGroupware project
065: *
066: * Revision 1.3 2003/10/15 14:23:29 jano
067: * converting to XDoclet
068: *
069: * Revision 1.2 2003/10/15 14:16:53 colin
070: * fixing for XDoclet
071: *
072: * Revision 1.4 2003/05/01 12:13:22 jano
073: * tidy up names of sequeneces
074: *
075: * Revision 1.3 2003/02/28 07:29:23 colin
076: * fixed code for creation
077: * added id dispenser
078: * moved CMRs to post create
079: *
080: * Revision 1.2 2003/02/25 14:38:13 colin
081: * implemented setModified methods on entity beans thro IvataEntityBean superclass
082: *
083: * Revision 1.1 2003/02/24 19:09:22 colin
084: * moved to business
085: * -----------------------------------------------------------------------------
086: */
087: package com.ivata.groupware.business.library.faq;
088:
089: import com.ivata.groupware.business.library.faq.category.FAQCategoryDO;
090: import com.ivata.groupware.container.persistence.BaseDO;
091:
092: /**
093: * <p>Represents a single question/answer pair as stored in frequently asked
094: * question library items.</p>
095: *
096: * @hibernate.class
097: * table="library_faq"
098: */
099: public class FAQDO extends BaseDO {
100:
101: /**
102: * <p>The answer to the question.</p>
103: */
104: private String answer;
105:
106: /**
107: * <p>The category which contains this question/answer.</p>
108: */
109: private FAQCategoryDO fAQCategory;
110: /**
111: * <p>The question.</p>
112: */
113: private String question;
114:
115: /**
116: * <p>Get the answer to the question.</p>
117: *
118: * @return the answer to the question.
119: * @hibernate.property
120: */
121: public final String getAnswer() {
122: return answer;
123: }
124:
125: /**
126: * <p>Get the category which contains this question/answer.</p>
127: *
128: * @return the category which contains this question/answer.
129: * @hibernate.many-to-one
130: * column="library_faq_category"
131: */
132: public final FAQCategoryDO getFAQCategory() {
133: return fAQCategory;
134: }
135:
136: /**
137: * <p>Get the question.</p>
138: *
139: * @return the question being asked.
140: * @hibernate.property
141: */
142: public final String getQuestion() {
143: return question;
144: }
145:
146: /**
147: * <p>Set the answer to the question.</p>
148: *
149: * @param answer the answer to the question.
150: */
151: public final void setAnswer(final String answer) {
152: this .answer = answer;
153: }
154:
155: /**
156: * <p>Set the category which contains this question/answer.</p>
157: *
158: * @param faqCategory the category which contains this question/answer.
159: */
160: public final void setFAQCategory(final FAQCategoryDO faqCategory) {
161: this .fAQCategory = faqCategory;
162: }
163:
164: /**
165: * <p>Set the question.</p>
166: *
167: * @param question the question being asked.
168: */
169: public final void setQuestion(final String question) {
170: this.question = question;
171: }
172: }
|