org.eclipse.emf.oda.ecore.util
Class StringUtil

java.lang.Object
  extended by org.eclipse.emf.oda.ecore.util.StringUtil

public class StringUtil
extends java.lang.Object

A utility for working with strings and text.


Constructor Summary
StringUtil()
           
 
Method Summary
protected static java.lang.String capName(java.lang.String name)
           
protected static java.lang.String format(java.lang.String name, char separator)
           
static java.lang.String getFeatureText(EStructuralFeature feature)
          Returns formatted text for the specified feature
protected static EStructuralFeature getLabelFeature(EClass eClass)
           
static java.lang.String getText(java.lang.Object object)
           
static java.lang.String getTypeText(EClassifier classifier)
          Returns formatted text for the specified type
static boolean isEmpty(java.lang.String text)
          Indicates whether the specified text is null or has a length of zero.
protected static java.util.List<java.lang.String> parseName(java.lang.String sourceName, char sourceSeparator)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringUtil

public StringUtil()
Method Detail

parseName

protected static java.util.List<java.lang.String> parseName(java.lang.String sourceName,
                                                            char sourceSeparator)

format

protected static java.lang.String format(java.lang.String name,
                                         char separator)

capName

protected static java.lang.String capName(java.lang.String name)

getLabelFeature

protected static EStructuralFeature getLabelFeature(EClass eClass)

getText

public static java.lang.String getText(java.lang.Object object)

getFeatureText

public static java.lang.String getFeatureText(EStructuralFeature feature)
Returns formatted text for the specified feature

Parameters:
feature - the feature
Returns:
formatted text

getTypeText

public static java.lang.String getTypeText(EClassifier classifier)
Returns formatted text for the specified type

Parameters:
classifier - the type
Returns:
formatted text

isEmpty

public static boolean isEmpty(java.lang.String text)
Indicates whether the specified text is null or has a length of zero.

Parameters:
text - the text
Returns:
whether the text is null or empty

Copyright 2001-2012 IBM Corporation and others.
All Rights Reserved.