001    /* PAVLOV -- Multiple Choice Study System
002     * Copyright (C) 2000 - 2004 T.J. Willis
003     * 
004     * This program is free software; you can redistribute it and/or
005     * modify it under the terms of the GNU General Public License
006     * as published by the Free Software Foundation; either version 2
007     * of the License, or (at your option) any later version.
008     *      
009     * This program is distributed in the hope that it will be useful,
010     * but WITHOUT ANY WARRANTY; without even the implied warranty of
011     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
012     * GNU General Public License for more details.
013     *          
014     * You should have received a copy of the GNU General Public License
015     * along with this program; if not, write to the Free Software
016     * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
017     *  
018     * $Header: /cvsroot/pavlov/net/sourceforge/pavlov/library/AnswerAtom.java,v 1.1 2004/05/10 14:55:14 tj_willis Exp $
019     */ 
020    package net.sourceforge.pavlov.library;
021    
022    import java.util.*;
023    import javax.swing.tree.DefaultMutableTreeNode;
024    import java.io.*;
025    import java.net.URLEncoder;
026    import org.apache.log4j.*;
027    /**
028     * One of a set of possible answers to a question.
029     *
030     * @author <a href="mailto:tj_willis@users.sourceforge.net"></a>
031     */
032    public class AnswerAtom
033    {
034        protected boolean correct;
035        protected Object content;
036    
037        public AnswerAtom(boolean isCorrect, Object answer)
038        {
039            correct = isCorrect;
040            content = answer;
041        }
042    
043        /**
044         * Get the Correct value.
045         * @return the Correct value.
046         */
047        public boolean isCorrect() {
048            return correct;
049        }
050    
051        /**
052         * Set the Correct value.
053         * @param newCorrect The new Correct value.
054         */
055        public void setCorrect(boolean newCorrect) {
056            this.correct = newCorrect;
057        }
058    
059        
060        /**
061         * Get the Content value.
062         * @return the Content value.
063         */
064        public Object getContent() {
065            return content;
066        }
067    
068        /**
069         * Set the Content value.
070         * @param newContent The new Content value.
071         */
072        public void setContent(Object newContent) {
073            this.content = newContent;
074        }
075    
076        
077    }
078    
079    
080    
081    
082