sk.stuba.fiit.foo07.genex.dao
Class KeywordDaoDerby

java.lang.Object
  extended by sk.stuba.fiit.foo07.genex.dao.BasicDao
      extended by sk.stuba.fiit.foo07.genex.dao.KeywordDaoDerby
All Implemented Interfaces:
KeywordDao

public class KeywordDaoDerby
extends BasicDao
implements KeywordDao


Field Summary
 
Fields inherited from class sk.stuba.fiit.foo07.genex.dao.BasicDao
con
 
Constructor Summary
KeywordDaoDerby()
           
KeywordDaoDerby(java.sql.Connection con)
           
 
Method Summary
 void addKeyword(java.lang.Integer questionID, Keyword toAdd)
           
 void addKeywords(java.lang.Integer questionID, java.util.ArrayList<Keyword> toAdd)
           
 void deleteAllKeywordsFromQuestion(java.lang.Integer questionID)
           
 void deleteKeyword(Keyword toDelete)
           
 void deleteKeywords(java.util.ArrayList<Keyword> toDelete)
           
 java.util.ArrayList<Keyword> getAllKeywords()
           
 Keyword getKeywordByID(java.lang.Integer keywordID)
           
 java.util.ArrayList<Keyword> getKeywordsByQuestionID(java.lang.Integer questionID)
           
 void updateKeyword(Keyword toUpdate)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeywordDaoDerby

public KeywordDaoDerby()
                throws java.lang.Exception
Throws:
java.lang.Exception

KeywordDaoDerby

public KeywordDaoDerby(java.sql.Connection con)
                throws java.sql.SQLException
Throws:
java.sql.SQLException
Method Detail

addKeyword

public void addKeyword(java.lang.Integer questionID,
                       Keyword toAdd)
                throws java.sql.SQLException
Specified by:
addKeyword in interface KeywordDao
Throws:
java.sql.SQLException

addKeywords

public void addKeywords(java.lang.Integer questionID,
                        java.util.ArrayList<Keyword> toAdd)
                 throws java.sql.SQLException
Specified by:
addKeywords in interface KeywordDao
Throws:
java.sql.SQLException

deleteKeyword

public void deleteKeyword(Keyword toDelete)
                   throws java.sql.SQLException
Specified by:
deleteKeyword in interface KeywordDao
Throws:
java.sql.SQLException

deleteAllKeywordsFromQuestion

public void deleteAllKeywordsFromQuestion(java.lang.Integer questionID)
                                   throws java.sql.SQLException
Specified by:
deleteAllKeywordsFromQuestion in interface KeywordDao
Throws:
java.sql.SQLException

deleteKeywords

public void deleteKeywords(java.util.ArrayList<Keyword> toDelete)
                    throws java.sql.SQLException
Specified by:
deleteKeywords in interface KeywordDao
Throws:
java.sql.SQLException

getKeywordByID

public Keyword getKeywordByID(java.lang.Integer keywordID)
                       throws java.sql.SQLException
Specified by:
getKeywordByID in interface KeywordDao
Throws:
java.sql.SQLException

getAllKeywords

public java.util.ArrayList<Keyword> getAllKeywords()
                                            throws java.sql.SQLException
Specified by:
getAllKeywords in interface KeywordDao
Throws:
java.sql.SQLException

getKeywordsByQuestionID

public java.util.ArrayList<Keyword> getKeywordsByQuestionID(java.lang.Integer questionID)
                                                     throws java.sql.SQLException
Specified by:
getKeywordsByQuestionID in interface KeywordDao
Throws:
java.sql.SQLException

updateKeyword

public void updateKeyword(Keyword toUpdate)
                   throws java.sql.SQLException
Specified by:
updateKeyword in interface KeywordDao
Throws:
java.sql.SQLException


Copyright © 2008 Faculty of Informatics and Information Technologies, STU Bratislava. All Rights Reserved.