Class PcfAuthenticationOptions.PcfAuthenticationOptionsBuilder
java.lang.Object
org.springframework.vault.authentication.PcfAuthenticationOptions.PcfAuthenticationOptionsBuilder
- Enclosing class:
 - PcfAuthenticationOptions
 
Builder for 
PcfAuthenticationOptions.- 
Method Summary
Modifier and TypeMethodDescriptionbuild()Build a newPcfAuthenticationOptionsinstance.Configure theClock.instanceCertificate(Supplier<String> instanceCertSupplier) Configure theSupplierto obtain the instance certificate.instanceKey(Supplier<String> instanceKeySupplier) Configure theSupplierto obtain the instance key.Configure the mount path.Configure the role. 
- 
Method Details
- 
path
Configure the mount path.- Parameters:
 path- must not be empty or null.- Returns:
 thisPcfAuthenticationOptions.PcfAuthenticationOptionsBuilder.- See Also:
 
 - 
role
Configure the role.- Parameters:
 role- name of the role against which the login is being attempted, must not be null or empty.- Returns:
 thisPcfAuthenticationOptions.PcfAuthenticationOptionsBuilder.
 - 
clock
Configure theClock.- Parameters:
 clock- must not be null.- Returns:
 thisPcfAuthenticationOptions.PcfAuthenticationOptionsBuilder.
 - 
instanceCertificate
public PcfAuthenticationOptions.PcfAuthenticationOptionsBuilder instanceCertificate(Supplier<String> instanceCertSupplier) Configure theSupplierto obtain the instance certificate.- Parameters:
 instanceCertSupplier- the supplier, must not be null.- Returns:
 thisPcfAuthenticationOptions.PcfAuthenticationOptionsBuilder.- See Also:
 
 - 
instanceKey
public PcfAuthenticationOptions.PcfAuthenticationOptionsBuilder instanceKey(Supplier<String> instanceKeySupplier) Configure theSupplierto obtain the instance key.- Parameters:
 instanceKeySupplier- the supplier, must not be null.- Returns:
 thisPcfAuthenticationOptions.PcfAuthenticationOptionsBuilder.- See Also:
 
 - 
build
Build a newPcfAuthenticationOptionsinstance.Falls back to the instance certificate at
CF_INSTANCE_CERTifinstanceCertificate(Supplier)is not configured respectiveCF_INSTANCE_KEYifinstanceKey(Supplier)is not configured.- Returns:
 - a new 
PcfAuthenticationOptions. - Throws:
 IllegalStateException- ifinstanceCertificate(Supplier)orinstanceKey(Supplier)are not set and the corresponding environment variableCF_INSTANCE_CERTrespectiveCF_INSTANCE_KEYis not set.
 
 -