You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@roller.apache.org by sn...@apache.org on 2006/05/02 00:23:34 UTC

svn commit: r398712 [1/32] - in /incubator/roller/trunk/src/org/apache: ./ roller/ roller/business/ roller/business/hibernate/ roller/business/referrers/ roller/business/runnable/ roller/business/search/ roller/business/search/operations/ roller/busine...

Author: snoopdave
Date: Mon May  1 15:23:02 2006
New Revision: 398712

URL: http://svn.apache.org/viewcvs?rev=398712&view=rev
Log:
Moving to org.apache.roller packaging

Added:
    incubator/roller/trunk/src/org/apache/
    incubator/roller/trunk/src/org/apache/roller/
    incubator/roller/trunk/src/org/apache/roller/RollerException.java
    incubator/roller/trunk/src/org/apache/roller/RollerPermissionsException.java
    incubator/roller/trunk/src/org/apache/roller/ThemeNotFoundException.java
    incubator/roller/trunk/src/org/apache/roller/business/
    incubator/roller/trunk/src/org/apache/roller/business/FileManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/IndexManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/PagePluginManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/RollerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/ThemeManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/ThreadManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateAutoPingManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateBookmarkManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateConfigManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernatePersistenceStrategy.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernatePingQueueManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernatePingTargetManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernatePlanetManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernatePropertiesManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateRefererManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateRollerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateRollerPlanetManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateUserManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/HibernateWeblogManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/hibernate/package.html
    incubator/roller/trunk/src/org/apache/roller/business/package.html
    incubator/roller/trunk/src/org/apache/roller/business/referrers/
    incubator/roller/trunk/src/org/apache/roller/business/referrers/IncomingReferrer.java
    incubator/roller/trunk/src/org/apache/roller/business/referrers/QueuedReferrerProcessingJob.java
    incubator/roller/trunk/src/org/apache/roller/business/referrers/ReferrerProcessingJob.java
    incubator/roller/trunk/src/org/apache/roller/business/referrers/ReferrerQueueManager.java
    incubator/roller/trunk/src/org/apache/roller/business/referrers/ReferrerQueueManagerImpl.java
    incubator/roller/trunk/src/org/apache/roller/business/roller-persistence.png   (with props)
    incubator/roller/trunk/src/org/apache/roller/business/roller-services-impl.png   (with props)
    incubator/roller/trunk/src/org/apache/roller/business/runnable/
    incubator/roller/trunk/src/org/apache/roller/business/runnable/ContinuousWorkerThread.java
    incubator/roller/trunk/src/org/apache/roller/business/runnable/Job.java
    incubator/roller/trunk/src/org/apache/roller/business/runnable/WorkerThread.java
    incubator/roller/trunk/src/org/apache/roller/business/search/
    incubator/roller/trunk/src/org/apache/roller/business/search/FieldConstants.java
    incubator/roller/trunk/src/org/apache/roller/business/search/IndexUtil.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/AddEntryOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/IndexOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/ReIndexEntryOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/ReadFromIndexOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/RebuildWebsiteIndexOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/RemoveEntryOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/RemoveWebsiteIndexOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/SearchOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/WriteToIndexOperation.java
    incubator/roller/trunk/src/org/apache/roller/business/search/operations/package.html
    incubator/roller/trunk/src/org/apache/roller/business/search/package.html
    incubator/roller/trunk/src/org/apache/roller/business/utils/
    incubator/roller/trunk/src/org/apache/roller/business/utils/ConsistencyCheck.java
    incubator/roller/trunk/src/org/apache/roller/business/utils/PasswordUtility.java
    incubator/roller/trunk/src/org/apache/roller/business/utils/UpgradeDatabase.java
    incubator/roller/trunk/src/org/apache/roller/business/utils/package.html
    incubator/roller/trunk/src/org/apache/roller/config/
    incubator/roller/trunk/src/org/apache/roller/config/PingConfig.java
    incubator/roller/trunk/src/org/apache/roller/config/RollerConfig.java
    incubator/roller/trunk/src/org/apache/roller/config/RollerRuntimeConfig.java
    incubator/roller/trunk/src/org/apache/roller/config/package.html
    incubator/roller/trunk/src/org/apache/roller/config/runtime/
    incubator/roller/trunk/src/org/apache/roller/config/runtime/ConfigDef.java
    incubator/roller/trunk/src/org/apache/roller/config/runtime/DisplayGroup.java
    incubator/roller/trunk/src/org/apache/roller/config/runtime/PropertyDef.java
    incubator/roller/trunk/src/org/apache/roller/config/runtime/RuntimeConfigDefs.java
    incubator/roller/trunk/src/org/apache/roller/config/runtime/RuntimeConfigDefsParser.java
    incubator/roller/trunk/src/org/apache/roller/config/runtime/package.html
    incubator/roller/trunk/src/org/apache/roller/model/
    incubator/roller/trunk/src/org/apache/roller/model/AutoPingManager.java
    incubator/roller/trunk/src/org/apache/roller/model/BookmarkManager.java
    incubator/roller/trunk/src/org/apache/roller/model/ConfigManager.java
    incubator/roller/trunk/src/org/apache/roller/model/FileManager.java
    incubator/roller/trunk/src/org/apache/roller/model/IndexManager.java
    incubator/roller/trunk/src/org/apache/roller/model/PagePlugin.java
    incubator/roller/trunk/src/org/apache/roller/model/PagePluginManager.java
    incubator/roller/trunk/src/org/apache/roller/model/PingQueueManager.java
    incubator/roller/trunk/src/org/apache/roller/model/PingTargetManager.java
    incubator/roller/trunk/src/org/apache/roller/model/PlanetManager.java
    incubator/roller/trunk/src/org/apache/roller/model/PropertiesManager.java
    incubator/roller/trunk/src/org/apache/roller/model/RefererManager.java
    incubator/roller/trunk/src/org/apache/roller/model/Roller.java
    incubator/roller/trunk/src/org/apache/roller/model/RollerFactory.java
    incubator/roller/trunk/src/org/apache/roller/model/ScheduledTask.java
    incubator/roller/trunk/src/org/apache/roller/model/ThemeManager.java
    incubator/roller/trunk/src/org/apache/roller/model/ThreadManager.java
    incubator/roller/trunk/src/org/apache/roller/model/UserManager.java
    incubator/roller/trunk/src/org/apache/roller/model/WeblogManager.java
    incubator/roller/trunk/src/org/apache/roller/model/package.html
    incubator/roller/trunk/src/org/apache/roller/model/roller-services.png   (with props)
    incubator/roller/trunk/src/org/apache/roller/package.html
    incubator/roller/trunk/src/org/apache/roller/pojos/
    incubator/roller/trunk/src/org/apache/roller/pojos/Assoc.java
    incubator/roller/trunk/src/org/apache/roller/pojos/AutoPingData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/BookmarkComparator.java
    incubator/roller/trunk/src/org/apache/roller/pojos/BookmarkData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/CommentData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/EntryAttributeData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/FolderAssoc.java
    incubator/roller/trunk/src/org/apache/roller/pojos/FolderData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/HierarchicalPersistentObject.java
    incubator/roller/trunk/src/org/apache/roller/pojos/ObjectAuditData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PermissionsData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PersistentObject.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PingCategoryRestrictionData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PingQueueEntryData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PingTargetData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PlanetConfigData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PlanetEntryData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PlanetGroupData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PlanetGroupSubscriptionAssoc.java
    incubator/roller/trunk/src/org/apache/roller/pojos/PlanetSubscriptionData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/RefererComparator.java
    incubator/roller/trunk/src/org/apache/roller/pojos/RefererData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/RoleData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/RollerConfigData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/RollerPropertyData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/Template.java
    incubator/roller/trunk/src/org/apache/roller/pojos/Theme.java
    incubator/roller/trunk/src/org/apache/roller/pojos/ThemeTemplate.java
    incubator/roller/trunk/src/org/apache/roller/pojos/UserData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WeblogCategoryAssoc.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WeblogCategoryData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WeblogEntryComparator.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WeblogEntryData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WeblogEntryWrapperComparator.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WeblogTemplate.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WebsiteData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/WebsiteDisplayData.java
    incubator/roller/trunk/src/org/apache/roller/pojos/package.html
    incubator/roller/trunk/src/org/apache/roller/pojos/roller-datamodel.png   (with props)
    incubator/roller/trunk/src/org/apache/roller/presentation/
    incubator/roller/trunk/src/org/apache/roller/presentation/ArchiveParser.java
    incubator/roller/trunk/src/org/apache/roller/presentation/Authenticator.java
    incubator/roller/trunk/src/org/apache/roller/presentation/BasePageModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/BlacklistUpdateTask.java
    incubator/roller/trunk/src/org/apache/roller/presentation/DefaultAuthenticator.java
    incubator/roller/trunk/src/org/apache/roller/presentation/InvalidRequestException.java
    incubator/roller/trunk/src/org/apache/roller/presentation/LanguageUtil.java
    incubator/roller/trunk/src/org/apache/roller/presentation/MainPageAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/ParsedRequest.java
    incubator/roller/trunk/src/org/apache/roller/presentation/PlanetRequest.java
    incubator/roller/trunk/src/org/apache/roller/presentation/RollerContext.java
    incubator/roller/trunk/src/org/apache/roller/presentation/RollerRequest.java
    incubator/roller/trunk/src/org/apache/roller/presentation/RollerSession.java
    incubator/roller/trunk/src/org/apache/roller/presentation/TurnoverReferersTask.java
    incubator/roller/trunk/src/org/apache/roller/presentation/WeblogFeedRequest.java
    incubator/roller/trunk/src/org/apache/roller/presentation/WeblogPageRequest.java
    incubator/roller/trunk/src/org/apache/roller/presentation/WeblogRequest.java
    incubator/roller/trunk/src/org/apache/roller/presentation/ajax/
    incubator/roller/trunk/src/org/apache/roller/presentation/ajax/UserDataServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/BookmarkEditAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/BookmarkSaveAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/BookmarksAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/FolderEditAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/FolderSaveAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/ImportBookmarksFormAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/actions/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/formbeans/
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/formbeans/BookmarkFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/formbeans/BookmarksForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/formbeans/FolderFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/bookmarks/formbeans/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/Cache.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/CacheFactory.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/CacheHandler.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/CacheManager.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/ExpiringCacheEntry.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/ExpiringLRUCacheFactoryImpl.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/ExpiringLRUCacheImpl.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/FuturePostingsInvalidationJob.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/LRUCacheFactoryImpl.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/LRUCacheImpl.java
    incubator/roller/trunk/src/org/apache/roller/presentation/cache/LazyExpiringCacheEntry.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/BreadCrumbFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/ByteArrayOutputStreamWrapper.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/ByteArrayResponseWrapper.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/CharEncodingFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/CompressionFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/DebugFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/FeedCacheFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/IPBanFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/IfModifiedFeedCacheFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/IfModifiedWeblogPageCacheFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/IfPlanetModifiedFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/MainPageCacheFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/PersistenceSessionFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/PlanetCacheFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/RefererFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/RequestFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/SchemeEnforcementFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/WeblogPageCacheFilter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/filters/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/newsfeeds/
    incubator/roller/trunk/src/org/apache/roller/presentation/newsfeeds/NewsfeedCache.java
    incubator/roller/trunk/src/org/apache/roller/presentation/newsfeeds/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/pings/
    incubator/roller/trunk/src/org/apache/roller/presentation/pings/PingQueueProcessor.java
    incubator/roller/trunk/src/org/apache/roller/presentation/pings/PingQueueTask.java
    incubator/roller/trunk/src/org/apache/roller/presentation/pings/WeblogUpdatePinger.java
    incubator/roller/trunk/src/org/apache/roller/presentation/pings/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/PlanetAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/PlanetConfigAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/PlanetGroupsAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/PlanetSubscriptionFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/PlanetSubscriptionsAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/RefreshEntriesTask.java
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/SyncWebsitesTask.java
    incubator/roller/trunk/src/org/apache/roller/presentation/planet/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/roller-ui.png   (with props)
    incubator/roller/trunk/src/org/apache/roller/presentation/search/
    incubator/roller/trunk/src/org/apache/roller/presentation/search/SearchAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/search/SearchResultsPageModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/search/SearchServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/servlets/
    incubator/roller/trunk/src/org/apache/roller/presentation/servlets/CommentAuthenticatorServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/servlets/CommentServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/servlets/ResourceServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/servlets/TrackbackServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/DateTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/HybridTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/LinkParamTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/LinkTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/RowTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/StatusMessageTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/VelocityTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/calendar/
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/calendar/CalendarModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/calendar/CalendarTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/calendar/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/BaseRollerMenu.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/EditorNavigationBarTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/Menu.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/MenuImpl.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/MenuItem.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/MenuItemImpl.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/MenuModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/MenuTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/RollerMenuModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/menu/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/tags/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/util/
    incubator/roller/trunk/src/org/apache/roller/presentation/util/CacheHttpServletResponseWrapper.java
    incubator/roller/trunk/src/org/apache/roller/presentation/util/RequestUtil.java
    incubator/roller/trunk/src/org/apache/roller/presentation/util/ResponseContent.java
    incubator/roller/trunk/src/org/apache/roller/presentation/util/SplitPrintWriter.java
    incubator/roller/trunk/src/org/apache/roller/presentation/util/SplitServletOutputStream.java
    incubator/roller/trunk/src/org/apache/roller/presentation/util/StrutsUtil.java
    incubator/roller/trunk/src/org/apache/roller/presentation/util/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/CommentAuthenticator.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/CommentServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/ContextLoader.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/DefaultCommentAuthenticator.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/ExportRss.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/FlavorServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/FoafServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/LanguageServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/MathCommentAuthenticator.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/PageHelper.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/PageModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/PageServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/PlanetFeedServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/PlanetPageModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/PreviewServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/RSDServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/RollerResourceLoader.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/ThemeResourceLoader.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/WebappResourceLoader.java
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/export_atom.vm
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/export_rss.vm
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/velocity/roller-velocity.png   (with props)
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/BasePingTargetsAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/CategoriesAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/CategoryDeleteAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/CategoryEditAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/CategorySaveAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/CommentManagementAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/CustomPingTargetsAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/ExportEntriesAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/ImportEntriesAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/PingSetupAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/ReferersAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/ToggleLinkbackDisplayAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/WeblogEntryFormAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/WeblogEntryManagementAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/WeblogEntryPageModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/actions/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/BakeWeblogForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/CategoriesForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/CategoryDeleteForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/CommentFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/CommentManagementForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/CommentQueryForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/ImportEntriesForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/PingSetupForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/TrackbackForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/WeblogCategoryFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/WeblogEntryFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/WeblogEntryManagementForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/WeblogEntryQueryForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/formbeans/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/BigWeblogCalendarModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/DateMacro.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/EditWeblogCalendarModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/RssBadgeTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/ShowEntryContentTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/ShowEntrySummaryTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/ShowEntryTextTag.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/WeblogCalendarModel.java
    incubator/roller/trunk/src/org/apache/roller/presentation/weblog/tags/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/AtomHandler.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/AtomService.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/AtomServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/PubControlModule.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/PubControlModuleGenerator.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/PubControlModuleImpl.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/PubControlModuleParser.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/RollerAtomHandler.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/WSSEUtilities.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/atomprotocol/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/xmlrpc/
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/xmlrpc/BaseAPIHandler.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/xmlrpc/BloggerAPIHandler.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/xmlrpc/MetaWeblogAPIHandler.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/xmlrpc/RollerXMLRPCServlet.java
    incubator/roller/trunk/src/org/apache/roller/presentation/webservices/xmlrpc/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/website/
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/CacheInfoAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/CommonPingTargetsAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/CreateWebsiteAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/InviteMemberAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/MaintenanceAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/MemberPermissionsAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/RollerPropertiesAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/ThemeEditorAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/UploadFileFormAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/UserAdminAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/UserBaseAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/UserNewAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/WeblogTemplateFormAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/WebsiteFormAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/YourProfileAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/YourWebsitesAction.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/actions/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/CreateWebsiteForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/InviteMemberForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/MaintenanceForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/MemberPermissionsForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/RollerConfigFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/ThemeEditorForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/UploadFileForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/UserAdminForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/UserFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/WebsiteFormEx.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/YourWebsitesForm.java
    incubator/roller/trunk/src/org/apache/roller/presentation/website/formbeans/package.html
    incubator/roller/trunk/src/org/apache/roller/presentation/website/package.html
    incubator/roller/trunk/src/org/apache/roller/util/
    incubator/roller/trunk/src/org/apache/roller/util/Blacklist.java
    incubator/roller/trunk/src/org/apache/roller/util/DateUtil.java
    incubator/roller/trunk/src/org/apache/roller/util/ISO8601DateParser.java
    incubator/roller/trunk/src/org/apache/roller/util/LRUCache.java
    incubator/roller/trunk/src/org/apache/roller/util/LRUCache2.java
    incubator/roller/trunk/src/org/apache/roller/util/LinkbackExtractor.java
    incubator/roller/trunk/src/org/apache/roller/util/LocaleComparator.java
    incubator/roller/trunk/src/org/apache/roller/util/MD5Encoder.java
    incubator/roller/trunk/src/org/apache/roller/util/MailUtil.java
    incubator/roller/trunk/src/org/apache/roller/util/OldRollerConfig.java
    incubator/roller/trunk/src/org/apache/roller/util/PojoUtil.java
    incubator/roller/trunk/src/org/apache/roller/util/PropertyExpander.java
    incubator/roller/trunk/src/org/apache/roller/util/RandomGUID.java
    incubator/roller/trunk/src/org/apache/roller/util/RegexUtil.java
    incubator/roller/trunk/src/org/apache/roller/util/RollerMessages.java
    incubator/roller/trunk/src/org/apache/roller/util/SpamChecker.java
    incubator/roller/trunk/src/org/apache/roller/util/StringUtils.java
    incubator/roller/trunk/src/org/apache/roller/util/Technorati.java
    incubator/roller/trunk/src/org/apache/roller/util/TimeZoneComparator.java
    incubator/roller/trunk/src/org/apache/roller/util/Utilities.java
    incubator/roller/trunk/src/org/apache/roller/util/XSLTransform.java
    incubator/roller/trunk/src/org/apache/roller/util/package.html
    incubator/roller/trunk/src/org/apache/roller/util/rome/
    incubator/roller/trunk/src/org/apache/roller/util/rome/ContentModule.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/ContentModuleGenerator.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/ContentModuleImpl.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/ContentModuleParser.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/DiskFeedInfoCache.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/PlanetConverterForRSS091N.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/PlanetConverterForRSS091U.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/PlanetConverterForRSS20.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/PlanetRSS091NParser.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/PlanetRSS091UParser.java
    incubator/roller/trunk/src/org/apache/roller/util/rome/package.html

Added: incubator/roller/trunk/src/org/apache/roller/RollerException.java
URL: http://svn.apache.org/viewcvs/incubator/roller/trunk/src/org/apache/roller/RollerException.java?rev=398712&view=auto
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/RollerException.java (added)
+++ incubator/roller/trunk/src/org/apache/roller/RollerException.java Mon May  1 15:23:02 2006
@@ -0,0 +1,135 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one or more
+*  contributor license agreements.  The ASF licenses this file to You
+* under the Apache License, Version 2.0 (the "License"); you may not
+* use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.  For additional information regarding
+* copyright in this work, please see the NOTICE file in the top level
+* directory of this distribution.
+*/
+
+package org.apache.roller;
+
+import java.io.PrintStream;
+import java.io.PrintWriter;
+
+/**
+ * Roller services interfaces throw this exception.
+ */ 
+public class RollerException extends Exception
+{
+    private Throwable mRootCause = null;
+    
+	/**
+	 * Construct RollerException, wrapping existing throwable.
+	 * @param s Error message
+	 * @param t Existing connection to wrap.
+	 */
+	public RollerException(String s,Throwable t)
+	{
+		super(s);
+        mRootCause = t;
+	}
+	/**
+	 * Construct RollerException, wrapping existing throwable.
+	 * @param t Existing exception to be wrapped.
+	 */
+	public RollerException(Throwable t)
+	{
+        mRootCause = t;
+	}
+	/**
+	 * Construct RollerException with message string.
+	 * @param s Error message string.
+	 */
+	public RollerException(String s)
+	{
+		super(s);
+	}
+	/**
+	 * Construct emtpy exception object.
+	 */
+	public RollerException()
+	{
+		super();
+	}
+    /**
+     * Get root cause object, or null if none.
+     * @return Root cause or null if none.
+     */
+    public Throwable getRootCause()
+    {
+        return mRootCause;
+    }
+   
+    /**
+     * Print stack trace for exception and for root cause exception if htere is one.
+     * @see java.lang.Throwable#printStackTrace()
+     */
+    public void printStackTrace()
+    {
+        super.printStackTrace();
+        if (mRootCause != null)
+        {
+            System.out.println("--- ROOT CAUSE ---");
+            mRootCause.printStackTrace();
+        }
+    }
+
+    /**
+     * Print stack trace for exception and for root cause exception if htere is one.
+     * @param s Stream to print to.
+     */
+    public void printStackTrace(PrintStream s)
+    {
+        super.printStackTrace(s);
+        if (mRootCause != null)
+        {
+            s.println("--- ROOT CAUSE ---");
+            mRootCause.printStackTrace(s);
+        }
+    }
+
+    /**
+     * Print stack trace for exception and for root cause exception if htere is one.
+     * @param s Writer to write to.
+     */
+    public void printStackTrace(PrintWriter s)
+    {
+       super.printStackTrace(s);
+       if (null != mRootCause) 
+       {
+           s.println("--- ROOT CAUSE ---");
+           mRootCause.printStackTrace(s);
+       }
+    }
+
+    /**
+     * Get root cause message.
+     * @return Root cause message.
+     */
+    public String getRootCauseMessage() 
+    {
+        String rcmessage = null;
+        if (getRootCause()!=null) 
+        {
+            if (getRootCause().getCause()!=null)
+            {
+                rcmessage = getRootCause().getCause().getMessage();
+            }
+            rcmessage = (rcmessage == null) ? getRootCause().getMessage() : rcmessage;
+            rcmessage = (rcmessage == null) ? super.getMessage() : rcmessage;
+            rcmessage = (rcmessage == null) ? "NONE" : rcmessage;
+        }
+        return rcmessage;
+    }
+}
+

Added: incubator/roller/trunk/src/org/apache/roller/RollerPermissionsException.java
URL: http://svn.apache.org/viewcvs/incubator/roller/trunk/src/org/apache/roller/RollerPermissionsException.java?rev=398712&view=auto
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/RollerPermissionsException.java (added)
+++ incubator/roller/trunk/src/org/apache/roller/RollerPermissionsException.java Mon May  1 15:23:02 2006
@@ -0,0 +1,51 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one or more
+*  contributor license agreements.  The ASF licenses this file to You
+* under the Apache License, Version 2.0 (the "License"); you may not
+* use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.  For additional information regarding
+* copyright in this work, please see the NOTICE file in the top level
+* directory of this distribution.
+*/
+package org.apache.roller;
+
+/**
+ * Thrown when persistence session user lacks one or more required permissions.
+ */ 
+public class RollerPermissionsException extends RollerException
+{
+	/**
+	 * Construct RollerException, wrapping existing throwable.
+	 * @param s Error message.
+	 * @param t Throwable to be wrapped
+	 */
+	public RollerPermissionsException(String s,Throwable t)
+	{
+		super(s,t);
+	}
+	/**
+	 * Construct RollerException, wrapping existing throwable.
+	 * @param t Throwable to be wrapped
+	 */
+	public RollerPermissionsException(Throwable t)
+	{
+        super(t);
+	}
+	/**
+	 * Construct RollerException, with error message.
+	 * @param s Error message
+	 */
+	public RollerPermissionsException(String s)
+	{
+		super(s);
+	}
+}
+

Added: incubator/roller/trunk/src/org/apache/roller/ThemeNotFoundException.java
URL: http://svn.apache.org/viewcvs/incubator/roller/trunk/src/org/apache/roller/ThemeNotFoundException.java?rev=398712&view=auto
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/ThemeNotFoundException.java (added)
+++ incubator/roller/trunk/src/org/apache/roller/ThemeNotFoundException.java Mon May  1 15:23:02 2006
@@ -0,0 +1,50 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one or more
+*  contributor license agreements.  The ASF licenses this file to You
+* under the Apache License, Version 2.0 (the "License"); you may not
+* use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.  For additional information regarding
+* copyright in this work, please see the NOTICE file in the top level
+* directory of this distribution.
+*/
+/*
+ * ThemeNotFoundException.java
+ *
+ * Created on June 28, 2005, 12:48 PM
+ */
+
+package org.apache.roller;
+
+
+/**
+ * Thrown when the ThemeManager has a problem finding a named theme.
+ *
+ * @author Allen Gilliland
+ */
+public class ThemeNotFoundException extends RollerException {
+    
+    public ThemeNotFoundException(String s,Throwable t) {
+        super(s, t);
+    }
+    
+    public ThemeNotFoundException(Throwable t) {
+        super(t);
+    }
+    
+    public ThemeNotFoundException(String s) {
+        super(s);
+    }
+    
+    public ThemeNotFoundException() {
+        super();
+    }
+    
+}

Added: incubator/roller/trunk/src/org/apache/roller/business/FileManagerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/trunk/src/org/apache/roller/business/FileManagerImpl.java?rev=398712&view=auto
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/business/FileManagerImpl.java (added)
+++ incubator/roller/trunk/src/org/apache/roller/business/FileManagerImpl.java Mon May  1 15:23:02 2006
@@ -0,0 +1,291 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one or more
+*  contributor license agreements.  The ASF licenses this file to You
+* under the Apache License, Version 2.0 (the "License"); you may not
+* use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.  For additional information regarding
+* copyright in this work, please see the NOTICE file in the top level
+* directory of this distribution.
+*/
+package org.apache.roller.business;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.math.BigDecimal;
+import java.util.Map;
+import org.apache.commons.lang.StringUtils;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.roller.RollerException;
+import org.apache.roller.config.RollerConfig;
+import org.apache.roller.config.RollerRuntimeConfig;
+import org.apache.roller.model.FileManager;
+import org.apache.roller.model.Roller;
+import org.apache.roller.model.RollerFactory;
+import org.apache.roller.pojos.RollerPropertyData;
+import org.apache.roller.util.RollerMessages;
+
+/**
+ * Responsible for managing website resources.  This base implementation
+ * writes resources to a filesystem.
+ *
+ * @author David M Johnson
+ * @author Allen Gilliland
+ */
+public class FileManagerImpl implements FileManager {
+    private String upload_dir = null;
+    private String upload_url = null;
+    
+    private static Log mLogger =
+            LogFactory.getFactory().getInstance(FileManagerImpl.class);
+    
+    
+    /**
+     * Create file manager.
+     */
+    public FileManagerImpl() {
+        String uploaddir = RollerConfig.getProperty("uploads.dir");
+        String uploadurl = RollerConfig.getProperty("uploads.url");
+        
+        // Note: System property expansion is now handled by RollerConfig.
+        
+        if(uploaddir == null || uploaddir.trim().length() < 1)
+            uploaddir = System.getProperty("user.home") + File.separator+"roller_data"+File.separator+"uploads";
+        
+        if( ! uploaddir.endsWith(File.separator))
+            uploaddir += File.separator;
+        
+        if(uploadurl == null || uploadurl.trim().length() < 1)
+            uploadurl = File.separator+"resources";
+        
+        this.upload_dir = uploaddir.replace('/',File.separatorChar);
+        this.upload_url = uploadurl;
+    }
+    
+    
+    /**
+     * Get the upload directory being used by this file manager
+     **/
+    public String getUploadDir() {
+        return this.upload_dir;
+    }
+    
+    /**
+     * Get the upload path being used by this file manager
+     **/
+    public String getUploadUrl() {
+        return this.upload_url;
+    }
+    
+    
+    /**
+     * Determine if file can be saved given current RollerConfig settings.
+     */
+    public boolean canSave(
+            String weblogHandle, String name, long size, RollerMessages messages)
+            throws RollerException {
+        Roller mRoller = RollerFactory.getRoller();
+        Map config = mRoller.getPropertiesManager().getProperties();
+        
+        if (!((RollerPropertyData)config.get("uploads.enabled")).getValue().equalsIgnoreCase("true")) {
+            messages.addError("error.upload.disabled");
+            return false;
+        }
+        
+        String allows = ((RollerPropertyData)config.get("uploads.types.allowed")).getValue();
+        String forbids = ((RollerPropertyData)config.get("uploads.types.forbid")).getValue();
+        String[] allowFiles = StringUtils.split(StringUtils.deleteWhitespace(allows), ",");
+        String[] forbidFiles = StringUtils.split(StringUtils.deleteWhitespace(forbids), ",");
+        if (!checkFileType(allowFiles, forbidFiles, name)) {
+            messages.addError("error.upload.forbiddenFile", allows);
+            return false;
+        }
+        
+        BigDecimal maxDirMB = new BigDecimal(
+                ((RollerPropertyData)config.get("uploads.dir.maxsize")).getValue());
+        int maxDirBytes = (int)(1024000 * maxDirMB.doubleValue());
+        int userDirSize = getWebsiteDirSize(weblogHandle, this.upload_dir);
+        if (userDirSize + size > maxDirBytes) {
+            messages.addError("error.upload.dirmax", maxDirMB.toString());
+            return false;
+        }
+        
+        BigDecimal maxFileMB = new BigDecimal(
+                ((RollerPropertyData)config.get("uploads.file.maxsize")).getValue());
+        int maxFileBytes = (int)(1024000 * maxFileMB.doubleValue());
+        mLogger.debug(""+maxFileBytes);
+        mLogger.debug(""+size);
+        if (size > maxFileBytes) {
+            messages.addError("error.upload.filemax", maxFileMB.toString());
+            return false;
+        }
+        
+        return true;
+    }
+    
+    public boolean overQuota(String weblogHandle) throws RollerException {
+        
+        String maxDir = RollerRuntimeConfig.getProperty("uploads.dir.maxsize");
+        String maxFile = RollerRuntimeConfig.getProperty("uploads.file.maxsize");
+        BigDecimal maxDirSize = new BigDecimal(maxDir); // in megabytes
+        BigDecimal maxFileSize = new BigDecimal(maxFile); // in megabytes
+
+        // determine the number of bytes in website's directory
+        int maxDirBytes = (int)(1024000 * maxDirSize.doubleValue());
+        int userDirSize = 0;
+         String dir = getUploadDir();
+         File d = new File(dir + weblogHandle);
+        if (d.mkdirs() || d.exists()) {
+            File[] files = d.listFiles();
+            long dirSize = 0l;
+            for (int i=0; i<files.length; i++) {
+                if (!files[i].isDirectory()) {
+                    dirSize = dirSize + files[i].length();
+                }
+            }
+            userDirSize = new Long(dirSize).intValue();
+        }
+        return userDirSize > maxDirBytes;
+    }
+    
+    /**
+     * Get collection files in website's resource directory.
+     * @param site Website
+     * @return Collection of files in website's resource directory
+     */
+    public File[] getFiles(String weblogHandle) throws RollerException {
+        String dir = this.upload_dir + weblogHandle;
+        File uploadDir = new File(dir);
+        return uploadDir.listFiles();
+    }
+    
+    /**
+     * Delete named file from website's resource area.
+     */
+    public void deleteFile(String weblogHandle, String name)
+    throws RollerException {
+        String dir = this.upload_dir + weblogHandle;
+        File f = new File(dir + File.separator + name);
+        f.delete();
+    }
+    
+    /**
+     * Save file to website's resource directory.
+     * @param site Website to save to
+     * @param name Name of file to save
+     * @param size Size of file to be saved
+     * @param is Read file from input stream
+     */
+    public void saveFile(String weblogHandle, String name, long size, InputStream is)
+    throws RollerException {
+        if (!canSave(weblogHandle, name, size, new RollerMessages())) {
+            throw new RollerException("ERROR: upload denied");
+        }
+        
+        byte[] buffer = new byte[8192];
+        int bytesRead = 0;
+        String dir = this.upload_dir;
+        
+        File dirPath = new File(dir + File.separator + weblogHandle);
+        if (!dirPath.exists()) {
+            dirPath.mkdirs();
+        }
+        OutputStream bos = null;
+        try {
+            bos = new FileOutputStream(
+                    dirPath.getAbsolutePath() + File.separator + name);
+            while ((bytesRead = is.read(buffer, 0, 8192)) != -1) {
+                bos.write(buffer, 0, bytesRead);
+            }
+        } catch (Exception e) {
+            throw new RollerException("ERROR uploading file", e);
+        } finally {
+            try {
+                bos.flush();
+                bos.close();
+            } catch (Exception ignored) {}
+        }
+        if (mLogger.isDebugEnabled()) {
+            mLogger.debug("The file has been written to \"" + dir + weblogHandle + "\"");
+        }
+    }
+    
+    /**
+     * Returns current size of file uploads owned by specified weblog handle.
+     * @param username User
+     * @param dir      Upload directory
+     * @return Size of user's uploaded files in bytes.
+     */
+    private int getWebsiteDirSize(String weblogHandle, String dir) {
+        int userDirSize = 0;
+        File d = new File(dir + File.separator + weblogHandle);
+        if (d.mkdirs() || d.exists()) {
+            File[] files = d.listFiles();
+            long dirSize = 0l;
+            for (int i=0; i<files.length; i++) {
+                if (!files[i].isDirectory()) {
+                    dirSize = dirSize + files[i].length();
+                }
+            }
+            userDirSize = new Long(dirSize).intValue();
+        }
+        return userDirSize;
+    }
+    
+    /**
+     * Return true if file is allowed to be uplaoded given specified allowed and
+     * forbidden file types.
+     * @param allowFiles  File types (i.e. extensions) that are allowed
+     * @param forbidFiles File types that are forbidden
+     * @param fileName    Name of file to be uploaded
+     * @return True if file is allowed to be uploaded
+     */
+    private boolean checkFileType(
+            String[] allowFiles, String[] forbidFiles, String fileName) {
+        // default to false
+        boolean allowFile = false;
+        
+        // if this person hasn't listed any allows, then assume they want
+        // to allow *all* filetypes, except those listed under forbid
+        if(allowFiles == null || allowFiles.length < 1)
+            allowFile = true;
+        
+        // check for allowed types
+        if (allowFiles != null && allowFiles.length > 0) {
+            for (int y=0; y<allowFiles.length; y++) {
+                if (fileName.toLowerCase().endsWith(
+                        allowFiles[y].toLowerCase())) {
+                    allowFile = true;
+                    break;
+                }
+            }
+        }
+        
+        // check for forbidden types ... this overrides any allows
+        if (forbidFiles != null && forbidFiles.length > 0) {
+            for (int x=0; x<forbidFiles.length; x++) {
+                if (fileName.toLowerCase().endsWith(
+                        forbidFiles[x].toLowerCase())) {
+                    allowFile = false;
+                    break;
+                }
+            }
+        }
+        
+        return allowFile;
+    }
+    
+    public void release() {
+    }
+}

Added: incubator/roller/trunk/src/org/apache/roller/business/IndexManagerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/trunk/src/org/apache/roller/business/IndexManagerImpl.java?rev=398712&view=auto
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/business/IndexManagerImpl.java (added)
+++ incubator/roller/trunk/src/org/apache/roller/business/IndexManagerImpl.java Mon May  1 15:23:02 2006
@@ -0,0 +1,454 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one or more
+*  contributor license agreements.  The ASF licenses this file to You
+* under the Apache License, Version 2.0 (the "License"); you may not
+* use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.  For additional information regarding
+* copyright in this work, please see the NOTICE file in the top level
+* directory of this distribution.
+*/
+/*
+ * Created on Jul 18, 2003
+ *
+ * Authored by: Mindaugas Idzelis  (min@idzelis.com)
+ */
+package org.apache.roller.business;
+
+import java.io.File;
+import java.io.IOException;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.lucene.analysis.Analyzer;
+import org.apache.lucene.analysis.standard.StandardAnalyzer;
+import org.apache.lucene.index.IndexReader;
+import org.apache.lucene.index.IndexWriter;
+import org.apache.lucene.store.Directory;
+import org.apache.lucene.store.FSDirectory;
+import org.apache.lucene.store.RAMDirectory;
+import org.apache.roller.RollerException;
+import org.apache.roller.business.search.operations.AddEntryOperation;
+import org.apache.roller.business.search.operations.IndexOperation;
+import org.apache.roller.business.search.operations.ReIndexEntryOperation;
+import org.apache.roller.business.search.operations.RebuildWebsiteIndexOperation;
+import org.apache.roller.business.search.operations.RemoveEntryOperation;
+import org.apache.roller.business.search.operations.RemoveWebsiteIndexOperation;
+import org.apache.roller.business.search.operations.WriteToIndexOperation;
+import org.apache.roller.model.IndexManager;
+import org.apache.roller.pojos.WeblogEntryData;
+import org.apache.roller.pojos.WebsiteData;
+
+import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;
+import org.apache.roller.config.RollerConfig;
+import org.apache.roller.model.RollerFactory;
+import org.apache.roller.util.StringUtils;
+
+/**
+ * Lucene implementation of IndexManager. This is the central entry point into the Lucene
+ * searching API.
+ * @author aim4min
+ * @author mraible (formatting and making indexDir configurable)
+ */
+public class IndexManagerImpl implements IndexManager
+{
+    //~ Static fields/initializers
+    // =============================================
+
+    private IndexReader reader;
+
+    static Log mLogger = LogFactory.getFactory().getInstance(
+            IndexManagerImpl.class);
+
+    //~ Instance fields
+    // ========================================================
+
+    private boolean searchEnabled = true;
+
+    File indexConsistencyMarker;
+
+    private boolean useRAMIndex = false;
+
+    private RAMDirectory fRAMindex;
+
+    private String indexDir = null;
+
+    private boolean inconsistentAtStartup = false;
+
+    private ReadWriteLock rwl = new WriterPreferenceReadWriteLock();
+
+    //~ Constructors
+    // ===========================================================
+
+    /**
+     * Creates a new lucene index manager. This should only be created once.
+     * Creating the index manager more than once will definately result in
+     * errors. The preferred way of getting an index is through the
+     * RollerContext.
+     * 
+     * @param indexDir -
+     *            the path to the index directory
+     */
+    public IndexManagerImpl()
+    {
+        // check config to see if the internal search is enabled
+        String enabled = RollerConfig.getProperty("search.enabled");
+        if("false".equalsIgnoreCase(enabled))
+            this.searchEnabled = false;
+        
+        // we also need to know what our index directory is
+        // Note: system property expansion is now handled by RollerConfig
+        String indexDir = RollerConfig.getProperty("search.index.dir");
+
+        this.indexDir = indexDir.replace('/', File.separatorChar);
+        
+        // a little debugging
+        mLogger.info("search enabled: " + this.searchEnabled);
+        mLogger.info("index dir: " + this.indexDir);
+
+        String test = indexDir + File.separator + ".index-inconsistent";
+        indexConsistencyMarker = new File(test);
+
+        // only setup the index if search is enabled
+        if (this.searchEnabled) 
+        {
+            
+            // 1. If inconsistency marker exists.
+            //     Delete index
+            // 2. if we're using RAM index
+            //     load ram index wrapper around index
+            //
+            if (indexConsistencyMarker.exists()) 
+            {
+                getFSDirectory(true);
+                inconsistentAtStartup = true;
+            } 
+            else 
+            {
+                try 
+                {
+                    File makeIndexDir = new File(indexDir);
+                    if (!makeIndexDir.exists()) 
+                    {
+                        makeIndexDir.mkdirs();
+                        inconsistentAtStartup = true;
+                    }
+                    indexConsistencyMarker.createNewFile();
+                } 
+                catch (IOException e) 
+                {
+                    mLogger.error(e);
+                }
+            }
+            
+            if (indexExists()) 
+            {
+                if (useRAMIndex) 
+                {
+                    Directory filesystem = getFSDirectory(false);
+                    
+                    try 
+                    {
+                        fRAMindex = new RAMDirectory(filesystem);
+                    } 
+                    catch (IOException e)                     
+                    {
+                        mLogger.error("Error creating in-memory index", e);
+                    }
+                }
+            } 
+            else 
+            {
+                if (useRAMIndex) 
+                {
+                    fRAMindex = new RAMDirectory();
+                    createIndex(fRAMindex);
+                } 
+                else 
+                {
+                    createIndex(getFSDirectory(true));
+                }
+            }
+            
+            if (isInconsistentAtStartup())
+            {
+                mLogger.info(
+                    "Index was inconsistent. Rebuilding index in the background...");
+                try 
+                {                    
+                    rebuildWebsiteIndex();
+                }
+                catch (RollerException e) 
+                {
+                    mLogger.error("ERROR: scheduling re-index operation");
+                }
+            }       
+        }
+    }
+
+    //~ Methods
+    // ================================================================
+    
+    public void rebuildWebsiteIndex() throws RollerException
+    {
+        scheduleIndexOperation( 
+                new RebuildWebsiteIndexOperation(this, null));
+    }
+    
+    public void rebuildWebsiteIndex(WebsiteData website) throws RollerException
+    {
+        scheduleIndexOperation( 
+                new RebuildWebsiteIndexOperation(this, website));
+    }
+    
+    public void removeWebsiteIndex(WebsiteData website) throws RollerException
+    {
+        scheduleIndexOperation(
+                new RemoveWebsiteIndexOperation(this, website));
+    }
+    
+    public void addEntryIndexOperation(WeblogEntryData entry) throws RollerException
+    {
+        AddEntryOperation addEntry = new AddEntryOperation(this, entry);
+        scheduleIndexOperation(addEntry);
+    }
+    
+    public void addEntryReIndexOperation(WeblogEntryData entry) throws RollerException
+    {
+        ReIndexEntryOperation reindex = new ReIndexEntryOperation(this, entry);
+        scheduleIndexOperation(reindex);
+    }
+ 
+    public void removeEntryIndexOperation(WeblogEntryData entry) throws RollerException
+    {
+        RemoveEntryOperation removeOp = new RemoveEntryOperation(this, entry);
+        executeIndexOperationNow(removeOp); 
+    }
+    
+    public ReadWriteLock getReadWriteLock()
+    {
+        return rwl;
+    }
+
+    public boolean isInconsistentAtStartup()
+    {
+        return inconsistentAtStartup;
+    }
+
+    /**
+     * This is the analyzer that will be used to tokenize comment text.
+     * 
+     * @return Analyzer to be used in manipulating the database.
+     */
+    public static final Analyzer getAnalyzer()
+    {
+        return new StandardAnalyzer();
+    }
+
+    private void scheduleIndexOperation(final IndexOperation op)
+    {
+        try
+        {
+            // only if search is enabled
+            if(this.searchEnabled) {
+                mLogger.debug("Starting scheduled index operation: "+op.getClass().getName());
+                RollerFactory.getRoller().getThreadManager().executeInBackground(op);
+            }
+        }
+        catch (RollerException re)
+        {
+            mLogger.error("Error getting thread manager", re);
+        }
+        catch (InterruptedException e)
+        {
+            mLogger.error("Error executing operation", e);
+        }
+    }
+
+    /**
+     * @param search
+     */
+    public void executeIndexOperationNow(final IndexOperation op)
+    {
+        try
+        {
+            // only if search is enabled
+            if(this.searchEnabled) {
+                mLogger.debug("Executing index operation now: "+op.getClass().getName());
+                RollerFactory.getRoller().getThreadManager().executeInForeground(op);
+            }
+        }
+        catch (RollerException re)
+        {
+            mLogger.error("Error getting thread manager", re);
+        }
+        catch (InterruptedException e)
+        {
+            mLogger.error("Error executing operation", e);
+        }
+    }
+
+    public synchronized void resetSharedReader() 
+    {
+        reader = null;
+    }
+    public synchronized IndexReader getSharedIndexReader()
+    {
+        if (reader == null)
+        {
+            try
+            {
+                reader = IndexReader.open(getIndexDirectory());
+            }
+            catch (IOException e)
+            {
+            }
+        }
+        return reader;
+    }
+
+    /**
+     * Get the directory that is used by the lucene index. This method will
+     * return null if there is no index at the directory location. If we are
+     * using a RAM index, the directory will be a ram directory.
+     * 
+     * @return Directory The directory containing the index, or null if error.
+     */
+    public Directory getIndexDirectory()
+    {
+        if (useRAMIndex)
+        {
+            return fRAMindex;
+        }
+        else
+        {
+            return getFSDirectory(false);
+        }
+    }
+
+    private boolean indexExists()
+    {
+        return IndexReader.indexExists(indexDir);
+    }
+
+    Directory getFSDirectory(boolean delete)
+    {
+        Directory directory = null;
+
+        try
+        {
+            directory = FSDirectory.getDirectory(indexDir, delete);
+        }
+        catch (IOException e)
+        {
+            mLogger.error("Problem accessing index directory", e);
+        }
+
+        return directory;
+    }
+
+    private void createIndex(Directory dir)
+    {
+        IndexWriter writer = null;
+
+        try
+        {
+            writer = new IndexWriter(dir, IndexManagerImpl.getAnalyzer(), true);
+        }
+        catch (IOException e)
+        {
+            mLogger.error("Error creating index", e);
+        }
+        finally
+        {
+            try
+            {
+                if (writer != null)
+                {
+                    writer.close();
+                }
+            }
+            catch (IOException e)
+            {
+            }
+        }
+    }
+
+    private IndexOperation getSaveIndexOperation()
+    {
+        return new WriteToIndexOperation(this) {
+            public void doRun()
+            {
+                Directory dir = getIndexDirectory();
+                Directory fsdir = getFSDirectory(true);
+
+                IndexWriter writer = null;
+
+                try
+                {
+                    writer = new IndexWriter(fsdir, IndexManagerImpl
+                            .getAnalyzer(), true);
+
+                    writer.addIndexes(new Directory[] { dir });
+                    indexConsistencyMarker.delete();
+                }
+                catch (IOException e)
+                {
+                    mLogger.error("Problem saving index to disk", e);
+
+                    // Delete the directory, since there was a problem saving
+                    // the RAM contents
+                    getFSDirectory(true);
+                }
+                finally
+                {
+                    try
+                    {
+                        if (writer != null)
+                            writer.close();
+                    }
+                    catch (IOException e1)
+                    {
+                        mLogger.warn("Unable to close IndexWriter.");
+                    }
+                }
+
+            }
+        };
+    }
+
+    public void release() 
+    {
+        // no-op
+    }
+    
+    public void shutdown()
+    {
+        if (useRAMIndex)
+        {
+            scheduleIndexOperation(getSaveIndexOperation());
+        }
+        else
+        {
+            indexConsistencyMarker.delete();
+        }
+
+        try
+        {
+            if (reader != null)
+                reader.close();
+        }
+        catch (IOException e)
+        {
+            // won't happen, since it was
+        }
+    }
+}
\ No newline at end of file

Added: incubator/roller/trunk/src/org/apache/roller/business/PagePluginManagerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/trunk/src/org/apache/roller/business/PagePluginManagerImpl.java?rev=398712&view=auto
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/business/PagePluginManagerImpl.java (added)
+++ incubator/roller/trunk/src/org/apache/roller/business/PagePluginManagerImpl.java Mon May  1 15:23:02 2006
@@ -0,0 +1,155 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one or more
+*  contributor license agreements.  The ASF licenses this file to You
+* under the Apache License, Version 2.0 (the "License"); you may not
+* use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.  For additional information regarding
+* copyright in this work, please see the NOTICE file in the top level
+* directory of this distribution.
+*/
+/* Created on November 26, 2005, 9:04 AM */
+package org.apache.roller.business;
+
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.velocity.VelocityContext;
+import org.apache.velocity.context.Context;
+import org.apache.roller.config.RollerConfig;
+import org.apache.roller.model.PagePlugin;
+import org.apache.roller.model.PagePluginManager;
+import org.apache.roller.pojos.WeblogEntryData;
+import org.apache.roller.pojos.WebsiteData;
+import org.apache.roller.util.StringUtils;
+
+/**
+ * Centralized page plugin management.
+ * @author Dave Johnson
+ */
+public class PagePluginManagerImpl implements PagePluginManager {
+    
+    private static Log mLogger =
+            LogFactory.getFactory().getInstance(PagePluginManagerImpl.class);
+    
+    // Plugin classes keyed by plugin name
+    static Map mPagePlugins = new LinkedHashMap();
+    
+    /**
+     * Creates a new instance of PagePluginManagerImpl
+     */
+    public PagePluginManagerImpl() {
+        loadPagePluginClasses();
+    }
+    
+    public boolean hasPagePlugins() {
+        mLogger.debug("mPluginClasses.size(): " + mPagePlugins.size());
+        return (mPagePlugins != null && mPagePlugins.size() > 0);
+    }
+    
+    /**
+     * Initialize PagePlugins declared in roller.properties.
+     * By using the full class name we also allow for the implementation of
+     * "external" Plugins (maybe even packaged seperately). These classes are
+     * then later instantiated by PageHelper.
+     */
+    private void loadPagePluginClasses() {
+        mLogger.debug("Initializing page plugins");
+        
+        String pluginStr = RollerConfig.getProperty("plugins.page");
+        if (mLogger.isDebugEnabled()) mLogger.debug(pluginStr);
+        if (pluginStr != null) {
+            String[] plugins = StringUtils.stripAll(
+                    StringUtils.split(pluginStr, ",") );
+            for (int i=0; i<plugins.length; i++) {
+                if (mLogger.isDebugEnabled()) mLogger.debug("try " + plugins[i]);
+                try {
+                    Class pluginClass = Class.forName(plugins[i]);
+                    if (isPagePlugin(pluginClass)) {
+                        PagePlugin plugin = (PagePlugin)pluginClass.newInstance();
+                        mPagePlugins.put(plugin.getName(), pluginClass);
+                    } else {
+                        mLogger.warn(pluginClass + " is not a PagePlugin");
+                    }
+                } catch (ClassNotFoundException e) {
+                    mLogger.error("ClassNotFoundException for " + plugins[i]);
+                } catch (InstantiationException e) {
+                    mLogger.error("InstantiationException for " + plugins[i]);
+                } catch (IllegalAccessException e) {
+                    mLogger.error("IllegalAccessException for " + plugins[i]);
+                }
+            }
+        }
+    }
+
+    /**
+     * Create and init plugins for processing entries in a specified website. 
+     */
+    public Map createAndInitPagePlugins(
+            WebsiteData website,
+            Object servletContext,
+            String contextPath,
+            Context ctx) {
+        Map ret = new LinkedHashMap();
+        Iterator it = getPagePluginClasses().values().iterator();
+        while (it.hasNext()) {
+            try {
+                Class pluginClass = (Class)it.next();
+                PagePlugin plugin = (PagePlugin)pluginClass.newInstance();
+                plugin.init(website, servletContext, contextPath, ctx);
+                ret.put(plugin.getName(), plugin);
+            } catch (Exception e) {
+                mLogger.error("Unable to init() PagePlugin: ", e);
+            }
+        }
+        return ret;
+    }
+    
+    public String applyPagePlugins(
+        WeblogEntryData entry, Map pagePlugins, String str, boolean singleEntry) { 
+        String ret = str;
+        WeblogEntryData copy = new WeblogEntryData(entry);        
+        List entryPlugins = copy.getPluginsList();
+        if (entryPlugins != null && !entryPlugins.isEmpty()) {    
+            Iterator iter = entryPlugins.iterator();
+            while (iter.hasNext()) {
+                String key = (String)iter.next();
+                PagePlugin pagePlugin = (PagePlugin)pagePlugins.get(key);
+                if (pagePlugin != null) {
+                    if (!(singleEntry && pagePlugin.getSkipOnSingleEntry())) {
+                        ret = pagePlugin.render(entry, ret);
+                    }
+                } else {
+                    mLogger.error("ERROR: plugin not found: " + key);
+                }
+            }
+        }
+        return ret;
+    }
+    
+    private static boolean isPagePlugin(Class pluginClass) {
+        Class[] interfaces = pluginClass.getInterfaces();
+        for (int i=0; i<interfaces.length; i++) {
+            if (interfaces[i].equals(PagePlugin.class)) return true;
+        }
+        return false;
+    }
+    
+    private Map getPagePluginClasses() {
+        return mPagePlugins;
+    }
+    
+    public void release() {
+        // no op
+    }
+}

Added: incubator/roller/trunk/src/org/apache/roller/business/RollerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/trunk/src/org/apache/roller/business/RollerImpl.java?rev=398712&view=auto
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/business/RollerImpl.java (added)
+++ incubator/roller/trunk/src/org/apache/roller/business/RollerImpl.java Mon May  1 15:23:02 2006
@@ -0,0 +1,155 @@
+/*
+* Licensed to the Apache Software Foundation (ASF) under one or more
+*  contributor license agreements.  The ASF licenses this file to You
+* under the Apache License, Version 2.0 (the "License"); you may not
+* use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.  For additional information regarding
+* copyright in this work, please see the NOTICE file in the top level
+* directory of this distribution.
+*/
+/*
+ * RollerImpl.java
+ *
+ * Created on April 29, 2005, 5:33 PM
+ */
+package org.apache.roller.business;
+
+import java.sql.Connection;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.roller.RollerException;
+import org.apache.roller.business.referrers.ReferrerQueueManager;
+import org.apache.roller.business.referrers.ReferrerQueueManagerImpl;
+import org.apache.roller.business.utils.UpgradeDatabase;
+import org.apache.roller.model.FileManager;
+import org.apache.roller.model.IndexManager;
+import org.apache.roller.model.PagePluginManager;
+import org.apache.roller.model.Roller;
+import org.apache.roller.model.ThemeManager;
+import org.apache.roller.model.ThreadManager;
+
+
+/**
+ * The abstract version of the Roller implementation.
+ * Here we put code that pertains to *all* implementations of the Roller
+ * interface, regardless of their persistence strategy.
+ *
+ * @author Allen Gilliland
+ */
+public abstract class RollerImpl implements Roller {
+    
+    private static Log mLogger = LogFactory.getLog(RollerImpl.class);
+    
+    private FileManager fileManager = null;
+    private IndexManager indexManager = null;
+    private ThreadManager threadManager = null;
+    private ThemeManager themeManager = null;
+    private PagePluginManager pluginManager = null;
+    
+    
+    public RollerImpl() {
+        // nothing to do here yet
+    }
+    
+    
+    /**
+     * @see org.apache.roller.model.Roller#getFileManager()
+     */
+    public FileManager getFileManager() throws RollerException {
+        if (fileManager == null) {
+            fileManager = new FileManagerImpl();
+        }
+        return fileManager;
+    }
+    
+    
+    /**
+     * @see org.apache.roller.model.Roller#getThreadManager()
+     */
+    public ThreadManager getThreadManager() throws RollerException {
+        if (threadManager == null) {
+            threadManager = new ThreadManagerImpl();
+        }
+        return threadManager;
+    }
+    
+    
+    /**
+     * @see org.apache.roller.model.Roller#getIndexManager()
+     */
+    public IndexManager getIndexManager() throws RollerException {
+        if (indexManager == null) {
+            indexManager = new IndexManagerImpl();
+        }
+        return indexManager;
+    }
+    
+    
+    /**
+     * @see org.apache.roller.model.Roller#getThemeManager()
+     */
+    public ThemeManager getThemeManager() throws RollerException {
+        if (themeManager == null) {
+            themeManager = new ThemeManagerImpl();
+        }
+        return themeManager;
+    }
+    
+    
+    /**
+     * @see org.apache.roller.business.referrers.ReferrerQueueManager
+     */
+    public ReferrerQueueManager getReferrerQueueManager() {
+        return ReferrerQueueManagerImpl.getInstance();
+    }
+    
+    
+    /**
+     * @see org.apache.roller.model.Roller#getPluginManager()
+     */
+    public PagePluginManager getPagePluginManager() throws RollerException {
+        if (pluginManager == null) {
+            pluginManager = new PagePluginManagerImpl();
+        }
+        return pluginManager;
+    }
+    
+    
+    /**
+     * @see org.apache.roller.model.Roller#upgradeDatabase(java.sql.Connection)
+     */
+    public void upgradeDatabase(Connection con) throws RollerException {
+        UpgradeDatabase.upgradeDatabase(con);
+    }
+    
+    
+    public void release() {
+        try {
+            if (fileManager != null) fileManager.release();
+            if (threadManager != null) threadManager.release();
+            if (pluginManager != null) pluginManager.release();
+        } catch(Throwable e) {
+            mLogger.error("Error calling Roller.release()", e);
+        }
+    }
+    
+    
+    public void shutdown() {
+        try {
+            if (getReferrerQueueManager() != null) getReferrerQueueManager().shutdown();
+            if (indexManager != null) indexManager.shutdown();
+            if (threadManager != null) threadManager.shutdown();
+        } catch(Throwable e) {
+            mLogger.error("Error calling Roller.shutdown()", e);
+        }
+    }
+    
+}