litesoft
Diff Revisions
949
vs
950
for /trunk/Java/GWT/Client/src/org/litesoft/GWT/client/util/externalization/ExternalizedText.java
|
@@ -1,6 +1,6 @@ |
1 |
1 |
|
package org.litesoft.GWT.client.util.externalization; |
2 |
2 |
|
|
3 |
|
- |
import org.litesoft.commonfoundation.typeutils.*; |
|
3 |
+ |
import org.litesoft.commonfoundation.base.*; |
4 |
4 |
|
import org.litesoft.core.util.*; |
5 |
5 |
|
|
6 |
6 |
|
import com.google.gwt.i18n.client.Dictionary; |
|
@@ -36,9 +36,10 @@ |
36 |
36 |
|
* |
37 |
37 |
|
* @return null or the Template value associated with the key |
38 |
38 |
|
*/ |
|
39 |
+ |
@Override |
39 |
40 |
|
public String get( String key ) { |
40 |
|
- |
key = Strings.noEmpty( key ); |
41 |
|
- |
return (key != null) ? Strings.noEmpty( safeGet( key ) ) : null; |
|
41 |
+ |
key = ConstrainTo.significantOrNull( key ); |
|
42 |
+ |
return (key != null) ? ConstrainTo.significantOrNull( safeGet( key ) ) : null; |
42 |
43 |
|
} |
43 |
44 |
|
|
44 |
45 |
|
/** |
|
@@ -50,7 +51,8 @@ |
50 |
51 |
|
* @return The Template value associated with the key or the defaultValue if |
51 |
52 |
|
* the key was not found or its value was empty |
52 |
53 |
|
*/ |
|
54 |
+ |
@Override |
53 |
55 |
|
public String get( String key, String defaultValue ) { |
54 |
|
- |
return Strings.deNull( get( key ), defaultValue ); |
|
56 |
+ |
return ConstrainTo.firstNonNull( get( key ), defaultValue ); |
55 |
57 |
|
} |
56 |
58 |
|
} |