diff --git a/README.md b/README.md index ee383a5..9e39316 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ A lightweight library containing shared and generic utility classes for Java-bas ## 1) What is this repository for? ### 1.1) Quick summary -Version: `1.0.5` +Version: `1.0.6` **White_Utils** is a public Java library that provides standardized and generic utility classes to simplify common operations such as logging, formatting, and general helper functions across Java and Maven projects. It is published for public consumption and is also used as a standard within White Organization. @@ -25,7 +25,7 @@ WhiteUtils is designed to be as generic and dependency-minimal as possible so it mx.whiteweb.sdev white-utils - 1.0.5 + 1.0.6 ``` diff --git a/pom.xml b/pom.xml index ffa63ff..901b498 100644 --- a/pom.xml +++ b/pom.xml @@ -7,7 +7,7 @@ mx.whiteweb.sdev white-utils - 1.0.5 + 1.0.6 ${project.groupId}:${project.artifactId} A lightweight library containing shared and generic utility classes for Java-based projects. https://github.com/WhiteOrganization/white-utils diff --git a/src/main/java/org/white_sdev/utils/logging/WhiteLoggeable.java b/src/main/java/org/white_sdev/utils/logging/WhiteLoggeable.java index 0c16737..55b7643 100644 --- a/src/main/java/org/white_sdev/utils/logging/WhiteLoggeable.java +++ b/src/main/java/org/white_sdev/utils/logging/WhiteLoggeable.java @@ -1,5 +1,32 @@ package org.white_sdev.utils.logging; +/** + *

+ * Usage Sample: + *

+ * + *
{@code
+ * @Slf4j
+ * public class MyService implements WhiteLoggeable {
+ *     @Override
+ *     public org.slf4j.Logger getLogger() { return log; }
+ *
+ *     public void myProcess(String name, int age) {
+ *         // Method chaining is supported - all logging methods return LogContext
+ *         var log = withSignature("myProcess(name, age)")
+ *             .start("Processing user {} with age {}", name, age);
+ *
+ *         log.debug("User age is {}", age);
+ *         if (age < 18) {
+ *             log.warn("User {} is a minor", name);
+ *         }
+ *
+ *         log.info("User processed successfully")
+ *             .end("age is now {}", age);
+ *     }
+ * }
+ * }
+ */ @SuppressWarnings("unused") public interface WhiteLoggeable {