Package com.io7m.jade.api
Class ApplicationDirectoryConfiguration.Builder
java.lang.Object
com.io7m.jade.api.ApplicationDirectoryConfiguration.Builder
- Enclosing class:
- ApplicationDirectoryConfiguration
Builds instances of type
ApplicationDirectoryConfiguration.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds a newApplicationDirectoryConfiguration.from(ApplicationDirectoryConfigurationType instance) Fill a builder with attribute values from the providedApplicationDirectoryConfigurationTypeinstance.setApplicationName(String applicationName) Initializes the value for theapplicationNameattribute.setOverridePropertyName(String overridePropertyName) Initializes the optional valueoverridePropertyNameto overridePropertyName.setOverridePropertyName(Optional<String> overridePropertyName) Initializes the optional valueoverridePropertyNameto overridePropertyName.setPortablePropertyName(String portablePropertyName) Initializes the optional valueportablePropertyNameto portablePropertyName.setPortablePropertyName(Optional<String> portablePropertyName) Initializes the optional valueportablePropertyNameto portablePropertyName.
-
Method Details
-
from
public final ApplicationDirectoryConfiguration.Builder from(ApplicationDirectoryConfigurationType instance) Fill a builder with attribute values from the providedApplicationDirectoryConfigurationTypeinstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
setApplicationName
Initializes the value for theapplicationNameattribute.- Parameters:
applicationName- The value for applicationName- Returns:
thisbuilder for use in a chained invocation
-
setPortablePropertyName
public final ApplicationDirectoryConfiguration.Builder setPortablePropertyName(String portablePropertyName) Initializes the optional valueportablePropertyNameto portablePropertyName.- Parameters:
portablePropertyName- The value for portablePropertyName- Returns:
thisbuilder for chained invocation
-
setPortablePropertyName
public final ApplicationDirectoryConfiguration.Builder setPortablePropertyName(Optional<String> portablePropertyName) Initializes the optional valueportablePropertyNameto portablePropertyName.- Parameters:
portablePropertyName- The value for portablePropertyName- Returns:
thisbuilder for use in a chained invocation
-
setOverridePropertyName
public final ApplicationDirectoryConfiguration.Builder setOverridePropertyName(String overridePropertyName) Initializes the optional valueoverridePropertyNameto overridePropertyName.- Parameters:
overridePropertyName- The value for overridePropertyName- Returns:
thisbuilder for chained invocation
-
setOverridePropertyName
public final ApplicationDirectoryConfiguration.Builder setOverridePropertyName(Optional<String> overridePropertyName) Initializes the optional valueoverridePropertyNameto overridePropertyName.- Parameters:
overridePropertyName- The value for overridePropertyName- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newApplicationDirectoryConfiguration.- Returns:
- An immutable instance of ApplicationDirectoryConfiguration
- Throws:
IllegalStateException- if any required attributes are missing
-