aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarko Zajc <marko@zajc.eu.org>2023-04-02 01:29:00 +0200
committerMarko Zajc <marko@zajc.eu.org>2023-04-02 01:29:00 +0200
commit2922f6e9b9c0f11b50f78e405675db0bfb052e47 (patch)
tree160417c506316a9d0a8c426689479749f6fc28dc
parent556f60aa8577153b37f4f40f2ddaa3fdbb1d158f (diff)
Update README.md
-rw-r--r--README.md42
1 files changed, 21 insertions, 21 deletions
diff --git a/README.md b/README.md
index 0032071..22dfd70 100644
--- a/README.md
+++ b/README.md
@@ -5,16 +5,16 @@ A small project providing extensions and additions to Java 8's built-in function
5## Installation 5## Installation
6 6
7Add the following to your pom.xml's dependencies: 7Add the following to your pom.xml's dependencies:
8 8
9```xml 9```xml
10<dependencies> 10<dependencies>
11 ... 11 ...
12 <dependency> 12 <dependency>
13 <groupId>com.github.markozajc</groupId> 13 <groupId>com.github.markozajc</groupId>
14 <artifactId>extended-functions</artifactId> 14 <artifactId>extended-functions</artifactId>
15 <version>1.3</version> 15 <version>1.3</version>
16 </dependency> 16 </dependency>
17 ... 17 ...
18</dependencies> 18</dependencies>
19``` 19```
20 20
@@ -22,18 +22,18 @@ or your build.gradle:
22 22
23```groovy 23```groovy
24repositories { 24repositories {
25 ... 25 ...
26 mavenCentral() 26 mavenCentral()
27 ... 27 ...
28} 28}
29 29
30dependencies { 30dependencies {
31 ... 31 ...
32 api 'com.github.markozajc:extended-functions:1.3' 32 api 'com.github.markozajc:extended-functions:1.3'
33 ... 33 ...
34} 34}
35``` 35```
36 36
37## Usage 37## Usage
38 38
39Some of this project's additions do not extend Java 8's built-in functions and can therefore not be used directly with Java's APIs. However, those that do (specifically certain E\* and AE\* ones) can be through casting. For example, one can use: 39Some of this project's additions do not extend Java 8's built-in functions and can therefore not be used directly with Java's APIs. However, those that do (specifically certain E\* and AE\* ones) can be through casting. For example, one can use:
@@ -52,11 +52,11 @@ rather than the vanilla way of doing it:
52 52
53```java 53```java
54files.forEach(t -> { 54files.forEach(t -> {
55 try { 55 try {
56 Files.delete(t); 56 Files.delete(t);
57 } catch (IOException e) { 57 } catch (IOException e) {
58 // the error handling logic 58 // the error handling logic
59 } 59 }
60}); 60});
61``` 61```
62 62
@@ -68,7 +68,7 @@ It's also possible to handle exceptions in-line with `EHandle`:
68 68
69```java 69```java
70files.forEach(EHandle.handle(Files::delete, (f, t) -> { 70files.forEach(EHandle.handle(Files::delete, (f, t) -> {
71 // error handling logic 71 // error handling logic
72})); 72}));
73``` 73```
74 74