Session manager that stores information obtained at run time.
Session manager that stores information obtained at run time. It allows different processes and threads to have access to this information. There are two types of session:
- Normal - disk storage
- Shared - storage in class data memory
- Add one of the options below to the pom.xml file:
<dependency>
<groupId>io.github.wniemiec-data-java</groupId>
<artifactId>session</artifactId>
<version>LATEST</version>
</dependency>
<dependency>
<groupId>wniemiec.data.java</groupId>
<artifactId>session</artifactId>
<version>LATEST</version>
</dependency>
- Run
$ mvn install
- Use it
[...]
import wniemiec.data.java.Session;
[...]
Pair<String, String> example = Pair.of("Hello", "World");
System.out.println( example.getFirst() + " " + example.getSecond() );
Method | Type | Description | Default |
---|---|---|---|
save{,shared} | key: String, value: Object: void |
Stores data in the current session. | - |
read{,shared} | key: String: Object |
Gets data from the current session. | - |
remove{,shared} | key: String: void |
Removes data from the current session. | - |
hasKey{,shared} | key: String: boolean |
Checks if there is data stored in the session with the specified key. | - |
destroy{,shared} | void: boolean |
Deletes the session. | - |
Details about each version are documented in the releases section.
See the documentation on how you can contribute to the project here.
Name | Type | Description |
---|---|---|
dist | Directory |
Released versions |
docs | Directory |
Documentation files |
src | Directory |
Source files |