java.lang.Object
io.github.eggy03.ferrumx.windows.service.user.UserService

public class UserService extends Object
Service class for fetching the current system user information.

This class retrieves the current user's details such as username, home directory, and working directory using standard Java system properties.

Usage example


 UserService userService = new UserService();
 User currentUser = userService.getUser();
 System.out.println(currentUser);
 
Since:
2.0.0
Author:
Egg-03
  • Constructor Details

    • UserService

      public UserService()
  • Method Details

    • getUser

      @NotNull public @NotNull User getUser()
      Retrieves the current system user information.
      Returns:
      a non-null User object containing the username, user home directory, and current working directory.