public class NameUtils
extends org.mule.runtime.api.util.NameUtils
NameUtils with extensions oriented behavior| Modifier and Type | Field and Description |
|---|---|
static String |
CONFIGURATION |
static String |
CONNECTION_PROVIDER |
static String |
CONSTRUCT |
static String |
FUNCTION |
static String |
OPERATION |
static String |
SOURCE |
static String |
SOURCE_CALLBACK |
| Modifier and Type | Method and Description |
|---|---|
static <T extends org.mule.runtime.api.meta.NamedObject> |
alphaSortDescribedList(List<T> list)
Sorts the given
list in ascending alphabetic order, using NamedObject.getName() as the sorting criteria |
static String |
defaultNamespace(String extensionName) |
static String |
getAliasName(Class<?> type) |
static String |
getAliasName(Field field) |
static String |
getAliasName(org.mule.metadata.api.model.MetadataType metadataType)
This method will look for the
TypeAliasAnnotation of the MetadataType
to get the type simple name. |
static String |
getAliasName(Parameter parameter) |
static String |
getComponentDeclarationTypeName(org.mule.runtime.api.meta.model.declaration.fluent.BaseDeclaration declaration) |
static String |
getComponentModelTypeName(org.mule.runtime.api.meta.model.parameter.ParameterizedModel component) |
static String |
getDeclarationTypeName(org.mule.runtime.api.meta.model.declaration.fluent.ParameterizedDeclaration declaration) |
static String |
getModelName(Object model) |
static String |
getTopLevelTypeName(org.mule.metadata.api.model.MetadataType metadataType)
Returns a hypenized name of the give top level
metadataType. |
static boolean |
isUncountable(String word)
Return true if the word is uncountable.
|
static String |
itemize(String word)
Return the itemized version of a word, which is
an
hyphenized version of the word with
the item suffix |
static String |
pluralize(String word)
Return the pluralized version of a word.
|
static String |
singularize(String word)
Return the singularized version of a word.
|
public static final String CONFIGURATION
public static final String OPERATION
public static final String CONNECTION_PROVIDER
public static final String SOURCE
public static final String SOURCE_CALLBACK
public static final String FUNCTION
public static final String CONSTRUCT
public static String pluralize(String word)
word - The wordpublic static String singularize(String word)
word - The wordpublic static String itemize(String word)
hyphenized version of the word with
the item suffixword - The wordpublic static boolean isUncountable(String word)
word - The wordpublic static String getTopLevelTypeName(org.mule.metadata.api.model.MetadataType metadataType)
metadataType.
This method will look for the TypeAliasAnnotation of the MetadataType
to get the type simple name.
As a fallback, it uses ClassInformationAnnotation.getClassname() to obtain the
simple name of the class.
Finally if there is no ClassInformation, the TypeIdAnnotation will be used as
Alias, failing if it is not found.
metadataType - the MetadataType which name you wanttypepublic static String getAliasName(org.mule.metadata.api.model.MetadataType metadataType)
TypeAliasAnnotation of the MetadataType
to get the type simple name.
As a fallback, it uses ClassInformationAnnotation.getClassname() to obtain the
simple name of the class.
Finally if there is no ClassInformation, the TypeIdAnnotation will be used as
Alias, failing if it is not found.
metadataType - the MetadataType whose Alias is requiredpublic static String getComponentModelTypeName(org.mule.runtime.api.meta.model.parameter.ParameterizedModel component)
public static String getDeclarationTypeName(org.mule.runtime.api.meta.model.declaration.fluent.ParameterizedDeclaration declaration)
public static String getComponentDeclarationTypeName(org.mule.runtime.api.meta.model.declaration.fluent.BaseDeclaration declaration)
public static <T extends org.mule.runtime.api.meta.NamedObject> List<T> alphaSortDescribedList(List<T> list)
list in ascending alphabetic order, using NamedObject.getName() as the sorting criteriaT - the generic type of the items in the listlist - a List with instances of NamedObjectlistCopyright © 2018 MuleSoft, Inc.. All rights reserved.