Skip to content
Snippets Groups Projects
Commit 9b0e44c6 authored by felmer's avatar felmer
Browse files

LMS-1957 add convenience method

SVN: 19382
parent fd76e052
No related branches found
No related tags found
No related merge requests found
......@@ -16,6 +16,8 @@
package ch.systemsx.cisd.openbis.generic.shared.basic.dto;
import org.apache.commons.lang.StringUtils;
/**
* Table cell wrapping a string.
......@@ -25,6 +27,12 @@ package ch.systemsx.cisd.openbis.generic.shared.basic.dto;
public class StringTableCell implements ISerializableComparable
{
private static final long serialVersionUID = ServiceVersionHolder.VERSION;
private static final StringTableCell EMPTY_CELL = new StringTableCell("");
public static StringTableCell wrap(String stringOrNull)
{
return StringUtils.isBlank(stringOrNull) ? EMPTY_CELL : new StringTableCell(stringOrNull);
}
private String string;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment