com.atlassian.jira.issue.customfields.converters
Class StringConverterImpl

java.lang.Object
  extended by com.atlassian.jira.issue.customfields.converters.StringConverterImpl
All Implemented Interfaces:
StringConverter

public class StringConverterImpl
extends java.lang.Object
implements StringConverter


Constructor Summary
StringConverterImpl()
           
 
Method Summary
static java.lang.String convertNullToEmpty(java.lang.String value)
          Returns Empty String if the passed value is null, else returns the original value.
 java.lang.String getObject(java.lang.String stringValue)
          This method is a no-op, but I guess it was included for consistency with other Converters.
 java.lang.String getString(java.lang.String value)
          Just turns null into an empty string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringConverterImpl

public StringConverterImpl()
Method Detail

getString

public java.lang.String getString(java.lang.String value)
Description copied from interface: StringConverter
Just turns null into an empty string.

Specified by:
getString in interface StringConverter
Parameters:
value - The String value to check for null.
Returns:
Empty String if the passed value is null, else returns the original value.

getObject

public java.lang.String getObject(java.lang.String stringValue)
Description copied from interface: StringConverter
This method is a no-op, but I guess it was included for consistency with other Converters.

Specified by:
getObject in interface StringConverter
Parameters:
stringValue - the stringValue to do absolutely nothing with, and just return as is.
Returns:
The exact same object that you gave me.

convertNullToEmpty

public static java.lang.String convertNullToEmpty(java.lang.String value)
Returns Empty String if the passed value is null, else returns the original value.

Parameters:
value - The String value to check for null.
Returns:
Empty String if the passed value is null, else returns the original value.


Copyright © 2002-2010 Atlassian. All Rights Reserved.