ftry

Functional wrapper for try-catch-finally

Лицензия

Лицензия

Группа

Группа

com.aegisql
Идентификатор

Идентификатор

ftry
Последняя версия

Последняя версия

1.0.3
Дата

Дата

Тип

Тип

jar
Описание

Описание

ftry
Functional wrapper for try-catch-finally
Ссылка на сайт

Ссылка на сайт

https://github.com/aegisql/ftry
Организация-разработчик

Организация-разработчик

AEGIS DATA SOLUTIONS, LLC
Система контроля версий

Система контроля версий

https://github.com/aegisql/ftry

Скачать ftry

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/com.aegisql/ftry/ -->
<dependency>
    <groupId>com.aegisql</groupId>
    <artifactId>ftry</artifactId>
    <version>1.0.3</version>
</dependency>
// https://jarcasting.com/artifacts/com.aegisql/ftry/
implementation 'com.aegisql:ftry:1.0.3'
// https://jarcasting.com/artifacts/com.aegisql/ftry/
implementation ("com.aegisql:ftry:1.0.3")
'com.aegisql:ftry:jar:1.0.3'
<dependency org="com.aegisql" name="ftry" rev="1.0.3">
  <artifact name="ftry" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.aegisql', module='ftry', version='1.0.3')
)
libraryDependencies += "com.aegisql" % "ftry" % "1.0.3"
[com.aegisql/ftry "1.0.3"]

Зависимости

compile (2)

Идентификатор библиотеки Тип Версия
junit : junit jar 4.11
org.slf4j : slf4j-api jar 1.7.5

test (2)

Идентификатор библиотеки Тип Версия
org.slf4j : slf4j-log4j12 jar 1.7.5
log4j : log4j jar 1.2.17

Модули Проекта

Данный проект не имеет модулей.

ftry

Functional wrapper for try-catch block in Java

Tutorial: https://github.com/aegisql/ftry/wiki

This is a fully functional analog of Java's

try {
   doSomething(); // this code can throw E1 or E2 or unchecked exceptions
} catch(E1 e1) {
   processE1();
} catch(E2 e2) {
   processE2();
} finally {
  finish();
}

Same code can be overwritten using the ftry library:

Try t = new Try(
   this::doSomething // this code can throw E1 or E2 or unchecked exceptions 
).orCatch(E1.class,
    e->processE1()
).orCatch(E2.class, 
    e->processE2()
).withFinal(
    this::finish()
);

boolean result = t.evaluator(Exception.class).eval();

Release history

1.0.2

bugfix, catch multiple exceptions with one ExceptionBlock

1.0.1

bugfixes, simplified evaluator interface

1.0.0

First release

maven dependency

<dependency>
    <groupId>com.aegisql</groupId>
    <artifactId>ftry</artifactId>
    <version>1.0.2</version>
</dependency>

Check for latest version at http://mvnrepository.com/artifact/com.aegisql/ftry

Версии библиотеки

Версия
1.0.3
1.0.2
1.0.1
1.0.0