|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.mtl.common.utils.MTLStandardLibrary
public final class MTLStandardLibrary
This will define additional operations on OCL types as defined in the MTL specification.
| Field Summary | |
|---|---|
static java.lang.String |
OPERATION_INTEGER_TOSTRING
Name of the "toString" standard Integer operation. |
static java.lang.String |
OPERATION_REAL_TOSTRING
Name of the "toString" standard Real operation. |
static java.lang.String |
OPERATION_STRING_FIRST
Name of the "first" standard String operation. |
static java.lang.String |
OPERATION_STRING_INDEX
Name of the "index" standard String operation. |
static java.lang.String |
OPERATION_STRING_ISALPHA
Name of the "isAlpha" standard String operation. |
static java.lang.String |
OPERATION_STRING_ISALPHANUM
Name of the "isAlphanum" standard String operation. |
static java.lang.String |
OPERATION_STRING_LAST
Name of the "last" standard String operation. |
static java.lang.String |
OPERATION_STRING_STRCMP
Name of the "strcmp" standard String operation. |
static java.lang.String |
OPERATION_STRING_STRSTR
Name of the "strstr" standard String operation. |
static java.lang.String |
OPERATION_STRING_STRTOK
Name of the "strtok" standard String operation. |
static java.lang.String |
OPERATION_STRING_SUBSTITUTE
Name of the "substitute" standard String operation. |
static java.lang.String |
OPERATION_STRING_TOLOWERFIRST
Name of the "toLowerFirst" standard String operation. |
static java.lang.String |
OPERATION_STRING_TOUPPERFIRST
Name of the "toUpperFirst" standard String operation. |
static java.lang.String |
PRIMITIVE_INTEGER_NAME
Name of the primitive type "Integer" as defined in the OCL standard library. |
static java.lang.String |
PRIMITIVE_REAL_NAME
Name of the primitive type "Real" as defined in the OCL standard library. |
static java.lang.String |
PRIMITIVE_STRING_NAME
Name of the primitive type "String" as defined in the OCL standard library. |
| Constructor Summary | |
|---|---|
MTLStandardLibrary()
Initializes the standard library package along with its content. |
|
| Method Summary | |
|---|---|
org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.EOperation> |
getExistingOperations(org.eclipse.emf.ecore.EClassifier type)
Obtains the operations declared on the specified type. |
org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.EOperation> |
getExistingOperations(java.lang.String classifierName)
Obtains the operations declared on the specified type. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String OPERATION_INTEGER_TOSTRING
toString( Integer i ) : String
Converts the integer i to a string.
Note that this has been replaced by the MTLNonStandardLibrary.OPERATION_OCLANY_TOSTRING.
public static final java.lang.String OPERATION_REAL_TOSTRING
toString( Real r ) : String
Converts the real r to a string.
Note that this has been replaced by the MTLNonStandardLibrary.OPERATION_OCLANY_TOSTRING.
public static final java.lang.String OPERATION_STRING_FIRST
first( Integer n ) : String
Returns first n characters of self, or self if size of self is
less than n.
public static final java.lang.String OPERATION_STRING_INDEX
index( String r ) : Integer
Returns the index of substring r in self, or -1 if r is not in
self.
public static final java.lang.String OPERATION_STRING_ISALPHA
isAlpha() : Boolean
Returns true if self consists only of alphabetical
characters, false otherwise.
public static final java.lang.String OPERATION_STRING_ISALPHANUM
isAlphanum() : Boolean
Returns true if self consists only of alphanumeric
characters, false otherwise.
public static final java.lang.String OPERATION_STRING_LAST
last( Integer n ) : String
Returns last n characters of self, or self if size of self is
less than n.
public static final java.lang.String OPERATION_STRING_STRCMP
strcmp( String s1 ) : Integer
Returns an integer less than zero, equal to zero, or greater
than zero depending on whether s1 is lexicographically less than, equal to, or greater than self.
public static final java.lang.String OPERATION_STRING_STRSTR
strstr( String r ) : Boolean
Searches for string r in self. Returns true if found, false
otherwise.
public static final java.lang.String OPERATION_STRING_STRTOK
strtok( String s1, Integer flag ) : String
Breaks the string self into a sequence of tokens
each of which is delimited by any character in string s1. The parameter flag should be 0 when strtok is
called for the first time, 1 subsequently.
public static final java.lang.String OPERATION_STRING_SUBSTITUTE
substitute( String r, String t ) : String
Substitutes substring r in self by substring t
and returns the resulting string. If there is no occurrence of the substring, it returns the original
string.
public static final java.lang.String OPERATION_STRING_TOLOWERFIRST
toLowerFirst() : String
Creates a copy of self with first character converted to lowercase
and returns it.
public static final java.lang.String OPERATION_STRING_TOUPPERFIRST
toUpperFirst() : String
Creates a copy of self with first character converted to uppercase
and returns it.
public static final java.lang.String PRIMITIVE_INTEGER_NAME
public static final java.lang.String PRIMITIVE_REAL_NAME
public static final java.lang.String PRIMITIVE_STRING_NAME
| Constructor Detail |
|---|
public MTLStandardLibrary()
| Method Detail |
|---|
public org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.EOperation> getExistingOperations(org.eclipse.emf.ecore.EClassifier type)
type - The type which operation are sought.
null if none.public org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.EOperation> getExistingOperations(java.lang.String classifierName)
classifierName - The name of the classifier which operation are sought.
null if none.
|
Copyright 2008 Obeo All Rights Reserved. |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||