Skip to content

Commit

Permalink
perf: use lombok for enum getters
Browse files Browse the repository at this point in the history
  • Loading branch information
jy95 committed Jan 28, 2025
1 parent 9d303be commit 9db5142
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 16 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
package io.github.jy95.fds.common.types;

import lombok.Getter;

import java.util.List;

/**
* Represents the available display orders
*
* @author jy95
*/
@Getter
public enum DisplayOrder {
/**
* Display "method"
Expand Down Expand Up @@ -141,18 +144,13 @@ public enum DisplayOrder {
*/
TIMING_MODIFIER_EXTENSION(List.of("timing.modifierExtension"));

/**
* Getter for the <code>field</code>(s) covered by the display order
*/
private final List<String> fields;

DisplayOrder(List<String> fields) {
this.fields = fields;
}

/**
* <p>Getter for the field <code>fields</code>.</p>
*
* @return a {@link java.util.List} object
*/
public List<String> getFields() {
return fields;
}
}
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
package io.github.jy95.fds.common.types;

import lombok.Getter;

/**
* Enum representing the link words used to combine list elements.
*
* @author jy95
*/
@Getter
public enum LinkWord {
/**
* Represents the "and" link word.
Expand All @@ -15,18 +18,13 @@ public enum LinkWord {
*/
THEN("then");

/**
* Retrieves the value of the link word.
*/
private final String value;

LinkWord(String value) {
this.value = value;
}

/**
* Retrieves the value of the link word.
*
* @return The string value of the link word.
*/
public String getValue() {
return value;
}
}

0 comments on commit 9db5142

Please sign in to comment.