-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathfaq.html
executable file
·359 lines (348 loc) · 21.8 KB
/
faq.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- Generated by Apache Maven Doxia Site Renderer 1.3 at May 19, 2012 -->
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>op4j: bending the Java spoon - Frequently Asked Questions</title>
<style type="text/css" media="all">
@import url("./css/maven-base.css");
@import url("./css/maven-theme.css");
@import url("./css/site.css");
</style>
<link rel="stylesheet" href="./css/print.css" type="text/css" media="print" />
<meta name="Date-Revision-yyyymmdd" content="20120519" />
<meta http-equiv="Content-Language" content="en" />
</head>
<body class="composite">
<div id="banner">
<a href="./" id="bannerLeft">
<img src="images/op4j_logo.png" alt="op4j: bending the Java spoon" />
</a>
<div class="clear">
<hr/>
</div>
</div>
<div id="breadcrumbs">
<div class="xleft">
<span id="publishDate">Last Published: 19 May 2012</span>
| <span id="projectVersion">Version: 1.2</span>
</div>
<div class="xright"> <a href="index.html" title="Main">Main</a>
|
<a href="download.html" title="Download">Download</a>
|
<a href="https://www.bendingthejavaspoon.com" class="externalLink" title="Example Recipes Blog">Example Recipes Blog</a>
|
<a href="https://github.com/op4j/op4j.github.com/issues" class="externalLink" title="Issue Tracking">Issue Tracking</a>
|
<a href="apidocs/index.html" title="Javadoc">Javadoc</a>
|
<a href="https://github.com/op4j" class="externalLink" title="Github Project Page">Github Project Page</a>
</div>
<div class="clear">
<hr/>
</div>
</div>
<div id="leftColumn">
<div id="navcolumn">
<h5>The op4j Project</h5>
<ul>
<li class="none">
<a href="index.html" title="· Main">· Main</a>
</li>
<li class="none">
<a href="download.html" title="· Download">· Download</a>
</li>
<li class="none">
<a href="maveninfo.html" title="· Maven Info">· Maven Info</a>
</li>
<li class="none">
<a href="dependencies.html" title="· Dependencies">· Dependencies</a>
</li>
<li class="none">
<a href="https://github.com/op4j" class="externalLink" title="· Github Repository">· Github Repository</a>
</li>
<li class="none">
<a href="https://www.bendingthejavaspoon.com" class="externalLink" title="· Example Recipes">· Example Recipes</a>
</li>
<li class="none">
<a href="https://github.com/op4j/op4j.github.com/issues" class="externalLink" title="· Issue Tracking">· Issue Tracking</a>
</li>
<li class="expanded">
<a href="#" title="· Documentation">· Documentation</a>
<ul>
<li class="none">
<a href="basics.html" title="· The Basics">· The Basics</a>
</li>
<li class="expanded">
<a href="#" title="· Working with...">· Working with...</a>
<ul>
<li class="none">
<a href="arrays.html" title="· Arrays">· Arrays</a>
</li>
<li class="none">
<a href="lists.html" title="· Lists">· Lists</a>
</li>
<li class="none">
<a href="maps.html" title="· Maps">· Maps</a>
</li>
<li class="none">
<a href="sets.html" title="· Sets">· Sets</a>
</li>
<li class="none">
<a href="generic.html" title="· Any object (generic)">· Any object (generic)</a>
</li>
</ul>
</li>
<li class="expanded">
<a href="#" title="· Functions">· Functions</a>
<ul>
<li class="none">
<a href="functions.html" title="· About Functions">· About Functions</a>
</li>
<li class="none">
<a href="call.html" title="· Call">· Call</a>
</li>
<li class="none">
<a href="get.html" title="· Get">· Get</a>
</li>
<li class="none">
<a href="fnfunc.html" title="· FnFunc">· FnFunc</a>
</li>
<li class="none">
<a href="fnboolean.html" title="· FnBoolean">· FnBoolean</a>
</li>
<li class="none">
<a href="fncalendar.html" title="· FnCalendar">· FnCalendar</a>
</li>
<li class="none">
<a href="fndate.html" title="· FnDate">· FnDate</a>
</li>
<li class="none">
<a href="fnobject.html" title="· FnObject">· FnObject</a>
</li>
<li class="none">
<a href="fnstring.html" title="· FnString">· FnString</a>
</li>
<li class="expanded">
<a href="#" title="· Numbers">· Numbers</a>
<ul>
<li class="none">
<a href="fnnumber.html" title="· FnNumber">· FnNumber</a>
</li>
<li class="none">
<a href="fnbigdecimal.html" title="· FnBigDecimal">· FnBigDecimal</a>
</li>
<li class="none">
<a href="fnbiginteger.html" title="· FnBigInteger">· FnBigInteger</a>
</li>
<li class="none">
<a href="fninteger.html" title="· FnInteger">· FnInteger</a>
</li>
<li class="none">
<a href="fnlong.html" title="· FnLong">· FnLong</a>
</li>
<li class="none">
<a href="fnfloat.html" title="· FnFloat">· FnFloat</a>
</li>
<li class="none">
<a href="fndouble.html" title="· FnDouble">· FnDouble</a>
</li>
<li class="none">
<a href="fndouble.html" title="· FnShort">· FnShort</a>
</li>
</ul>
</li>
<li class="expanded">
<a href="#" title="· Structures">· Structures</a>
<ul>
<li class="none">
<a href="fnarray.html" title="· FnArray">· FnArray</a>
</li>
<li class="none">
<a href="fnlist.html" title="· FnList">· FnList</a>
</li>
<li class="none">
<a href="fnmap.html" title="· FnMap">· FnMap</a>
</li>
<li class="none">
<a href="fnset.html" title="· FnSet">· FnSet</a>
</li>
<li class="none">
<a href="fntuple.html" title="· FnTuple">· FnTuple</a>
</li>
</ul>
</li>
</ul>
</li>
<li class="none">
<a href="apidocs/op4j/index.html" title="· Javadoc">· Javadoc</a>
</li>
<li class="none">
<strong>· FAQ</strong>
</li>
</ul>
</li>
<li class="none">
<a href="license.html" title="· License">· License</a>
</li>
<li class="none">
<a href="team.html" title="· Team">· Team</a>
</li>
</ul>
<ul>
<li class="collapsed">
<a href="ognl-about.html" title="· op4j-ognl">· op4j-ognl</a>
</li>
<li class="collapsed">
<a href="jodatime-about.html" title="· op4j-jodatime">· op4j-jodatime</a>
</li>
</ul>
<a href="https://maven.apache.org" title="Built with Maven 2" class="poweredBy">
<img class="poweredBy" alt="Built with Maven 2" src="https://maven.apache.org/images/logos/maven-feather.png" />
</a>
</div>
</div>
<div id="bodyColumn">
<div id="contentBox">
<div class="section"><h2><a name="top">Frequently Asked Questions</a><a name="Frequently_Asked_Questions"></a></h2><p><b>About op4j</b></p><ol style="list-style-type: decimal"><li><a href="#where-does-op4-come-from">Where does op4j come from? Is it made or backed by any software company?</a></li><li><a href="#why-do-you-pronounce-it-opah">Why do you pronounce it ['op-ah]?</a></li><li><a href="#why-bending-the-java-spoon">Bending the Java spoon? Is this a kind of magic?</a></li><li><a href="#what-is-relation-javaruntype">What is javaRuntype's relation to the op4j project?</a></li><li><a href="#does-op4j-offer-commercial-support">Does op4j offer any type of commercial support?</a></li><li><a href="#contribute">How can I contribute to op4j?</a></li></ol><p><b>General</b></p><ol style="list-style-type: decimal"><li><a href="#what-is-op4j-useful-for">What is op4j useful for?</a></li><li><a href="#where-can-I-find-examples">Despite having read all your documentation, I still cannot imagine what is this thing useful for. Where can I find some usage examples?</a></li><li><a href="#will-op4j-be-obsolete">Will op4j be obsolete when Java 7 arrives?</a></li><li><a href="#can-I-use-only-functions">I'm not interested in your fancy-styled chained operators, but I love some functions here. Can I still use op4j?</a></li></ol></div><div class="section"><h2>About op4j<a name="About_op4j"></a></h2><dl><dt><a name="where-does-op4-come-from">Where does op4j come from? Is it made or backed by any software company?</a></dt><dd>
<p>
op4j is Open Source Software created by a Spanish Software Engineer
called <a href="team.html">Daniel Fernández</a> with help from another Spanish
Software Engineer called <a href="team.html">Soraya Sánchez</a> in their spare time.
</p>
<p>
It is neither made nor backed
by any software (or any other type of) company, and it is offered to the public
totally free of charge, both in binary and in source code forms, under the <b>Apache License 2.0</b>.
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="why-do-you-pronounce-it-opah">Why do you pronounce it ['op-ah]?</a></dt><dd>
<p>
Why not?
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="why-bending-the-java-spoon">Bending the Java spoon? Is this a kind of magic?</a></dt><dd>
<p>
Yes, it's a kind of magic ;-).
</p>
<p>
The biggest problem for op4j is, strange as it seems, Java. During the long and
painful development of the op4j concept, the authors felt they were achieving things that
Java was simply not designed for. Java is terrific and we love it, but it is a highly
bureaucratic language, strongly and statically typed, and it has been patched several
times over the years in order to acquire some modern features with the requirement
of not leaving legacy code behind -which has lead to some terrifying creatures like the
current <i>Generics</i> implementation-. In this scenario, trying to bring to Java
features (or more accurately, coding styles) which belonged more in the functional
and dynamic programming worlds was really difficult.
</p>
<p>
This is why, realising that they were curling and twisting the language, pushing it
to its limits and extracting every drop of juice it had to give, the authors felt
like being bending the Java spoon. And that is what the +40K lines of code in
op4j are about.
</p>
<p>
But it was worth it, wasn't it?
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="what-is-relation-javaruntype">What is javaRuntype's relation to the op4j project?</a></dt><dd>
<p>
javaRuntype [<a class="externalLink" href="https://www.javaruntype.org">https://www.javaruntype.org</a>] was conceived at first as a part of the op4j project,
and by the same person who created op4j itself, but later during op4j's development it was decided that javaRuntype should be a project
of its own as its range of application by separate was in fact quite broad.
</p>
<p>
So, javaRuntype remains today as a useful and required dependency for op4j, but it can also
be used without op4j at all for several different purposes.
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="does-op4j-offer-commercial-support">Does op4j offer any type of commercial support?</a></dt><dd>
<p>
No, it does not.
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="contribute">How can I contribute to op4j?</a></dt><dd>
<p>
In many ways:
</p>
<ul>
<li>You can write to the <a href="team.html">Team</a> with your ideas for improving op4j.</li>
<li>You can contribute some code, write a patch for a new feature
or behaviour (please, tell the project admins first about your idea so
that effort can be correctly coordinated).</li>
<li>You can write articles, reviews, blog posts, etc. about op4j, showing
how it works or how it integrates with other technologies.</li>
<li>You can promote op4j in your company/work and among your colleague developers.</li>
</ul>
<p>
If you want to contribute some code to op4j, please read first the
page on <a href="contributing.html">Contributing to op4j</a>.
</p>
<p align="right"><a href="#top">[top]</a></p></dd></dl></div><div class="section"><h2>General<a name="General"></a></h2><dl><dt><a name="what-is-op4j-useful-for">What is op4j useful for?</a></dt><dd>
<p>
op4j is mainly useful for developers. We say it is a <b>developer happiness tool</b> because
its aim is to enable developers to create cleaner and more readable java code, especially
auxiliary code (data conversions, structure managing, etc). In order to achieve this,
op4j builds on the
<i><a class="externalLink" href="http://martinfowler.com/bliki/FluentInterface.html">Fluent Interface</a></i>
concept and also provides a huge set of predefined functions which enable developers to
perform everyday tasks in an elegant and simple manner.
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="where-can-I-find-examples">Despite having read all your documentation, I still cannot imagine what is this thing useful for. Where can I find some usage examples?</a></dt><dd>
<p>
First of all, congratulations on having read all the docs, you are really brave ;-).
</p>
<p>
The op4j authors maintain a blog with <i>example recipes</i> which can show you some practical
examples and give you ideas for using op4j. It is called <b>Bending the Java spoon</b> and
it can be reached at <a class="externalLink" href="https://www.bendingthejavaspoon.com">https://www.bendingthejavaspoon.com</a>.
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="will-op4j-be-obsolete">Will op4j be obsolete when Java 7 arrives?</a></dt><dd>
<p>
Well, obviously if the authors believed that, we wouldn't have been working on op4j for the
last couple of years ;-). The answer is <b>no</b>.
</p>
<p>
We have heard this comment a couple of times, always coming from people who see op4j as a
library for creating <i>closures</i>, which it is not. Function expressions are a nice
feature in op4j but -besides not being completely comparable to closures (just similar in concept)-
creating functions is not the main objective of the library (although it is a nice one).
</p>
<p>
op4j tries to bring Java a little bit closer to the dynamicity of other languages by
enabling coding styles more similar to the <i>fluency</i> of some functional
languages, something we believe will not be a Java 7 feature. As will not be the several
hundreds of functions for everyday tasks op4j provides out-of-the-box.
</p>
<p>
And even more: op4j works with Java version 1.5 or higher whereas Java 7's new features
will only work with... well, Java 7 ;-)
</p>
<p align="right"><a href="#top">[top]</a></p><hr /></dd><dt><a name="can-I-use-only-functions">I'm not interested in your fancy-styled chained operators, but I love some functions here. Can I still use op4j?</a></dt><dd>
<p>
Absolutely! We understand that chained operation expressions are the trendiest and
most <i>modern</i> feature in op4j (in the authors' opinion), but in fact that is just one of the
two big features in op4j. The other one is, of course, <b>functions</b>. op4j includes several
hundred powerful functions which can be used directly without ever creating any kind
of chained expression, and we'd love you to use them that way, if that is what you prefer.
</p>
<p>
Just have a look at, for example, the amazing functions in
<a class="externalLink" href="https://www.op4j.org/fnstring.html"><tt>FnString</tt></a>. Great time-saving functions,
ready to be used!
</p>
<p align="right"><a href="#top">[top]</a></p></dd></dl></div>
</div>
</div>
<div class="clear">
<hr/>
</div>
<div id="footer">
<div class="xright">
Copyright © 2012
<a href="https://www.op4j.org">The OP4J team</a>.
All Rights Reserved.
</div>
<div class="clear">
<hr/>
</div>
</div>
</body>
</html>