Skip to content

Commit

Permalink
IDE-Checks
Browse files Browse the repository at this point in the history
  • Loading branch information
cuioss committed Feb 18, 2025
1 parent eba1d79 commit 23f51a6
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ public boolean isBooleanField() {
* @return {@link DynamicFieldType} identified by the given type. In case there
* is no fitting type it will return {@link DynamicFieldType#STRING}
*/
public static final DynamicFieldType getByTypeString(final String type) {
public static DynamicFieldType getByTypeString(final String type) {
var fieldType = DynamicFieldType.STRING;

for (final DynamicFieldType dynamicFieldType : DynamicFieldType.values()) {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/de/cuioss/uimodel/model/Gender.java
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ private static Map<String, Gender> initMapping() {
* @param genderString may be {@code null} or empty
* @return the computed {@linkplain Gender} object.
*/
public static final Gender fromString(final String genderString) {
public static Gender fromString(final String genderString) {
final var key = nullToEmpty(genderString).toLowerCase();
return MAPPING.getOrDefault(key, UNKNOWN);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,10 @@
* @author Matthias Walliczek
*/
@UtilityClass
public final class AugmentationKeyConstans {
public final class AugmentationKeyConstants {

/**
* Marks one code in a category as default, e.g. to be used to preselect a drop
* down box.
* Marks one code in a category as default, e.g., to be used to preselect a drop-down box.
*/
public static final String DEFAULT_VALUE = "default_value";

Expand All @@ -43,8 +42,8 @@ public final class AugmentationKeyConstans {
* <code>true</code>.
*/
public static boolean isUndefinedValue(final ConceptKeyType codeType) {
return null != codeType && null != codeType.get(AugmentationKeyConstans.UNDEFINED_VALUE)
&& Boolean.parseBoolean(codeType.get(AugmentationKeyConstans.UNDEFINED_VALUE));
return null != codeType && null != codeType.get(AugmentationKeyConstants.UNDEFINED_VALUE)
&& Boolean.parseBoolean(codeType.get(AugmentationKeyConstants.UNDEFINED_VALUE));
}

/**
Expand All @@ -54,7 +53,7 @@ public static boolean isUndefinedValue(final ConceptKeyType codeType) {
* <code>true</code>.
*/
public static boolean isDefaultValue(final ConceptKeyType codeType) {
return null != codeType && null != codeType.get(AugmentationKeyConstans.DEFAULT_VALUE)
&& Boolean.parseBoolean(codeType.get(AugmentationKeyConstans.DEFAULT_VALUE));
return null != codeType && null != codeType.get(AugmentationKeyConstants.DEFAULT_VALUE)
&& Boolean.parseBoolean(codeType.get(AugmentationKeyConstants.DEFAULT_VALUE));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public interface ConceptCategory extends Serializable {
/**
* @param value the identifier
* @return an ConceptKeyType with given value marked with
* {@link AugmentationKeyConstans#UNDEFINED_VALUE}
* {@link AugmentationKeyConstants#UNDEFINED_VALUE}
*/
ConceptKeyType createUndefinedConceptKey(String value);
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

import java.io.Serial;

import de.cuioss.uimodel.model.conceptkey.AugmentationKeyConstans;
import de.cuioss.uimodel.model.conceptkey.AugmentationKeyConstants;
import de.cuioss.uimodel.model.conceptkey.ConceptCategory;
import de.cuioss.uimodel.model.conceptkey.ConceptKeyType;
import de.cuioss.uimodel.nameprovider.I18nDisplayNameProvider;
Expand Down Expand Up @@ -60,7 +60,7 @@ public BaseConceptCategory(final String name) {
@Override
public ConceptKeyType createUndefinedConceptKey(final String value) {
return ConceptKeyTypeImpl.builder().identifier(value).labelResolver(new I18nDisplayNameProvider(value))
.category(this).augmentation(AugmentationKeyConstans.UNDEFINED_VALUE, Boolean.TRUE.toString()).build();
.category(this).augmentation(AugmentationKeyConstants.UNDEFINED_VALUE, Boolean.TRUE.toString()).build();
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ public DisplayMessageProvider build() {
/**
* @return {@linkplain Builder} in fluent api style
*/
public static final Builder builder() {
public static Builder builder() {
return new Builder();
}
}
2 changes: 1 addition & 1 deletion src/site/asciidoc/about.adoc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
== About

Defines types and stuctures symplifying the integration of server-side ui
Defines types and features simplifying the integration of server-side ui
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

import de.cuioss.test.generator.Generators;
import de.cuioss.test.generator.TypedGenerator;
import de.cuioss.uimodel.model.conceptkey.AugmentationKeyConstans;
import de.cuioss.uimodel.model.conceptkey.AugmentationKeyConstants;
import de.cuioss.uimodel.model.conceptkey.ConceptCategory;
import de.cuioss.uimodel.model.conceptkey.ConceptKeyType;

Expand All @@ -42,7 +42,7 @@ enum TestCodeCategory implements ConceptCategory {
@Override
public ConceptKeyType createUndefinedConceptKey(final String value) {
return ConceptKeyTypeImpl.builder().category(this).identifier(value)
.augmentation(AugmentationKeyConstans.UNDEFINED_VALUE, Boolean.TRUE.toString()).build();
.augmentation(AugmentationKeyConstants.UNDEFINED_VALUE, Boolean.TRUE.toString()).build();
}

@Override
Expand Down

0 comments on commit 23f51a6

Please sign in to comment.