org.plasma.provisioning
Class NameUtils

java.lang.Object
  extended by org.plasma.provisioning.NameUtils

public class NameUtils
extends Object


Constructor Summary
NameUtils()
           
 
Method Summary
static String firstToLowerCase(String name)
           
static String firstToUpperCase(String name)
           
static String toAbbreviatedName(String name)
          Creates a capitalized, underscore delimited name from the given camel case name and removes consonant characters where the name exceeds the given max.
static String toAbbreviatedName(String name, int max)
          Creates a capitalized, underscore delimited name from the given camel case name and removes consonant characters where the name exceeds the given max.
static String toCamelCase(String name)
          Creates a capitalized, underscore delimited name from the given camel case name.
static String toConstantName(String name)
          Creates a capitalized, underscore delimited name from the given camel case name.
static String[] toPackageTokens(String uri)
          Tokenizes the given URI as an array of names suitable to be used as a UML package hierarchy.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NameUtils

public NameUtils()
Method Detail

toPackageTokens

public static String[] toPackageTokens(String uri)
Tokenizes the given URI as an array of names suitable to be used as a UML package hierarchy.

Parameters:
uri -
Returns:
the name array

toCamelCase

public static String toCamelCase(String name)
Creates a capitalized, underscore delimited name from the given camel case name.

Parameters:
name - the name
Returns:
the result name

toConstantName

public static String toConstantName(String name)
Creates a capitalized, underscore delimited name from the given camel case name.

Parameters:
name - the name
Returns:
the result name

toAbbreviatedName

public static String toAbbreviatedName(String name)
Creates a capitalized, underscore delimited name from the given camel case name and removes consonant characters where the name exceeds the given max.

Parameters:
name - the name
Returns:

toAbbreviatedName

public static String toAbbreviatedName(String name,
                                       int max)
Creates a capitalized, underscore delimited name from the given camel case name and removes consonant characters where the name exceeds the given max.

Parameters:
name - the name
max - the max size to allow before abbreviation begins.
Returns:

firstToUpperCase

public static String firstToUpperCase(String name)

firstToLowerCase

public static String firstToLowerCase(String name)


Copyright © 2014. All rights reserved.