-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #51 from pagopa/hotfix-boolean-converters-to-stand…
…in-and-aca fix: updated flag converters for aca and standIn.
- Loading branch information
Showing
3 changed files
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
src/main/java/it/gov/pagopa/apiconfig/starter/util/DummyBooleanConverter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package it.gov.pagopa.apiconfig.starter.util; | ||
|
||
import javax.persistence.AttributeConverter; | ||
|
||
/** | ||
* Dummy converter for boolean values, to deprecate once all entities using the numeric converter are | ||
* defined without the use of the auto-apply | ||
*/ | ||
public class DummyBooleanConverter implements AttributeConverter<Boolean, Boolean> { | ||
|
||
@Override | ||
public Boolean convertToDatabaseColumn(final Boolean value) { | ||
return value; | ||
} | ||
|
||
@Override | ||
public Boolean convertToEntityAttribute(final Boolean value) { | ||
return value; | ||
} | ||
|
||
} |