Class CdpProfileConfigFile
- java.lang.Object
-
- com.cloudera.cdp.authentication.credentials.profile.CdpProfileConfigFile
-
public class CdpProfileConfigFile extends Object
Handles loading a CDP profile from either the default location or from an input path. Offers a convenience method for retreiving credentials from a named profile.
-
-
Constructor Summary
Constructors Constructor Description CdpProfileConfigFile()
Constructor.CdpProfileConfigFile(File file)
Loads the CDP credential profiles from the input file.CdpProfileConfigFile(String filePath)
Loads the CDP credential profiles from the input path.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CdpCredentials
getCredentials(String profileName)
Returns the CdpCredentials using the profile name provided.
-
-
-
Constructor Detail
-
CdpProfileConfigFile
public CdpProfileConfigFile()
Constructor. Loads the CDP credentials file from the default location.
-
CdpProfileConfigFile
public CdpProfileConfigFile(String filePath)
Loads the CDP credential profiles from the input path.- Parameters:
filePath
- path to CDP credentials file
-
CdpProfileConfigFile
public CdpProfileConfigFile(File file)
Loads the CDP credential profiles from the input file.- Parameters:
file
- CDP credentials file
-
-
Method Detail
-
getCredentials
public CdpCredentials getCredentials(String profileName)
Returns the CdpCredentials using the profile name provided.- Parameters:
profileName
- CDP profile name- Returns:
- CdpCredentials
-
-