You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@roller.apache.org by cl...@apache.org on 2006/09/07 23:48:41 UTC
svn commit: r441245 - in
/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business:
datamapper/ jdo/
Author: clr
Date: Thu Sep 7 14:48:40 2006
New Revision: 441245
URL: http://svn.apache.org/viewvc?view=rev&rev=441245
Log:
Datamapper updates
Modified:
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperPlanetManagerImpl.java
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperQuery.java
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperReferrerManagerImpl.java
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRemoveQuery.java
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRollerImpl.java
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperUserManagerImpl.java
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperWeblogManagerImpl.java
incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/jdo/JDOPersistenceStrategy.java
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperPlanetManagerImpl.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperPlanetManagerImpl.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperPlanetManagerImpl.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperPlanetManagerImpl.java Thu Sep 7 14:48:40 2006
@@ -43,6 +43,7 @@
import org.apache.roller.pojos.PlanetSubscriptionData;
import org.apache.roller.pojos.WeblogEntryData;
import org.apache.roller.pojos.WebsiteData;
+import org.apache.roller.pojos.UserData;
import com.sun.syndication.fetcher.FeedFetcher;
import com.sun.syndication.fetcher.impl.FeedFetcherCache;
@@ -271,11 +272,16 @@
|| siteUpdated.after(sub.getLastUpdated())) {
int entryCount = RollerRuntimeConfig
.getIntProperty("site.newsfeeds.defaultEntries");
- entries = blogmgr.getWeblogEntries(website, null, // startDate
+ entries = blogmgr.getWeblogEntries(website,
+ null, //user,
+ null, // startDate
new Date(), // endDate
null, // catName
WeblogEntryData.PUBLISHED, // status
- new Integer(entryCount)); // maxEntries
+ null, // sortBy
+ null, // locale
+ 0, // offset
+ entryCount); // maxEntries
sub.setLastUpdated(siteUpdated);
saveSubscription(sub);
@@ -295,7 +301,8 @@
catch (Exception e) {
logger.warn("Problem reading local feed", e);
}
- return getNewEntriesRemote(sub, feedFetcher, feedInfoCache);
+ //return getNewEntriesRemote(sub, feedFetcher, feedInfoCache);
+ return null;
}
public void refreshEntries() throws RollerException {
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperQuery.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperQuery.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperQuery.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperQuery.java Thu Sep 7 14:48:40 2006
@@ -41,20 +41,20 @@
Object execute(Object[] params);
/** Set the result to be a single instance (not a List).
- * @result the instance on which this method is called
+ * @return the instance on which this method is called
*/
DatamapperQuery setUnique();
/** Set the types of the parameters. This is only needed if the
* parameter types are temporal types, e.g. Date, Time, Calendar.
- * @param the types of the parameters in corresponding positions.
- * @result the instance on which this method is called
+ * @param types types of the parameters in corresponding positions.
+ * @return the instance on which this method is called
*/
DatamapperQuery setTypes(Object[] types);
/** Set the range of results for this query.
- * @fromIncl the beginning row number
- * @toExcl the ending row number
+ * @param fromIncl the beginning row number
+ * @param toExcl the ending row number
* @return the instance on which this method is called
*/
DatamapperQuery setRange(long fromIncl, long toExcl);
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperReferrerManagerImpl.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperReferrerManagerImpl.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperReferrerManagerImpl.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperReferrerManagerImpl.java Thu Sep 7 14:48:40 2006
@@ -39,54 +39,146 @@
this.strategy = strategy;
}
+ /**
+ * Store the referer.
+ */
public void saveReferer(RefererData referer) throws RollerException {
- strategy.store(referer);
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Remove a single referer.
+ */
public void removeReferer(RefererData referer) throws RollerException {
- strategy.remove(referer);
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Clear referrer dayhits and remove referrers without excerpts.
+ */
public void clearReferrers() throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Clear referrer dayhits and remove referrers without excerpts.
+ */
public void clearReferrers(WebsiteData website) throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Retrieve referer by id.
+ */
public RefererData getReferer(String id) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Get all referers for specified weblog.
+ * @param weblog
+ * @return List of type RefererData
+ */
public List getReferers(WebsiteData weblog) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Get all referers for specified user that were made today.
+ * @param userName Name of user.
+ * @return List of type RefererData
+ */
public List getTodaysReferers(WebsiteData website) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
- public List getReferersToDate(WebsiteData website, String date) throws RollerException {
- }
-
- public List getDaysPopularWebsites(int max) throws RollerException {
- }
-
+ /**
+ * Get referers for a specified date.
+ * @param userName Name of user.
+ * @param date YYYYMMDD format of day's date.
+ * @return List of type RefererData.
+ * @throws org.apache.roller.RollerException
+ */
+ public List getReferersToDate(WebsiteData website, String date)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get most popular websites based on referer day hits.
+ * @param offset Offset into results (for paging)
+ * @param len Maximum number of results to return (for paging)
+ * @return List of WebsiteDisplayData objects.
+ */
+ public List getDaysPopularWebsites(int offset, int length)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Returns hot weblogs as StatCount objects, in descending order by today's
+ * hits.
+ * @param sinceDays Restrict to last X days (or -1 for all)
+ * @param offset Offset into results (for paging)
+ * @param len Maximum number of results to return (for paging)
+ * @return List of StatCount objects.
+ */
+ public List getHotWeblogs(int sinceDays, int offset, int length)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get referers that refer to a specific weblog entry.
+ * @param entryid Weblog entry ID
+ * @return List of RefererData objects.
+ * @throws org.apache.roller.RollerException
+ */
public List getReferersToEntry(String entryid) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Get user's day hits
+ */
public int getDayHits(WebsiteData website) throws RollerException {
+ return 0; //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Get user's all-time total hits
+ */
public int getTotalHits(WebsiteData website) throws RollerException {
+ return 0; //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Apply ignoreWord/spam filters to all referers in system.
+ */
public void applyRefererFilters() throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
- public void applyRefererFilters(WebsiteData website) throws RollerException {
+ /**
+ * Apply ignoreWord/spam filters to all referers in website.
+ */
+ public void applyRefererFilters(WebsiteData website)
+ throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
- public void processReferrer(String requestUrl, String referrerUrl, String weblogHandle, String weblogAnchor, String weblogDateString) {
+ /**
+ * Process an incoming referer.
+ */
+ public void processReferrer(String requestUrl, String referrerUrl,
+ String weblogHandle, String weblogAnchor, String weblogDateString) {
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Release all resources held by manager.
+ */
public void release() {
+ //To change body of implemented methods use File | Settings | File Templates.
}
-
}
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRemoveQuery.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRemoveQuery.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRemoveQuery.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRemoveQuery.java Thu Sep 7 14:48:40 2006
@@ -23,32 +23,30 @@
*/
public interface DatamapperRemoveQuery {
- /** Remove instances selected by the query with no parameters.
- * @return the results of the query
+ /**
+ * Remove instances selected by the query with no parameters.
*/
void removeAll();
/** Remove instances selected by the query with one parameter.
* @param param the parameter
- * @return the results of the query
*/
void removeAll(Object param);
/** Remove instances selected by the query with parameters.
* @param params the parameters
- * @return the results of the query
*/
void removeAll(Object[] params);
/** Set the result to be a single instance (not a List).
- * @result the instance on which this method is called
+ * @return the instance on which this method is called
*/
DatamapperRemoveQuery setUnique();
/** Set the types of the parameters. This is only needed if the
* parameter types are temporal types, e.g. Date, Time, Calendar.
- * @param the types of the parameters in corresponding positions.
- * @result the instance on which this method is called
+ * @param types types of the parameters in corresponding positions.
+ * @return the instance on which this method is called
*/
DatamapperRemoveQuery setTypes(Object[] types);
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRollerImpl.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRollerImpl.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRollerImpl.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperRollerImpl.java Thu Sep 7 14:48:40 2006
@@ -98,7 +98,7 @@
/**
- * @see org.apache.roller.model.Roller#getAutoPingManager()
+ * @see org.apache.roller.model.Roller#getAutopingManager()
*/
public AutoPingManager getAutopingManager() throws RollerException {
if (autoPingManager == null) {
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperUserManagerImpl.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperUserManagerImpl.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperUserManagerImpl.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperUserManagerImpl.java Thu Sep 7 14:48:40 2006
@@ -20,6 +20,8 @@
import java.util.Date;
import java.util.Iterator;
import java.util.List;
+import java.util.Map;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.roller.RollerException;
@@ -78,6 +80,95 @@
return (UserData)strategy.load(UserData.class, id);
}
+ /**
+ * Get user object by user name (only enabled users)
+ */
+ public UserData getUserByUserName(String userName) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get user object by user name, optionally include dis-enabled users
+ */
+ public UserData getUserByUserName(String userName, Boolean enabled)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get all enabled users
+ */
+ public List getUsers(int offset, int length) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get all users, optionally include dis-enabled users.
+ * @param enabled True for enabled only, false for disabled only, null for
+ * all
+ * @param startDate Restrict to those created after (or null for all)
+ * @param endDate Restrict to those created before (or null for all)
+ */
+ public List getUsers(Boolean enabled, Date startDate, Date endDate,
+ int offset, int length) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get all users or a website.
+ * @param website Get all users of this website (or null for all)
+ * @returns List of UserData objects.
+ */
+ public List getUsers(WebsiteData website, Boolean enabled, int offset,
+ int length) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Returns users whose usernames or email addresses start with a string.
+ * @param startsWith String to match userNames and emailAddresses against
+ * @param offset Offset into results (for paging)
+ * @param length Max to return (for paging)
+ * @param enabled True for only enalbed, false for disabled, null for all
+ * @return List of (up to length) users that match startsWith string
+ */
+ public List getUsersStartingWith(String startsWith, Boolean enabled,
+ int offset, int length) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get map with 26 entries, one for each letter A-Z and containing integers
+ * reflecting the number of users whose names start with each letter.
+ */
+ public Map getUserNameLetterMap() throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get collection of users whose names begin with specified letter
+ */
+ public List getUsersByLetter(char letter, int offset, int length)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get map with 26 entries, one for each letter A-Z and containing integers
+ * reflecting the number of weblogs whose names start with each letter.
+ */
+ public Map getWeblogHandleLetterMap() throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get collection of weblogs whose handles begin with specified letter
+ */
+ public List getWeblogsByLetter(char letter, int offset, int length)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
public UserData getUserByUsername(String userName)
throws RollerException {
return getUserByUsername(userName, Boolean.TRUE);
@@ -326,7 +417,7 @@
* @param endDate Restrict to those created before (or null for all)
* @param offset Offset into results (for paging)
* @param len Maximum number of results to return (for paging)
- * @returns List of WebsiteData objects.
+ * @return List of WebsiteData objects.
*/
public List getMostCommentedWebsites(
Date startDate,
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperWeblogManagerImpl.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperWeblogManagerImpl.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperWeblogManagerImpl.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/datamapper/DatamapperWeblogManagerImpl.java Thu Sep 7 14:48:40 2006
@@ -26,6 +26,7 @@
import org.apache.roller.pojos.WeblogCategoryData;
import org.apache.roller.pojos.WeblogEntryData;
import org.apache.roller.pojos.WebsiteData;
+import org.apache.roller.pojos.UserData;
/*
* DatamapperWeblogManagerImpl.java
@@ -34,132 +35,417 @@
*
*/
public class DatamapperWeblogManagerImpl implements WeblogManager {
-
- /** Creates a new instance of DatamapperWeblogManagerImpl */
- public DatamapperWeblogManagerImpl() {
- }
-
- public void saveWeblogEntry(WeblogEntryData entry) throws RollerException {
- }
-
- public void removeWeblogEntry(WeblogEntryData entry) throws RollerException {
- }
-
- public WeblogEntryData getWeblogEntry(String id) throws RollerException {
- }
-
- public WeblogEntryData getWeblogEntryByAnchor(WebsiteData website, String anchor) throws RollerException {
- }
-
- public List getWeblogEntries(WebsiteData website, Date startDate, Date endDate, String catName, String status, String sortBy, int offset, int range) throws RollerException {
- }
-
- public List getWeblogEntries(WebsiteData website, Date startDate, Date endDate, String catName, String status, String sortBy, Integer maxEntries) throws RollerException {
- }
-
- public Map getWeblogEntryObjectMap(WebsiteData website, Date startDate, Date endDate, String catName, String status, Integer maxEntries) throws RollerException {
- }
-
- public Map getWeblogEntryStringMap(WebsiteData website, Date startDate, Date endDate, String catName, String status, Integer maxEntries) throws RollerException {
- }
-
- public List getWeblogEntries(WeblogCategoryData cat, boolean subcats) throws RollerException {
- }
-
- public WeblogEntryData getNextEntry(WeblogEntryData current, String catName) throws RollerException {
- }
-
- public WeblogEntryData getPreviousEntry(WeblogEntryData current, String catName) throws RollerException {
- }
- public List getNextEntries(WeblogEntryData entry, String catName, int maxEntries) throws RollerException {
- }
-
- public List getPreviousEntries(WeblogEntryData entry, String catName, int maxEntries) throws RollerException {
- }
-
- public List getWeblogEntriesPinnedToMain(Integer max) throws RollerException {
- }
-
- public Date getWeblogLastPublishTime(WebsiteData website) throws RollerException {
- }
-
- public Date getWeblogLastPublishTime(WebsiteData website, String catName) throws RollerException {
- }
-
- public void saveWeblogCategory(WeblogCategoryData cat) throws RollerException {
- }
-
- public void moveWeblogCategoryContents(String srcId, String destId) throws RollerException {
- }
+ private DatamapperPersistenceStrategy strategy;
- public void removeWeblogCategory(WeblogCategoryData cat) throws RollerException {
+ public DatamapperWeblogManagerImpl
+ (DatamapperPersistenceStrategy strategy) {
+ this.strategy = strategy;
}
- public WeblogCategoryData getWeblogCategory(String id) throws RollerException {
- }
-
- public WeblogCategoryData getRootWeblogCategory(WebsiteData website) throws RollerException {
- }
-
- public WeblogCategoryData getWeblogCategoryByPath(WebsiteData website, String categoryPath) throws RollerException {
- }
-
- public WeblogCategoryData getWeblogCategoryByPath(WebsiteData wd, WeblogCategoryData category, String string) throws RollerException {
+ /**
+ * Save weblog entry.
+ */
+ public void saveWeblogEntry(WeblogEntryData entry) throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
- public List getWeblogCategories(WebsiteData website) throws RollerException {
+ /**
+ * Remove weblog entry.
+ */
+ public void removeWeblogEntry(WeblogEntryData entry)
+ throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
- public List getWeblogCategories(WebsiteData website, boolean includeRoot) throws RollerException {
+ /**
+ * Get weblog entry by id.
+ */
+ public WeblogEntryData getWeblogEntry(String id) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Get weblog entry by anchor.
+ */
+ public WeblogEntryData getWeblogEntryByAnchor(WebsiteData website,
+ String anchor) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get WeblogEntries by offset/length as list in reverse chronological
+ * order. The range offset and list arguments enable paging through query
+ * results.
+ * @param website Weblog or null to get for all weblogs.
+ * @param user User or null to get for all users.
+ * @param startDate Start date or null for no start date.
+ * @param endDate End date or null for no end date.
+ * @param catName Category path or null for all categories.
+ * @param status Status of DRAFT, PENDING, PUBLISHED or null for all
+ * @param sortBy Sort by either 'pubTime' or 'updateTime' (null for
+ * pubTime)
+ * @param offset Offset into results for paging
+ * @param range Max comments to return (or -1 for no limit)
+ * @return List of WeblogEntryData objects in reverse chrono order.
+ * @throws org.apache.roller.RollerException
+ */
+ public List getWeblogEntries(WebsiteData website, UserData user,
+ Date startDate, Date endDate, String catName,
+ String status, String sortBy, String locale,
+ int offset, int range) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get Weblog Entries grouped by day. This method returns a Map that
+ * contains Lists, each List contains WeblogEntryData objects, and the Lists
+ * are keyed by Date objects.
+ * @param website Weblog or null to get for all weblogs.
+ * @param startDate Start date or null for no start date.
+ * @param endDate End date or null for no end date.
+ * @param catName Category path or null for all categories.
+ * @param status Status of DRAFT, PENDING, PUBLISHED or null for all
+ * @param offset Offset into results for paging
+ * @param range Max comments to return (or -1 for no limit)
+ * @return Map of Lists, keyed by Date, and containing WeblogEntryData.
+ * @throws org.apache.roller.RollerException
+ */
+ public Map getWeblogEntryObjectMap(WebsiteData website,
+ Date startDate, Date endDate, String catName,
+ String status, String locale, int offset,
+ int range) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get Weblog Entry date strings grouped by day. This method returns a Map
+ * that contains Lists, each List contains YYYYMMDD date strings objects,
+ * and the Lists are keyed by Date objects.
+ * @param website Weblog or null to get for all weblogs.
+ * @param startDate Start date or null for no start date.
+ * @param endDate End date or null for no end date.
+ * @param catName Category path or null for all categories.
+ * @param status Status of DRAFT, PENDING, PUBLISHED or null for all
+ * @param offset Offset into results for paging
+ * @param range Max comments to return (or -1 for no limit)
+ * @return Map of Lists, keyed by Date, and containing date strings.
+ * @throws org.apache.roller.RollerException
+ */
+ public Map getWeblogEntryStringMap(WebsiteData website,
+ Date startDate, Date endDate, String catName,
+ String status, String locale, int offset,
+ int range) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get weblog entries with given category or, optionally, any sub-category
+ * of that category.
+ * @param cat Category
+ * @param subcats True if sub-categories are to be fetched
+ * @return List of weblog entries in category
+ */
+ public List getWeblogEntries(WeblogCategoryData cat, boolean subcats)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get weblog enties ordered by descending number of comments.
+ * @param website Weblog or null to get for all weblogs.
+ * @param startDate Start date or null for no start date.
+ * @param endDate End date or null for no end date.
+ * @param offset Offset into results for paging
+ * @param length Max comments to return (or -1 for no limit)
+ * @return List of WeblogEntryData objects.
+ */
+ public List getMostCommentedWeblogEntries(WebsiteData website,
+ Date startDate, Date endDate, int offset,
+ int length) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get the WeblogEntry following, chronologically, the current entry.
+ * Restrict by the Category, if named.
+ * @param current The "current" WeblogEntryData
+ * @param catName The value of the requested Category Name
+ */
+ public WeblogEntryData getNextEntry(WeblogEntryData current,
+ String catName, String locale) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get the WeblogEntry prior to, chronologically, the current entry.
+ * Restrict by the Category, if named.
+ * @param current The "current" WeblogEntryData.
+ * @param catName The value of the requested Category Name.
+ */
+ public WeblogEntryData getPreviousEntry(WeblogEntryData current,
+ String catName, String locale) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get entries next after current entry.
+ * @param entry Current entry.
+ * @param catName Only return entries in this category (if not null).
+ * @param maxEntries Maximum number of entries to return.
+ */
+ public List getNextEntries(WeblogEntryData entry, String catName,
+ String locale, int maxEntries) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get entries previous to current entry.
+ * @param entry Current entry.
+ * @param catName Only return entries in this category (if not null).
+ * @param maxEntries Maximum number of entries to return.
+ */
+ public List getPreviousEntries(WeblogEntryData entry, String catName,
+ String locale, int maxEntries) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get specified number of most recent pinned and published Weblog Entries.
+ * @param max Maximum number to return.
+ * @return Collection of WeblogEntryData objects.
+ */
+ public List getWeblogEntriesPinnedToMain(Integer max)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get time of last update for a weblog specified by username
+ */
+ public Date getWeblogLastPublishTime(WebsiteData website)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Gets returns most recent pubTime, optionally restricted by category.
+ * @param website Handle of website or null for all users
+ * @param catName Category name of posts or null for all categories
+ * @return Date Of last publish time
+ */
+ public Date getWeblogLastPublishTime(WebsiteData website, String catName)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Save weblog category.
+ */
+ public void saveWeblogCategory(WeblogCategoryData cat)
+ throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Remove weblog category.
+ */
+ public void removeWeblogCategory(WeblogCategoryData cat)
+ throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get category by id.
+ */
+ public WeblogCategoryData getWeblogCategory(String id)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Recategorize all entries with one category to another.
+ */
+ public void moveWeblogCategoryContents(String srcId, String destId)
+ throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get top level categories for a website.
+ * @param website Website.
+ */
+ public WeblogCategoryData getRootWeblogCategory(WebsiteData website)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get category specified by website and categoryPath.
+ * @param website Website of WeblogCategory.
+ * @param categoryPath Path of WeblogCategory, relative to category root.
+ */
+ public WeblogCategoryData getWeblogCategoryByPath(WebsiteData website,
+ String categoryPath) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get sub-category by path relative to specified category.
+ * @param category Root of path or null to start at top of category tree.
+ * @param path Path of category to be located.
+ * @param website Website of categories.
+ * @return Category specified by path or null if not found.
+ */
+ public WeblogCategoryData getWeblogCategoryByPath(WebsiteData wd,
+ WeblogCategoryData category, String string) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get WebLogCategory objects for a website.
+ */
+ public List getWeblogCategories(WebsiteData website)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get WebLogCategory objects for a website.
+ */
+ public List getWeblogCategories(WebsiteData website, boolean includeRoot)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Get absolute path to category, appropriate for use by
+ * getWeblogCategoryByPath().
+ * @param category WeblogCategoryData.
+ * @return Forward slash separated path string.
+ */
public String getPath(WeblogCategoryData category) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
- public Assoc getWeblogCategoryParentAssoc(WeblogCategoryData data) throws RollerException {
+ /**
+ * Get parent association for a category.
+ */
+ public Assoc getWeblogCategoryParentAssoc(WeblogCategoryData data)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
- public List getWeblogCategoryChildAssocs(WeblogCategoryData data) throws RollerException {
+ /**
+ * Get child associations for a category.
+ */
+ public List getWeblogCategoryChildAssocs(WeblogCategoryData data)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
- public List getAllWeblogCategoryDecscendentAssocs(WeblogCategoryData data) throws RollerException {
+ /**
+ * Get all descendent associations for a category.
+ */
+ public List getAllWeblogCategoryDecscendentAssocs(WeblogCategoryData data)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
- public List getWeblogCategoryAncestorAssocs(WeblogCategoryData data) throws RollerException {
+ /**
+ * Get all ancestor associates for a category.
+ */
+ public List getWeblogCategoryAncestorAssocs(WeblogCategoryData data)
+ throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Save comment.
+ */
public void saveComment(CommentData comment) throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Remove comment.
+ */
public void removeComment(CommentData comment) throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Get comment by id.
+ */
public CommentData getComment(String id) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
- public List getComments(WebsiteData website, WeblogEntryData entry, String searchString, Date startDate, Date endDate, Boolean pending, Boolean approved, Boolean spam, boolean reverseChrono, int offset, int length) throws RollerException {
- }
-
+ /**
+ * Generic comments query method.
+ * @param website Website or null for all comments on site
+ * @param entry Entry or null to include all comments
+ * @param startDate Start date or null for no restriction
+ * @param endDate End date or null for no restriction
+ * @param pending Pending flag value or null for no restriction
+ * @param pending Approved flag value or null for no restriction
+ * @param reverseChrono True for results in reverse chrono order
+ * @param spam Spam flag value or null for no restriction
+ * @param offset Offset into results for paging
+ * @param length Max comments to return (or -1 for no limit)
+ */
+ public List getComments(WebsiteData website, WeblogEntryData entry,
+ String searchString, Date startDate,
+ Date endDate, Boolean pending,
+ Boolean approved, Boolean spam,
+ boolean reverseChrono, int offset,
+ int length) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
+ }
+
+ /**
+ * Create unique anchor for weblog entry.
+ */
public String createAnchor(WeblogEntryData data) throws RollerException {
+ return null; //To change body of implemented methods use File | Settings | File Templates.
}
- public boolean isDuplicateWeblogCategoryName(WeblogCategoryData data) throws RollerException {
- }
-
- public boolean isWeblogCategoryInUse(WeblogCategoryData data) throws RollerException {
+ /**
+ * Check for duplicate category name.
+ */
+ public boolean isDuplicateWeblogCategoryName(WeblogCategoryData data)
+ throws RollerException {
+ return false; //To change body of implemented methods use File | Settings | File Templates.
}
- public boolean isDescendentOf(WeblogCategoryData child, WeblogCategoryData ancestor) throws RollerException {
+ /**
+ * Check if weblog category is in use.
+ */
+ public boolean isWeblogCategoryInUse(WeblogCategoryData data)
+ throws RollerException {
+ return false; //To change body of implemented methods use File | Settings | File Templates.
}
- public String getUrl(WebsiteData website, String contextUrl) throws RollerException {
+ /**
+ * Returns true if ancestor is truly an ancestor of child.
+ */
+ public boolean isDescendentOf(WeblogCategoryData child,
+ WeblogCategoryData ancestor) throws RollerException {
+ return false; //To change body of implemented methods use File | Settings | File Templates.
}
- public void applyCommentDefaultsToEntries(WebsiteData website) throws RollerException {
+ /**
+ * Apply comment default settings from website to all of website's entries.
+ */
+ public void applyCommentDefaultsToEntries(WebsiteData website)
+ throws RollerException {
+ //To change body of implemented methods use File | Settings | File Templates.
}
+ /**
+ * Release all resources held by manager.
+ */
public void release() {
+ //To change body of implemented methods use File | Settings | File Templates.
}
-
}
Modified: incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/jdo/JDOPersistenceStrategy.java
URL: http://svn.apache.org/viewvc/incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/jdo/JDOPersistenceStrategy.java?view=diff&rev=441245&r1=441244&r2=441245
==============================================================================
--- incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/jdo/JDOPersistenceStrategy.java (original)
+++ incubator/roller/branches/roller_3.0/sandbox/jdobackend/src/org/apache/roller/business/jdo/JDOPersistenceStrategy.java Thu Sep 7 14:48:40 2006
@@ -187,7 +187,6 @@
* @param clazz the class of instances to find
* @param queryName the name of the query
* @param arg the argument to the query
- * @param types the types of the arguments to the query
* @return the results of the query
* @throws org.apache.roller.RollerException on any error
*/