implemented dropping transaction by clearing amount, source or destination field
Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
This commit is contained in:
@@ -6,6 +6,9 @@ import de.srsoftware.umbrella.core.constants.Field;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import static de.srsoftware.tools.Optionals.isSet;
|
||||
import static de.srsoftware.tools.Optionals.nullIfEmpty;
|
||||
|
||||
public class IdOrString implements Mappable {
|
||||
private final Long id;
|
||||
private final String value;
|
||||
@@ -52,6 +55,10 @@ public class IdOrString implements Mappable {
|
||||
return map;
|
||||
}
|
||||
|
||||
public boolean isEmpty() {
|
||||
return id == null && !isSet(value);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return value;
|
||||
@@ -60,4 +67,4 @@ public class IdOrString implements Mappable {
|
||||
public String value(){
|
||||
return value;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user