<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://wiki.logicaldoc.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Document_Pre%2FPost_Processing</id>
	<title>Document Pre/Post Processing - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://wiki.logicaldoc.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Document_Pre%2FPost_Processing"/>
	<link rel="alternate" type="text/html" href="http://wiki.logicaldoc.com/wiki/index.php?title=Document_Pre/Post_Processing&amp;action=history"/>
	<updated>2026-06-06T09:47:20Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.1</generator>
	<entry>
		<id>http://wiki.logicaldoc.com/wiki/index.php?title=Document_Pre/Post_Processing&amp;diff=150&amp;oldid=prev</id>
		<title>87.29.232.99 at 13:58, 25 November 2008</title>
		<link rel="alternate" type="text/html" href="http://wiki.logicaldoc.com/wiki/index.php?title=Document_Pre/Post_Processing&amp;diff=150&amp;oldid=prev"/>
		<updated>2008-11-25T13:58:11Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Some analisys sessions in various organizations where LogicalDOC was adopted, reported that it would be useful to add some kind of logic during the document storage procedure.&amp;lt;br&amp;gt;&lt;br /&gt;
For example a common need is to have a customizable numeration of inserted documents.&lt;br /&gt;
The idea is to define a new extension point in the core plug-in that can be extended by custom plug-ins in order to provide specific logic before and after a document is saved into the database.&lt;br /&gt;
&lt;br /&gt;
Basically if a client wants to interact with the store procedure it must implement an interface like this:&lt;br /&gt;
&amp;lt;source lang=&amp;quot;java&amp;quot; line=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
public interface DocumentListener {&lt;br /&gt;
	/**&lt;br /&gt;
	 * Called before a document is stored in the database&lt;br /&gt;
	 * &lt;br /&gt;
	 * @param document The document to be stored&lt;br /&gt;
	 * @param dictionary Dictionary of the execution pipeline&lt;br /&gt;
	 */&lt;br /&gt;
	public void beforeStore(Document document, Map&amp;lt;String, Object&amp;gt; dictionary);&lt;br /&gt;
&lt;br /&gt;
	/**&lt;br /&gt;
	 * Called after a document is stored in the database&lt;br /&gt;
	 * &lt;br /&gt;
	 * @param document The document to be stored&lt;br /&gt;
	 * @param dictionary Dictionary of the execution pipeline&lt;br /&gt;
	 */&lt;br /&gt;
	public void afterStore(Document document, Map&amp;lt;String, Object&amp;gt; dictionary);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Each time a document is stored, all enlisted listeners are notified and each listener can do a particular job. A convenient dictionary map can be passed through the execution chain so that one listener can share informations with others.&lt;br /&gt;
The extension point must define the implementation class and a position so that this can be used to choose the right notification order.&lt;/div&gt;</summary>
		<author><name>87.29.232.99</name></author>
	</entry>
</feed>