![JAR search and dependency download from the Maven repository](/logo.png)
com.logicommerce.sdk.definition.implementations.PropertyDefinitionValueImpl Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sdk Show documentation
Show all versions of sdk Show documentation
SDK for developing Logicommerce plugins.
package com.logicommerce.sdk.definition.implementations;
import com.logicommerce.sdk.definition.DefinitionLanguages;
import com.logicommerce.sdk.definition.PropertyDefinitionValue;
/**
* PropertyDefinitionValueImpl class.
*
* @author Logicommerce
* @since 1.0.16
*/
public class PropertyDefinitionValueImpl implements PropertyDefinitionValue {
private String value;
private DefinitionLanguages languages;
/** {@inheritDoc} */
@Override
public String getValue() {
return value;
}
/** {@inheritDoc} */
@Override
public DefinitionLanguages getLanguages() {
return languages;
}
void setValue(String value) {
this.value = value;
}
void setLanguages(DefinitionLanguages languages) {
this.languages = languages;
}
public static class Builder {
private T parentBuilder;
private String value;
private DefinitionLanguagesImpl.Builder> languages;
public Builder(T parentBuilder) {
this.parentBuilder = parentBuilder;
}
public Builder value(String value) {
this.value = value;
return this;
}
public DefinitionLanguagesImpl.Builder> languages() {
this.languages = new DefinitionLanguagesImpl.Builder<>(this);
return languages;
}
PropertyDefinitionValue build() {
PropertyDefinitionValueImpl properyDefinitionValue = new PropertyDefinitionValueImpl();
properyDefinitionValue.setValue(value);
if (languages != null) {
properyDefinitionValue.setLanguages(languages.build());
}
return properyDefinitionValue;
}
public T done() {
return parentBuilder;
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy