https://github.com/cakemc-network/custom-properties
:book: cakemc's own file format for properties
https://github.com/cakemc-network/custom-properties
Last synced: 3 months ago
JSON representation
:book: cakemc's own file format for properties
- Host: GitHub
- URL: https://github.com/cakemc-network/custom-properties
- Owner: CakeMC-Network
- License: apache-2.0
- Created: 2024-10-15T21:33:01.000Z (7 months ago)
- Default Branch: develop
- Last Pushed: 2024-10-29T22:09:20.000Z (7 months ago)
- Last Synced: 2024-10-29T23:44:42.414Z (7 months ago)
- Language: Java
- Homepage:
- Size: 71.3 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.MD
- License: LICENSE
Awesome Lists containing this project
README
# Custom CakeMC file Format
this format is used for config files and properties````java
/**
* Main method to demonstrate the usage of CakeProperties.
*
* @param args command line arguments (unused)
*/
public static void main(String[] args) {
try {
CakeProperties cakeProperties = new CakeProperties("test.properties");// Add or update properties
cakeProperties.append("test.message.first", "1");
cakeProperties.append("test.message.second", "2");// Retrieve or create a new property
String value = cakeProperties.getOrCreate("test.message.third", "3");cakeProperties.append("owo.message.first", "test");
System.out.println("test.message.third = " + value);
} catch (IOException e) {
e.printStackTrace();
}
}
````the file created will look like this:
```
test.message
first = "1"
second = "2"
third = "3"owo.message
first = "test"```