org.wso2.registry.jdbc.dao
Class RatingsDAO

java.lang.Object
  extended by org.wso2.registry.jdbc.dao.RatingsDAO

public class RatingsDAO
extends java.lang.Object


Constructor Summary
RatingsDAO()
           
 
Method Summary
 void addRating(long artifactID, java.lang.String userID, int rating, java.sql.Connection conn)
           
 float getAverageRating(java.lang.String path, java.sql.Connection conn)
           
 java.util.Date getRatedTime(java.lang.String path, java.lang.String userName, java.sql.Connection conn)
           
 java.lang.String[] getRatedUserNames(java.lang.String resourcePath, java.sql.Connection conn)
           
 RatingDO getRating(long ratingID, java.sql.Connection conn)
           
 int getRating(java.lang.String path, java.lang.String userName, java.sql.Connection conn)
           
 boolean ratingExist(long artifactID, java.lang.String userID, java.sql.Connection conn)
           
 void removeRatings(long artifactID, java.sql.Connection conn)
           
 void updateRating(long artifactID, java.lang.String userID, int rating, java.sql.Connection conn)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RatingsDAO

public RatingsDAO()
Method Detail

addRating

public void addRating(long artifactID,
                      java.lang.String userID,
                      int rating,
                      java.sql.Connection conn)
               throws java.sql.SQLException
Throws:
java.sql.SQLException

updateRating

public void updateRating(long artifactID,
                         java.lang.String userID,
                         int rating,
                         java.sql.Connection conn)
                  throws java.sql.SQLException
Throws:
java.sql.SQLException

ratingExist

public boolean ratingExist(long artifactID,
                           java.lang.String userID,
                           java.sql.Connection conn)
                    throws java.sql.SQLException
Throws:
java.sql.SQLException

getAverageRating

public float getAverageRating(java.lang.String path,
                              java.sql.Connection conn)
                       throws java.sql.SQLException
Throws:
java.sql.SQLException

getRating

public int getRating(java.lang.String path,
                     java.lang.String userName,
                     java.sql.Connection conn)
              throws java.sql.SQLException
Throws:
java.sql.SQLException

getRatedTime

public java.util.Date getRatedTime(java.lang.String path,
                                   java.lang.String userName,
                                   java.sql.Connection conn)
                            throws java.sql.SQLException
Throws:
java.sql.SQLException

removeRatings

public void removeRatings(long artifactID,
                          java.sql.Connection conn)
                   throws java.sql.SQLException
Throws:
java.sql.SQLException

getRatedUserNames

public java.lang.String[] getRatedUserNames(java.lang.String resourcePath,
                                            java.sql.Connection conn)
                                     throws java.sql.SQLException
Throws:
java.sql.SQLException

getRating

public RatingDO getRating(long ratingID,
                          java.sql.Connection conn)
                   throws java.sql.SQLException
Throws:
java.sql.SQLException


Copyright © 2007 Apache Web Services Project. All Rights Reserved.