<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to HOWTO</title><link>https://sourceforge.net/p/clam4j/wiki/HOWTO/</link><description>Recent changes to HOWTO</description><atom:link href="https://sourceforge.net/p/clam4j/wiki/HOWTO/feed" rel="self"/><language>en</language><lastBuildDate>Fri, 21 Nov 2014 13:53:30 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/clam4j/wiki/HOWTO/feed" rel="self" type="application/rss+xml"/><item><title>HOWTO modified by Scott07uk</title><link>https://sourceforge.net/p/clam4j/wiki/HOWTO/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v6
+++ v7
@@ -63,6 +63,8 @@
 clam4jProps.setProperty(ClamManager.PROP_RUN_UPDATE, "true");
 clam4jProps.setProperty(ClamManager.PROP_UPDATE_FREQ_MIN, "60"); // Once every 60 minutes
 clam4jProps.setProperty(ClamManager.PROP_FRESHCLAM_PATH, "/path/to/freshclam/executable");
+//optionally set a callback so your application can be notified of freshclam runs
+clam4jProps.setProperty(ClamManager.PROP_FRESHCLAM_CALLBACK, "class.that.extends.FreshClamCallback");

 ClamManager.initalise(clam4jProps);
 ~~~~~~
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Scott07uk</dc:creator><pubDate>Fri, 21 Nov 2014 13:53:30 -0000</pubDate><guid>https://sourceforge.netda5ec35d84e6f1d6e3398f84bbcbe16c1746f452</guid></item><item><title>HOWTO modified by Scott07uk</title><link>https://sourceforge.net/p/clam4j/wiki/HOWTO/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v5
+++ v6
@@ -54,6 +54,7 @@
 Clam4j can help look after the Clam virus database too.  This is done by running the freshclam program on a defined schedule, you choose if you want this when you initalise Clam4j.  This is currently only supported where the clamd and your Java application are running on the same physical machine and the Java process can spawn freshclam in a way that allows it to update the virus database.

 To initalise Clam4j enabling freshclam you will need to do the following:
+
 ~~~~~~
 java.util.Properties clam4jProps = new java.util.Properties();

&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Scott07uk</dc:creator><pubDate>Sat, 14 Dec 2013 22:43:56 -0000</pubDate><guid>https://sourceforge.net06c34a744ea5dc09bd17ee4ddfec949e6a5d37f8</guid></item><item><title>HOWTO modified by Scott07uk</title><link>https://sourceforge.net/p/clam4j/wiki/HOWTO/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v4
+++ v5
@@ -46,3 +46,22 @@
   tEx.printStackTrace();
 }
 ~~~~~~
+
+
+More advanced initalisation
+---------------------------
+
+Clam4j can help look after the Clam virus database too.  This is done by running the freshclam program on a defined schedule, you choose if you want this when you initalise Clam4j.  This is currently only supported where the clamd and your Java application are running on the same physical machine and the Java process can spawn freshclam in a way that allows it to update the virus database.  
+
+To initalise Clam4j enabling freshclam you will need to do the following:
+~~~~~~
+java.util.Properties clam4jProps = new java.util.Properties();
+
+clam4jProps.setProperty(ClamManager.PROP_CLAMD_HOST, "localhost");
+clam4jProps.setProperty(ClamManager.PROP_CLAMD_PORT, "3310");
+clam4jProps.setProperty(ClamManager.PROP_RUN_UPDATE, "true");
+clam4jProps.setProperty(ClamManager.PROP_UPDATE_FREQ_MIN, "60"); // Once every 60 minutes
+clam4jProps.setProperty(ClamManager.PROP_FRESHCLAM_PATH, "/path/to/freshclam/executable");
+
+ClamManager.initalise(clam4jProps);
+~~~~~~
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Scott07uk</dc:creator><pubDate>Sat, 14 Dec 2013 22:43:36 -0000</pubDate><guid>https://sourceforge.net8b79f6379a99d4be855a9dc41241f4ea386cdea5</guid></item><item><title>HOWTO modified by Scott07uk</title><link>https://sourceforge.net/p/clam4j/wiki/HOWTO/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v3
+++ v4
@@ -18,3 +18,31 @@

 ClamManager.initalise(clam4jProps);
 ~~~~~~
+
+Thats is, Clam4j can now be used to scan for viruses
+
+Step Two
+--------
+Once Clam4j has been initalised, its usage is quite simple and can be done with:
+
+~~~~~~
+ClamScanner tScanner = new ClamScanner();
+
+try
+{
+  ClamScanResult tResult = tScanner.scanStream(pInputStream);
+  if (tResult.isThreadFound())
+  {
+    System.out.println("Virus [" + tResult.getThreatName() + "] detected!");
+  }
+  else
+  {
+    System.out.println("No threats found!");
+  }
+}
+catch (ClamException tEx)
+{
+  System.out.println("Oh Dear:" + tEx.toString());
+  tEx.printStackTrace();
+}
+~~~~~~
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Scott07uk</dc:creator><pubDate>Sat, 14 Dec 2013 22:37:46 -0000</pubDate><guid>https://sourceforge.netd746e01d09466c3aefa605fe7fafcdc59cfc3399</guid></item><item><title>HOWTO modified by Scott07uk</title><link>https://sourceforge.net/p/clam4j/wiki/HOWTO/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v2
+++ v3
@@ -8,4 +8,13 @@
 Step One
 --------

-The first step is to initalise Clam4j,
+The first step is to initalise Clam4j, this can be done with the following code:
+
+~~~~~~
+java.util.Properties clam4jProps = new java.util.Properties();
+
+clam4jProps.setProperty(ClamManager.PROP_CLAMD_HOST, "localhost");
+clam4jProps.setProperty(ClamManager.PROP_CLAMD_PORT, "3310");
+
+ClamManager.initalise(clam4jProps);
+~~~~~~
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Scott07uk</dc:creator><pubDate>Sat, 14 Dec 2013 22:31:14 -0000</pubDate><guid>https://sourceforge.net4e94d9113e87eeda1947ac5d7bbd9b75725ea308</guid></item><item><title>HOWTO modified by Scott07uk</title><link>https://sourceforge.net/p/clam4j/wiki/HOWTO/</link><description>&lt;div class="markdown_content"&gt;&lt;pre&gt;--- v1
+++ v2
@@ -1,8 +1,11 @@
-Welcome to your wiki!
+How to use
+==========

-This is the default page, edit it as you see fit. To add a new page simply reference it within brackets, e.g.: [SamplePage].
+Clam4j should be fairly simple to use in most java applications, there are two parts to getting clam4j to work.  

-The wiki uses [Markdown](/p/clam4j/wiki/markdown_syntax/) syntax.
+Clam4j is a wrapper around ClamAV, this means that ClamAV must already be installed and working (though there is no requirement for ClamAV and Clam4j to be running on the same machine).

-[[members limit=20]]
-[[download_button]]
+Step One
+--------
+
+The first step is to initalise Clam4j,
&lt;/pre&gt;
&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Scott07uk</dc:creator><pubDate>Sat, 14 Dec 2013 11:30:11 -0000</pubDate><guid>https://sourceforge.netcf42cca622e43f03e7bc687754eee2389cea4b59</guid></item><item><title>Home modified by Scott07uk</title><link>https://sourceforge.net/p/clam4j/wiki/Home/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;Welcome to your wiki!&lt;/p&gt;
&lt;p&gt;This is the default page, edit it as you see fit. To add a new page simply reference it within brackets, e.g.: &lt;span&gt;[SamplePage]&lt;/span&gt;.&lt;/p&gt;
&lt;p&gt;The wiki uses &lt;a class="" href="/p/clam4j/wiki/markdown_syntax/"&gt;Markdown&lt;/a&gt; syntax.&lt;/p&gt;
&lt;p&gt;&lt;h6&gt;Project Members:&lt;/h6&gt;
&lt;ul class="md-users-list"&gt;
&lt;li&gt;&lt;a href="/u/scott07uk/"&gt;Scott07uk&lt;/a&gt; (admin)&lt;/li&gt;
&lt;/ul&gt;&lt;br /&gt;
&lt;/p&gt;&lt;p&gt;&lt;span class="download-button-52abb59481b24b014846b99f" style="margin-bottom: 1em; display: block;"&gt;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Scott07uk</dc:creator><pubDate>Sat, 14 Dec 2013 01:34:13 -0000</pubDate><guid>https://sourceforge.net5158d421e15af8d4696d7266234129bc35262449</guid></item></channel></rss>