Missed writing out an XML element end tag in your Java codes? You’re not alone. It is acceptable for small XML documents because spotting the erring codes is relatively easy. However, things may get very frustrating when writing huge XML
Run Java Codes Before Application Shutdown
This post shows how to run Java codes before an application shutdown. We can use this idea to clean up resources, notify remote systems or display a farewell message before the application completes its execution or terminates. Java Runtime Class
Spring – Multiple Names Or Aliases For A Bean
Sometimes we have use cases that require different codes to reference the same bean using other names or aliases. Fortunately, we can have one bean and give them multiple aliases in Spring. This post shows how to assign multiple names
Rust – Connect to PostgreSQL Database Using Crate
Is this your sudden foray into Rust? Although not totally for beginners, this post shows how to connect to a PostgreSQL database from Rust. Note that we have updated the content of this post to use a newer version of
Rust – How to check for NULL values
Rust does not support NULL; therefore, we don’t perform NULL checks on values. It does not even have keywords for NULL. However, it provides an enum Option that we can use similarly to Java 8 Optional. No NULL Check because
docker-compose.yml YAML for MariaDB Docker Container
This post shows how to create and use a docker-compose YAML file to generate a MariaDB Docker container with initial user accounts. First, we need to install Docker for Windows. Then, use its docker-compose to process our YAML file. We
Java – Convert LocalDateTime to OffsetDateTime in any timezone
This post shows how to convert a Java LocalDateTime object to an OffsetDateTime object at the current zone offset. For example, let’s say we are in Singapore and want to convert the current LocalDateTime to a string value. This string
Rust – Convert Integer to String Or Format Numeric Values
We can use the Rust functions to_string(), and format functions to format or convert integer values to string values. This post shows how to use these functions on each of Rust’s integer types. Rust Integer Types There are six (6)
Rust – Check if key exists in HashMap Examples
This post shows how to check if a key exists in a HashMap in Rust. As we know, Rust has the HashMap struct, which is part of its Collections library that we can use to store key-value pairs. Rust HashMap
Rust – How to get Keys and Values from HashMap
In Rust, we can store key and value pairs using HashMap. This post shows how to store and extract the keys and values from a HashMap using the functions iter(), keys(), values(), get(), and unwrap(). Store Test Data Into a