incubator-jspwiki-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Greg Kable (JIRA)" <j...@apache.org>
Subject [jira] Updated: (JSPWIKI-528) Rationalise the use of Collections, particularly with regard to pages
Date Sun, 03 May 2009 11:49:30 GMT

     [ https://issues.apache.org/jira/browse/JSPWIKI-528?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Greg Kable updated JSPWIKI-528:
-------------------------------

    Attachment: jspwiki-528-ContentManager.patch

Patch 10 - jspwiki-528-ContentManager.patch

Changes to ContentManager:
- Changed getAllPages to return a List instead of a collection
- Add new API getAllPagesSorted to return a sorted result
- Add new API and getAllpages( Collection result, String space ) allowing you to use custom
collections for results (e.g. a time sorted TreeSet)

Changes to PageManager
- Changed getAllPages to return a List instead of a Collection

Potential problem!!!!  When running the unit tests I saw at least one instance where the Priha
content manager returned a duplicate page name in a query result.  This is only visible when
using the List version of getAllPages because the Set will silently overwrite the duplicate.
 Unfortunately I couldn't reliably duplicate the problem and it completely went away with
the latest update.  It needs to be watched though.

Also, this is the last patch under this ticket.  It's getting too hard to track all of the
patches so I don't want to do anything more until all current patches are either committed
or rejected.

> Rationalise the use of Collections, particularly with regard to pages
> ---------------------------------------------------------------------
>
>                 Key: JSPWIKI-528
>                 URL: https://issues.apache.org/jira/browse/JSPWIKI-528
>             Project: JSPWiki
>          Issue Type: Improvement
>            Reporter: Greg Kable
>            Priority: Minor
>             Fix For: 3.0
>
>         Attachments: jspwiki-528-AbstractFilteredPlugin.patch, jspwiki-528-AttachmentHandler.patch,
jspwiki-528-ContentManager.patch, jspwiki-528-LinkCollector.patch, jspwiki-528-SearchProviders.patch,
jspwiki-528-Weblog.patch, jspwiki-528-WikiEngine-771034.patch, jspwiki-528-WikiEngine.patch,
jspwiki-528-WikiPage.patch, jspwiki-528-workflow.Step.patch
>
>
> Most of the APIs return Collection rather than a finer interface and in many cases these
collections are repeatedly repacked and resorted unnecessarily. I will go through all APIs
that return collections of pages and make them return a finer interface - probably List for
unordered collections and SortedSet for ordered collections. This will make the use of these
collections much clearer for further development and give us some opportunity for future optimisations.
> This is likely to be a very wide set of changes across lots of different classes so I'll
submit separate patches for each class.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message