UserDatabase (Apache Tomcat 11.0.21 API Documentation)
Description: declaration: package: org.apache.catalina.startup, interface: UserDatabase

# Interface UserDatabase

All Known Implementing Classes:
  `HomesUserDatabase, PasswdUserDatabase`

public interface UserDatabase
Abstraction of the set of users defined by the operating system on the current server platform.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `getHome(String user)`
  `UserConfig`
  `getUserConfig()`
  `Enumeration<String>`
  `getUsers()`
  `void`
  `setUserConfig(UserConfig userConfig)`
  Set the UserConfig listener with which we are associated.

- ## Method Details

  - ### getUserConfig

    UserConfig getUserConfig()
    Returns:
      the UserConfig listener with which we are associated.

  - ### setUserConfig

    void setUserConfig(UserConfig userConfig)
    Set the UserConfig listener with which we are associated.
    Parameters:
      `userConfig` - The new UserConfig listener

  - ### getHome

    String getHome(String user)
    Parameters:
      `user` - User for which a home directory should be retrieved
    Returns:
      an absolute pathname to the home directory for the specified user.

  - ### getUsers

    Enumeration<String> getUsers()
    Returns:
      an enumeration of the usernames defined on this server.