Skip to content

Commit e89f631

Browse files
committed
updated
1 parent b2c239e commit e89f631

File tree

1 file changed

+21
-4
lines changed

1 file changed

+21
-4
lines changed

README.md

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,26 @@
11
[![License Apache 2.0](https://img.shields.io/badge/license-Apache%20License%202.0-green.svg)](http://www.apache.org/licenses/LICENSE-2.0)
2-
[![Maven central](https://maven-badges.herokuapp.com/maven-central/com.igormaznitsa/prologparser/badge.svg)](http://search.maven.org/#artifactdetails|com.igormaznitsa|prologparser|1.3.2|jar)
3-
[![Java 6.0+](https://img.shields.io/badge/java-6.0%2b-green.svg)](http://www.oracle.com/technetwork/java/javase/downloads/index.html)
4-
[![Android 2.0+](https://img.shields.io/badge/android-2.0%2b-green.svg)](http://developer.android.com/sdk/index.html)
2+
[![Maven central](https://maven-badges.herokuapp.com/maven-central/com.igormaznitsa/prologparser/badge.svg)](http://search.maven.org/#artifactdetails|com.igormaznitsa|prologparser|2.0.0|jar)
3+
[![Java 8.0+](https://img.shields.io/badge/java-8.0%2b-green.svg)](http://www.oracle.com/technetwork/java/javase/downloads/index.html)
54
[![PayPal donation](https://img.shields.io/badge/donation-PayPal-red.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=AHWJHJFBAWGL2)
65
[![Yandex.Money donation](https://img.shields.io/badge/donation-Я.деньги-yellow.svg)](http://yasobe.ru/na/iamoss)
76

87

9-
# Under very deep refactoring!
8+
# Preword
9+
10+
During my development of Java prolog engine (JProl) I had developed parser to parse sources written in Edinburgh style, I decided to extract the module into separated project and 1.0.0 version was published. In 2018 I had decided to make deep refactoring and 2.0.0 version was published. The Parser allows build custom prolog parsers with support of operators and some modern prolog features.
11+
12+
# Features
13+
14+
It supports
15+
- prolog operators
16+
- line and block commentaries
17+
- underline splitted numbers
18+
- curly blocks
19+
20+
# How to use?
21+
Parser implements stream which sequentially reads prolog terms from reader. By default PrologParser is abstract class but there is GenericPrologParser class provides minimalistic implementation.
22+
```
23+
Reader reader = new StringReader("hello(world). some({1,2,3}). power(X,Y,Z) :- Z is X ** Y.");
24+
PrologParser parser = new GenericPrologParser(reader, new DefaultParserContext(ParserContext.FLAG_CURLY_BRACKETS, Op.SWI));
25+
parser.forEach(System.out::println);
26+
```

0 commit comments

Comments
 (0)