fixed broken interfsce by mistake, added getAllLikesByFeed back
This commit is contained in:
parent
60abff8772
commit
6bb93b7de2
|
@ -2440,11 +2440,19 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
|
|||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Deprecated
|
||||
@Override
|
||||
public List<Like> getAllLikesByPost(String feedid) {
|
||||
public List<Like> getAllLikesByFeed(String feedid) {
|
||||
return getAllLikesByPost(feedid);
|
||||
}
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public List<Like> getAllLikesByPost(String postid) {
|
||||
List<Like> toReturn = new ArrayList<Like>();
|
||||
OperationResult<Rows<String, String>> result;
|
||||
PreparedIndexExpression<String, String> clause = cf_Likes.newIndexClause().whereColumn("Feedid").equals().value(feedid);
|
||||
PreparedIndexExpression<String, String> clause = cf_Likes.newIndexClause().whereColumn("Feedid").equals().value(postid);
|
||||
try {
|
||||
result = conn.getKeyspace().prepareQuery(cf_Likes)
|
||||
.searchWithIndex()
|
||||
|
@ -2467,7 +2475,7 @@ public final class DBCassandraAstyanaxImpl implements DatabookStore {
|
|||
else if (col.getName().compareTo("Feedid") == 0)
|
||||
toAdd.setFeedid(col.getStringValue());
|
||||
else {
|
||||
_log.error("getAllLikesByFeed(): Could not assign variable to this Like for column name: " + col.getName());
|
||||
_log.error("getAllLikesByPost(): Could not assign variable to this Like for column name: " + col.getName());
|
||||
}
|
||||
}
|
||||
toReturn.add(toAdd);
|
||||
|
|
|
@ -532,6 +532,12 @@ public interface DatabookStore {
|
|||
* @return the likes made to feeds in the range from: today to: timeInMillis
|
||||
*/
|
||||
List<Post> getRecentLikedPostsByUserAndDate(String userid, long timeInMillis) throws IllegalArgumentException;
|
||||
/**
|
||||
* @deprecated use getAllLikesByPost
|
||||
* @param postid postid identifier
|
||||
* return all the likes belonging to the postid
|
||||
*/
|
||||
List<Like> getAllLikesByFeed(String postid);
|
||||
/**
|
||||
* @param postid postid identifier
|
||||
* return all the likes belonging to the postid
|
||||
|
|
Loading…
Reference in New Issue