Updated documentation.
[svjatoslav_commons.git] / doc / index.html
1 <!doctype html>
2 <html lang="en">
3 <head>
4 <title>Svjatoslav Commons - Java library of commonly used functions</title>
5 <!-- 2017-12-26 Tue 17:13 -->
6 <meta charset="utf-8">
7 <meta name="viewport" content="width=device-width, initial-scale=1">
8 <meta name="generator" content="Org-mode">
9 <meta name="author" content="Svjatoslav Agejenko">
10 <link href="https://bootswatch.com/4/darkly/bootstrap.min.css" rel="stylesheet">
11 <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
12 <script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.1/js/bootstrap.min.js"></script>"
13 <style type="text/css">
14 footer {background-color: #111 !important;}
15 pre {background-color: #111; color: #ccc;}
16 </style>
17 <style type="text/css">
18 /* org mode styles on top of twbs */
19
20 html {
21     position: relative;
22     min-height: 100%;
23 }
24
25 body {
26     font-size: 18px;
27     margin-bottom: 105px;
28 }
29
30 footer {
31     position: absolute;
32     bottom: 0;
33     width: 100%;
34     height: 101px;
35     background-color: #f5f5f5;
36 }
37
38 footer > div {
39     padding: 10px;
40 }
41
42 footer p {
43     margin: 0 0 5px;
44     text-align: center;
45     font-size: 16px;
46 }
47
48 #table-of-contents {
49     margin-top: 20px;
50     margin-bottom: 20px;
51 }
52
53 blockquote p {
54     font-size: 18px;
55 }
56
57 pre {
58     font-size: 16px;
59 }
60
61 .footpara {
62     display: inline-block;
63 }
64
65 figcaption {
66   font-size: 16px;
67   color: #666;
68   font-style: italic;
69   padding-bottom: 15px;
70 }
71
72 /* from twbs docs */
73
74 .bs-docs-sidebar.affix {
75     position: static;
76 }
77 @media (min-width: 768px) {
78     .bs-docs-sidebar {
79         padding-left: 20px;
80     }
81 }
82
83 /* All levels of nav */
84 .bs-docs-sidebar .nav > li > a {
85     display: block;
86     padding: 4px 20px;
87     font-size: 14px;
88     font-weight: 500;
89     color: #999;
90 }
91 .bs-docs-sidebar .nav > li > a:hover,
92 .bs-docs-sidebar .nav > li > a:focus {
93     padding-left: 19px;
94     color: #A1283B;
95     text-decoration: none;
96     background-color: transparent;
97     border-left: 1px solid #A1283B;
98 }
99 .bs-docs-sidebar .nav > .active > a,
100 .bs-docs-sidebar .nav > .active:hover > a,
101 .bs-docs-sidebar .nav > .active:focus > a {
102     padding-left: 18px;
103     font-weight: bold;
104     color: #A1283B;
105     background-color: transparent;
106     border-left: 2px solid #A1283B;
107 }
108
109 /* Nav: second level (shown on .active) */
110 .bs-docs-sidebar .nav .nav {
111     display: none; /* Hide by default, but at >768px, show it */
112     padding-bottom: 10px;
113 }
114 .bs-docs-sidebar .nav .nav > li > a {
115     padding-top: 1px;
116     padding-bottom: 1px;
117     padding-left: 30px;
118     font-size: 12px;
119     font-weight: normal;
120 }
121 .bs-docs-sidebar .nav .nav > li > a:hover,
122 .bs-docs-sidebar .nav .nav > li > a:focus {
123     padding-left: 29px;
124 }
125 .bs-docs-sidebar .nav .nav > .active > a,
126 .bs-docs-sidebar .nav .nav > .active:hover > a,
127 .bs-docs-sidebar .nav .nav > .active:focus > a {
128     padding-left: 28px;
129     font-weight: 500;
130 }
131
132 /* Nav: third level (shown on .active) */
133 .bs-docs-sidebar .nav .nav .nav {
134     padding-bottom: 10px;
135 }
136 .bs-docs-sidebar .nav .nav .nav > li > a {
137     padding-top: 1px;
138     padding-bottom: 1px;
139     padding-left: 40px;
140     font-size: 12px;
141     font-weight: normal;
142 }
143 .bs-docs-sidebar .nav .nav .nav > li > a:hover,
144 .bs-docs-sidebar .nav .nav .nav > li > a:focus {
145     padding-left: 39px;
146 }
147 .bs-docs-sidebar .nav .nav .nav > .active > a,
148 .bs-docs-sidebar .nav .nav .nav > .active:hover > a,
149 .bs-docs-sidebar .nav .nav .nav > .active:focus > a {
150     padding-left: 38px;
151     font-weight: 500;
152 }
153
154 /* Show and affix the side nav when space allows it */
155 @media (min-width: 992px) {
156     .bs-docs-sidebar .nav > .active > ul {
157         display: block;
158     }
159     /* Widen the fixed sidebar */
160     .bs-docs-sidebar.affix,
161     .bs-docs-sidebar.affix-bottom {
162         width: 213px;
163     }
164     .bs-docs-sidebar.affix {
165         position: fixed; /* Undo the static from mobile first approach */
166         top: 20px;
167     }
168     .bs-docs-sidebar.affix-bottom {
169         position: absolute; /* Undo the static from mobile first approach */
170     }
171     .bs-docs-sidebar.affix .bs-docs-sidenav,.bs-docs-sidebar.affix-bottom .bs-docs-sidenav {
172         margin-top: 0;
173         margin-bottom: 0
174     }
175 }
176 @media (min-width: 1200px) {
177     /* Widen the fixed sidebar again */
178     .bs-docs-sidebar.affix-bottom,
179     .bs-docs-sidebar.affix {
180         width: 263px;
181     }
182 }
183 </style>
184 <script type="text/javascript">
185 $(function() {
186     'use strict';
187
188     $('.bs-docs-sidebar li').first().addClass('active');
189
190     $(document.body).scrollspy({target: '.bs-docs-sidebar'});
191
192     $('.bs-docs-sidebar').affix();
193 });
194 </script>
195 </head>
196 <body>
197 <div id="content" class="container">
198 <div class="row"><div class="col-md-9"><h1 class="title">Svjatoslav Commons - Java library of commonly used functions</h1>
199 <hr >
200 <ul class="org-ul">
201 <li><a href="http://www2.svjatoslav.eu/gitweb/?p=svjatoslav_commons.git;a=snapshot;h=HEAD;sf=tgz">download latest snapshot</a>
202 </li>
203
204 <li>This program is free software; you can redistribute it and/or modify
205 it under the terms of version 3 of the <a href="https://www.gnu.org/licenses/lgpl.html">GNU Lesser General Public
206 License</a> or later as published by the Free Software Foundation.
207 </li>
208
209 <li>Program author:
210 <ul class="org-ul">
211 <li>Svjatoslav Agejenko
212 </li>
213 <li>Homepage: <a href="http://svjatoslav.eu">http://svjatoslav.eu</a>
214 </li>
215 <li>Email: <a href="mailto://svjatoslav@svjatoslav.eu">mailto://svjatoslav@svjatoslav.eu</a>
216 </li>
217 </ul>
218 </li>
219
220 <li><a href="http://www.svjatoslav.eu/programs.jsp">other applications hosted at svjatoslav.eu</a>
221 </li>
222 </ul>
223
224 <div id="outline-container-sec-1" class="outline-2">
225 <h2 id="sec-1"><span class="section-number-2">1</span> Library contents</h2>
226 <div class="outline-text-2" id="text-1">
227 <ul class="org-ul">
228 <li>Commandline Interface helper
229 <pre class="example">
230 eu.svjatoslav.commons.commandline.CLIHelper
231 </pre>
232 </li>
233
234 <li>Commandline arguments parser and validator.
235 <pre class="example">
236 eu.svjatoslav.commons.commandline.parameterparser
237 </pre>
238 </li>
239
240 <li>Bit input and output streams.
241 <pre class="example">
242 eu.svjatoslav.commons.data.BitInputStream
243 eu.svjatoslav.commons.data.BitOutputStream
244 </pre>
245 </li>
246
247 <li>Slightly enhanced data input and output streams.
248 <pre class="example">
249 eu.svjatoslav.commons.data.EnhancedDataInputStream
250 eu.svjatoslav.commons.data.EnhancedDataOutputStream
251 </pre>
252 </li>
253
254 <li>Byte array to HEX string converter.
255 <pre class="example">
256 eu.svjatoslav.commons.data.HexConverter
257 </pre>
258 </li>
259
260 <li>Utility that tries to quess user desktop directory. (Quite ugly and
261 unreliable. Better solution is needed.)
262 <pre class="example">
263 eu.svjatoslav.commons.file.CommonPathResolver
264 </pre>
265 </li>
266
267 <li>File path parser.
268 <pre class="example">
269 eu.svjatoslav.commons.file.FilePathParser
270 </pre>
271 </li>
272
273 <li>File IO helper.
274 <pre class="example">
275 eu.svjatoslav.commons.file.IOHelper
276 </pre>
277 </li>
278
279 <li>Graphical error dialog.
280 <ul class="org-ul">
281 <li>Reusable graphical dialog to capture and show program exceptions
282 and associated program call stack traceback.
283 <pre class="example">
284 eu.svjatoslav.commons.gui.dialog.ExceptionDialog
285 </pre>
286 </li>
287 </ul>
288 </li>
289
290 <li>Primitive and simple component to add navigation menus to the web
291 sites.
292 <pre class="example">
293 eu.svjatoslav.commons.network.navigation
294 </pre>
295 </li>
296
297 <li>String tokenizer.
298 <pre class="example">
299 eu.svjatoslav.commons.string.tokenizer
300 </pre>
301 </li>
302
303 <li>Improved String, optimized for dealing with prefixes and suffixes.
304 <pre class="example">
305 eu.svjatoslav.commons.string.String2
306 </pre>
307 </li>
308
309 <li>Wildcards matcher. (?, *)
310 <pre class="example">
311 eu.svjatoslav.commons.string.WildCardMatcher#match
312 </pre>
313 </li>
314 </ul>
315 </div>
316 </div>
317
318 <div id="outline-container-sec-2" class="outline-2">
319 <h2 id="sec-2"><span class="section-number-2">2</span> Usage</h2>
320 <div class="outline-text-2" id="text-2">
321 <p>
322 Instructions to embed svjatoslav-commons in your project as a library:
323 </p>
324
325 <p>
326 Maven pom.xml file snippet:
327 </p>
328
329 <div class="org-src-container">
330
331 <pre class="src src-xml">&lt;<span style="color: #A6E22E;">dependencies</span>&gt;
332     ...
333     &lt;<span style="color: #A6E22E;">dependency</span>&gt;
334         &lt;<span style="color: #A6E22E;">groupId</span>&gt;eu.svjatoslav&lt;/<span style="color: #A6E22E;">groupId</span>&gt;
335         &lt;<span style="color: #A6E22E;">artifactId</span>&gt;svjatoslavcommons&lt;/<span style="color: #A6E22E;">artifactId</span>&gt;
336         &lt;<span style="color: #A6E22E;">version</span>&gt;1.7&lt;/<span style="color: #A6E22E;">version</span>&gt;
337     &lt;/<span style="color: #A6E22E;">dependency</span>&gt;
338     ...
339 &lt;/<span style="color: #A6E22E;">dependencies</span>&gt;
340
341
342 &lt;<span style="color: #A6E22E;">repositories</span>&gt;
343     ...
344     &lt;<span style="color: #A6E22E;">repository</span>&gt;
345         &lt;<span style="color: #A6E22E;">id</span>&gt;svjatoslav.eu&lt;/<span style="color: #A6E22E;">id</span>&gt;
346         &lt;<span style="color: #A6E22E;">name</span>&gt;Svjatoslav repository&lt;/<span style="color: #A6E22E;">name</span>&gt;
347         &lt;<span style="color: #A6E22E;">url</span>&gt;http://www2.svjatoslav.eu/maven/&lt;/<span style="color: #A6E22E;">url</span>&gt;
348     &lt;/<span style="color: #A6E22E;">repository</span>&gt;
349     ...
350 &lt;/<span style="color: #A6E22E;">repositories</span>&gt;
351 </pre>
352 </div>
353 </div>
354 </div>
355 </div><div class="col-md-3"><nav id="table-of-contents">
356 <div id="text-table-of-contents" class="bs-docs-sidebar">
357 <ul class="nav">
358 <li><a href="#sec-1">1. Library contents</a></li>
359 <li><a href="#sec-2">2. Usage</a></li>
360 </ul>
361 </div>
362 </nav>
363 </div></div></div>
364 <footer id="postamble" class="">
365 <div><p class="author">Author: Svjatoslav Agejenko</p>
366 <p class="date">Created: 2017-12-26 Tue 17:13</p>
367 <p class="creator"><a href="http://www.gnu.org/software/emacs/">Emacs</a> 25.1.1 (<a href="http://orgmode.org">Org-mode</a> 8.2.10)</p>
368 </div>
369 </footer>
370 </body>
371 </html>