@InterfaceAudience.Private @InterfaceStability.Unstable public class CredentialsBuilder extends Object implements Builder<Credentials>
Credentials.
The properties of the builder can only be set once, an attempt to set them a second time will trigger
an IllegalStateException. The properties that are lists are an exception to this rule, of course multiple
elements can be added / removed.
Builder instances can be used to build several elements, although properties already set cannot be changed after
a call to build() either.| Modifier and Type | Method and Description |
|---|---|
Credentials |
build()
Builds and returns an object.
|
static CredentialsBuilder |
create() |
static CredentialsBuilder |
createFromExisting(Credentials credentials) |
CredentialsBuilder |
withCredential(Credential credential) |
CredentialsBuilder |
withCredential(String name,
String value) |
CredentialsBuilder |
withCredential(String name,
String type,
List<ConfigurationEntry> configurationEntries) |
public static CredentialsBuilder create()
public static CredentialsBuilder createFromExisting(Credentials credentials)
public CredentialsBuilder withCredential(String name, String value)
public CredentialsBuilder withCredential(String name, String type, List<ConfigurationEntry> configurationEntries)
public CredentialsBuilder withCredential(Credential credential)
public Credentials build()
Builderbuild in interface Builder<Credentials>Copyright © 2021 Apache Software Foundation. All rights reserved.