Skip to content

Commit

Permalink
Update and correct readme
Browse files Browse the repository at this point in the history
  • Loading branch information
termermc committed Apr 7, 2020
1 parent 572c3fd commit f1b0c67
Showing 1 changed file with 18 additions and 5 deletions.
23 changes: 18 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
# TCPacketProtocol
Packet protocol supporting packet replies and a simple API

# WIP
Work in progress. Run `./gradlew build` to build.

# What is it
This is a simple library implementing a basic packet protocol in an easy and event-based way.
You can receive messages and reply to them with a simple API, and reduce TCP server development time.
Expand All @@ -29,7 +26,7 @@ TCPacketClient client = TCPacketClient(9006);
client.connect();

Packet message = new Packet()
.withBody("Ping!")
.body("Ping!");

client.send(message, (reply, timedOut) -> {
if(timedOut) {
Expand All @@ -38,4 +35,20 @@ client.send(message, (reply, timedOut) -> {
System.out.println("Got reply: "+reply.bodyAsString());
}
});
```
```

# Features
Here's a list of all features in TCPacketProtocol:

- Simple and efficient packet structure
- Repliable packets with callbacks
- Managed threading
- Works with Java 8 lambdas
- Fluent API

# Getting it
Download the JAR library from the releases tab, or compile the library using Gradle.

# Compiling
Download or clone the repository, and run either `gradlew.bat` (Windows), or `./gradlew` (OSX, Linux, Unix).
If all goes well, the library will be in `build/libs/`.

0 comments on commit f1b0c67

Please sign in to comment.