package stexfires.record;

import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

/**
 * @author Mathias Kalb
 * @since 0.1
 */
public interface ValueRecord extends TextRecord {

    ValueRecord newValueRecord(@Nullable String value);

    @NotNull Field valueField();

    default @Nullable String valueOfValueField() {
        return valueField().value();
    }

}

@@ -106,16 +106,44 @@
 lable;%0A%0A
+import java.util.Optional;%0A%0A
 /**%0A * @
@@ -417,10 +417,136 @@
 %0A    %7D%0A%0A
+    default Optional%3CString%3E valueOfValueFieldAsOptional() %7B%0A        return Optional.ofNullable(valueField().value());%0A    %7D%0A%0A
 %7D%0A

Add method 'valueOfValueFieldAsOptional'