Class DotenvBuilder

    • Constructor Detail

      • DotenvBuilder

        public DotenvBuilder()
    • Method Detail

      • directory

        public DotenvBuilder directory​(String path)
        Sets the directory containing the .env file.
        Parameters:
        path - the directory containing the .env file
        Returns:
        this DotenvBuilder
      • filename

        public DotenvBuilder filename​(String name)
        Sets the name of the .env file. The default is .env.
        Parameters:
        name - the filename
        Returns:
        this DotenvBuilder
      • ignoreIfMissing

        public DotenvBuilder ignoreIfMissing()
        Does not throw an exception when .env is missing.
        Returns:
        this DotenvBuilder
      • ignoreIfMalformed

        public DotenvBuilder ignoreIfMalformed()
        Does not throw an exception when .env is malformed.
        Returns:
        this DotenvBuilder
      • systemProperties

        public DotenvBuilder systemProperties()
        Sets each environment variable as system properties.
        Returns:
        this DotenvBuilder