https://github.com/hypothermic/lightser
Lightser - Lightweight asynchronous serialization for Java
https://github.com/hypothermic/lightser
deserialization github gradle java library lightser maven serialization
Last synced: 2 months ago
JSON representation
Lightser - Lightweight asynchronous serialization for Java
- Host: GitHub
- URL: https://github.com/hypothermic/lightser
- Owner: hypothermic
- License: mit
- Created: 2018-05-18T06:03:02.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-05-18T06:25:15.000Z (about 8 years ago)
- Last Synced: 2026-04-13T16:40:39.137Z (2 months ago)
- Topics: deserialization, github, gradle, java, library, lightser, maven, serialization
- Language: Java
- Homepage:
- Size: 14.6 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Lightser
Lightweight Java library to make asynchronous serialization easier.
## Example
```java
int[] object = new int[] {0, 3, 6, 9};
Lightser.serialize(object, sample, new SerializeCallback() {
public void onSerializeSuccessful() {
System.out.println("Serialize success");
}
public void onSerializeFailed(Exception x) {
x.printStackTrace();
}
});
Lightser.deserialize(sample, new DeserializeCallback() {
public void onDeserializeSuccessful(Serializable ser) {
if (Arrays.toString((int[]) ser).equals("[0, 3, 6, 9]")) {
System.out.println("Deserialize success");
}
}
public void onDeserializeFailed(Exception x) {
x.printStackTrace();
}
});
```
## Maven dependency
```xml
lightser-mvn-repo
https://raw.github.com/hypothermic/lightser/mvn-repo/
nl.hypothermic
lightser
LATEST
```
## Gradle dependency
```gradle
repositories {
maven {
url "https://raw.github.com/hypothermic/lightser/mvn-repo/"
}
}
dependencies {
// Note: use 'api' instead of 'compile' if you're using Android Studio.
compile group: 'nl.hypothermic', name: 'lightser', version: '1.0.0-RELEASE'
}
```