Package: collective.purge_behaviors
============Introduction============A set of behaviors that are assignable to custom dexterity types for complex system setups. Assign the behaviorto a specific type to have it purge parents, children, siblings, or site root each time it is edited. This isan advanced product, so please do not use unless you fully understand the implications of caching.NOTE: The purge behaviors are additive. If you purge something that has a purge behavior on it, it will betriggered. If you are not careful, this could end in an infinite loop (e.g. purging parents on and itemthat purges siblings). There is no support to stop this use case at the moment. If someone wanted to add this,it would be very awesome of you. Otherwise, this will manifest as a max recursion error.Usage-----To use, add collective.purge_behaviors to the list of eggs in your plone site and then activate the behaviorin the dexterity control panel for the type that should exhibit the purge behavior.HINT: If these instructions don't make sense to you, you shouldn't be using this product.Purge Behaviors---------------This package provides 4 different kinds of purge behaviors. They are all triggered when an item isedited, NOT when they are added for the first time.*Parents*: When this item is edited, purge its parents, one level up. This calls the adapter for each parentso if the parents have the purge parent enabled as well, then it will keep going up the chain. This would beideal for a situation where you have a folder view that you want to aggressively cache, and anytime you adda new item to the folder you want that cache to be cleared. Think: news items.*Siblings*: When this item is edited, purge anything in the same folder as the item. If those items havepurge behaviors as well, they will be persisted. This is ideal for a custom view that lists the contents ofa parent folder in a portlet or something of that nature. Think: portlet and folder listings.*Contents*: When this item is edited, purge anything it is containing. If that item is not folderish (thatis, it implements IFolderish) then it will be bypassed for your safety. This is ideal for a custom view onthe contents of a folder that rely on properties from the containing folder.*Site Root*: When this item is edited, purge the site root. This is ideal for editing items that affect afront page display. For example, you add a custom donor type and there is a view on the front page thatlists new donors. This will purge the plain views and the folder_listing of root.Changelog=========0.2 (Unreleased)----------------0.1 (2013-08-12)----------------- Initial release.[eleddy]collective.purge_behaviors Copyright (c) 2012, eleddyAll rights reserved.Redistribution and use in source and binary forms, with or withoutmodification, are permitted provided that the following conditionsare met:1. Redistributions of source code must retain the above copyrightnotice, this list of conditions and the following disclaimer.2. Redistributions in binary form must reproduce the above copyrightnotice, this list of conditions and the following disclaimer in thedocumentation and/or other materials provided with the distribution.3. The name of the author may not be used to endorse or promote productsderived from this software without specific prior written permission.THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS ORIMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIESOF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUTNOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANYTHEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OFTHIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.