|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.maverickdbms.basic.ConstantString
This is the basic string interface for the package.
| Field Summary | |
static ConstantString |
AM
|
static ConstantString |
EMPTY
|
static ConstantString |
FM
|
static ConstantString |
IM
|
static ConstantString |
LINE_SEPARATOR
|
protected static char |
MAX_RAISE_DELIMITER
|
protected static char |
MIN_RAISE_DELIMITER
|
static ConstantString |
ONE
|
static ConstantString |
RETURN_ELSE
Return value for unsuccessful completion of function |
static ConstantString |
RETURN_SUCCESS
Return value for successful completion of function |
static ConstantString |
RM
|
static ConstantString |
SM
|
static ConstantString |
SPACE
|
static ConstantString |
TM
|
static ConstantString |
VM
|
static ConstantString |
ZERO
|
| Constructor Summary | |
ConstantString()
|
|
| Method Summary | |
mvString |
ALPHA(mvString mvn)
Determines whether the string contains entirely alphabetic characters. |
ConstantString |
AND(ConstantString a)
|
mvString |
ASCII(mvString result)
Converts a ConstantString encoded in EBCDIC into ASCII |
mvString |
CAT(mvString result,
ConstantString append)
Appends a mvString to the current mvString. |
mvString |
CHANGE(mvString result,
ConstantString a,
ConstantString b,
ConstantString occur,
ConstantString begin)
|
mvString |
CHAR(mvString result)
Converts the numeric value into a ASCII value |
abstract char |
charAt(int index)
Gets the char at the given position. |
abstract int |
compareTo(ConstantString a)
Compares two strings lexicographically |
int |
compareTo(java.lang.Object o)
Compares two strings lexicographically |
mvString |
CONVERT(mvString result,
ConstantString a,
ConstantString b)
|
mvString |
COUNT(mvString count,
ConstantString substr,
int offset)
Counts the number of occurrences of a substring within the string |
mvString |
DCOUNT(mvString dcount,
ConstantString substr,
int offset)
Counts the number of substrings delimited by delim in the string. |
mvString |
DELETE(mvString result,
ConstantString attrib,
ConstantString val,
ConstantString subval)
Deletes an attribute, value or subvalue from a mvString, the corresponding delimiter is also removed |
mvString |
DOWNCASE(mvString result)
|
mvString |
DQUOTE(mvString result)
|
mvString |
DTX(mvString result,
ConstantString width)
Converts a decimal integer to hexadecimal notation |
mvString |
EBCDIC(mvString result)
Converts a mvString encoded in ASCII into EBCDIC |
ConstantString |
EQ(ConstantString a)
Determines whether mvs is equal to the string. |
abstract boolean |
equals(java.lang.Object o)
Determines whether the object is equal to the string |
mvString |
EREPLACE(mvString result,
ConstantString a,
ConstantString b,
ConstantString occur,
ConstantString begin)
|
boolean |
eval()
Determines whether the string is valid |
ConstantString |
EXTRACT(ConstantString attrib,
ConstantString val,
ConstantString subval)
|
mvString |
FIELD(mvString result,
mvString col1,
mvString col2,
ConstantString delim,
ConstantString field,
ConstantString count)
Returns the specified substring indexed by the delimiter |
int |
findLength(int start,
int len,
char delim)
|
int |
findPosition(int a,
int v,
int s)
|
ConstantString |
GE(MathInterface m,
ConstantString a)
|
abstract java.math.BigDecimal |
getBigDecimal()
Returns a BigDecimal representation of the string. |
abstract void |
getChars(int srcstart,
int srcend,
char[] dest,
int deststart)
Copies the specified index from the string into the destination character array. |
abstract double |
getDouble()
Returns a double representation of the string. |
ConstantString |
getReferenceString(ConstantString start,
ConstantString len)
|
ConstantString |
GT(MathInterface m,
ConstantString a)
|
mvString |
INDEX(mvString result,
ConstantString substr,
ConstantString numexpr)
Returns the starting position of the specified substr |
abstract int |
indexOf(char c,
int start)
|
mvString |
INSERT(mvString result,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString insert)
Inserts the specified string at the specified attribute, value and subvalue mark. |
abstract int |
intValue()
Returns the integer value of the string |
abstract boolean |
isIntegral()
|
abstract boolean |
isNumeric()
|
ConstantString |
LE(MathInterface m,
ConstantString a)
|
mvString |
LEN(mvString mvn)
Returns the length of the string |
abstract int |
length()
Returns the length of the string |
ConstantString |
LOCATEI(mvString location,
ConstantString element,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString start,
ConstantString searchtype)
Implementation of the (Prime) basic LOCATE statement |
ConstantString |
LOCATEP(mvString location,
ConstantString element,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString start,
ConstantString searchtype)
Implementation of the (Pick) basic LOCATE statement |
abstract long |
longValue()
Returns the integer value of the string |
mvString |
LOWER(mvString result)
Converts any delimiters found to the next lower level |
ConstantString |
LT(MathInterface m,
ConstantString a)
|
ConstantString |
MATCH(ConstantString pattern)
The MATCH functions matches the specified pattern to the string. |
ConstantString |
NOT()
|
mvString |
NUM(mvString mvn)
|
ConstantString |
OR(ConstantString a)
|
mvString |
RAISE(mvString result)
Converts any delimiters found to the next higher level |
mvString |
REPLACE(mvString result,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString replace)
Replaces the specified string at the specified attribute, value and subvalue mark. |
void |
SELECT(Program program,
mvString result,
Key key)
Creates a select list from the attributes of the current string |
mvString |
SEQ(mvString mvn)
Returns the ascii value of a single character |
mvString |
SPACE(mvString result)
Creates a string with the specified number of spaces |
mvString |
SQUOTE(mvString result)
|
mvString |
STR(mvString result,
ConstantString count)
Returns a string composed of a given number of repeated substrings |
mvString |
SUM(mvString result,
ConstantString begin,
ConstantString end)
|
abstract java.lang.String |
toString()
The standard toString method for the object |
mvString |
TRIM(mvString result,
ConstantString chr,
ConstantString type)
Removes the leading spaces and any concurrent spaces from the string |
mvString |
UPCASE(mvString result)
|
mvString |
XTD(mvString result,
ConstantString width)
Converts a hexadecimal value to decimal notation |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final ConstantString IM
public static final ConstantString RM
public static final ConstantString AM
public static final ConstantString FM
public static final ConstantString VM
public static final ConstantString SM
public static final ConstantString TM
public static final ConstantString ZERO
public static final ConstantString ONE
public static final ConstantString EMPTY
public static final ConstantString RETURN_SUCCESS
public static final ConstantString RETURN_ELSE
public static final ConstantString SPACE
public static final ConstantString LINE_SEPARATOR
protected static final char MAX_RAISE_DELIMITER
protected static final char MIN_RAISE_DELIMITER
| Constructor Detail |
public ConstantString()
| Method Detail |
public mvString ALPHA(mvString mvn)
mvn - the number to contain the result
public ConstantString AND(ConstantString a)
public mvString ASCII(mvString result)
throws java.io.UnsupportedEncodingException
result - mvString to contain the ascii translation
java.io.UnsupportedEncodingException - if the EBCDIC codepage is not present
public mvString CAT(mvString result,
ConstantString append)
result - the mvString to store the concatenated stringappend - the string to append
public mvString CHANGE(mvString result,
ConstantString a,
ConstantString b,
ConstantString occur,
ConstantString begin)
public mvString CHAR(mvString result)
result - mvString for storing the ascii result
public abstract char charAt(int index)
index - position of char within the string
public abstract int compareTo(ConstantString a)
a - string to compare
public int compareTo(java.lang.Object o)
compareTo in interface java.lang.Comparableo - object to compare
public mvString CONVERT(mvString result,
ConstantString a,
ConstantString b)
public mvString COUNT(mvString count,
ConstantString substr,
int offset)
count - mvString to contain the countsubstr - the substring to be searched foroffset - increment to start searching again after successful match
public mvString DCOUNT(mvString dcount,
ConstantString substr,
int offset)
dcount - the number to store the resultsubstr - the string to be searched foroffset - increment to start searching again after sucessful match
public mvString DELETE(mvString result,
ConstantString attrib,
ConstantString val,
ConstantString subval)
result - variable to place the resulting multivalue.attrib - attribute to delete, if value is zero the entire attribute is deletedval - value to delete, if subval is zero the entire value is deletedsubval - subvalue to delete.
public mvString DOWNCASE(mvString result)
public mvString DQUOTE(mvString result)
public mvString DTX(mvString result,
ConstantString width)
result - the string into which to place the outputwidth - the minimum size of the result
If width is specified and the number is of insufficient length
the resulting string is padded with leading zeroes
public mvString EBCDIC(mvString result)
throws java.io.UnsupportedEncodingException
result - mvString to contain the EBCDIC translation
java.io.UnsupportedEncodingException - if the EBCDIC codepage is not presentpublic ConstantString EQ(ConstantString a)
a - the string to be compared
public abstract boolean equals(java.lang.Object o)
o - the object to be compared
public mvString EREPLACE(mvString result,
ConstantString a,
ConstantString b,
ConstantString occur,
ConstantString begin)
public boolean eval()
public ConstantString EXTRACT(ConstantString attrib,
ConstantString val,
ConstantString subval)
public mvString FIELD(mvString result,
mvString col1,
mvString col2,
ConstantString delim,
ConstantString field,
ConstantString count)
result - the mvString to hold the substringcol1 - the start indexcol2 - the end indexdelim - the delimiterfield - the field numbercount - the number of fields to return
public int findLength(int start,
int len,
char delim)
public int findPosition(int a,
int v,
int s)
public abstract int indexOf(char c,
int start)
public mvString INSERT(mvString result,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString insert)
result - the string to hold the resulting dynamic arrayattrib - attribute positionval - value mark positionsubval - subvalue mark postioninsert - mvString to be inserted
public ConstantString GE(MathInterface m,
ConstantString a)
public abstract java.math.BigDecimal getBigDecimal()
public abstract double getDouble()
public abstract void getChars(int srcstart,
int srcend,
char[] dest,
int deststart)
srcstart - starting postion in the source string.srcend - ending index + 1 of characters to be copied from source.dest - the destination character arraydeststart - starting position in the destination array.
public ConstantString getReferenceString(ConstantString start,
ConstantString len)
public ConstantString GT(MathInterface m,
ConstantString a)
public mvString INDEX(mvString result,
ConstantString substr,
ConstantString numexpr)
result - the starting positionsubstr - the substring to be searched for.numexpr - the occurrance number of the substr.
public abstract int intValue()
public abstract boolean isIntegral()
public abstract boolean isNumeric()
public mvString LEN(mvString mvn)
mvn - the number to store the length
public abstract int length()
public ConstantString LOCATEI(mvString location,
ConstantString element,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString start,
ConstantString searchtype)
location - the string to hold the resulting positionelement - element to search for.attrib - attribute to search throughval - value to search throughsubval - subvalue to search throughstart - index of search startsearchtype - type of search ie 'AL', 'AR', 'DL', 'DR'
public ConstantString LOCATEP(mvString location,
ConstantString element,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString start,
ConstantString searchtype)
location - the string to hold the resulting positionelement - element to search for.attrib - attribute to search throughval - value to search throughsubval - subvalue to search throughstart - index of search startsearchtype - type of search ie 'AL', 'AR', 'DL', 'DR'
public ConstantString LE(MathInterface m,
ConstantString a)
public abstract long longValue()
public mvString LOWER(mvString result)
result - string to contain the raised value
public ConstantString LT(MathInterface m,
ConstantString a)
public ConstantString MATCH(ConstantString pattern)
pattern - the pattern to match
public ConstantString NOT()
public mvString NUM(mvString mvn)
public ConstantString OR(ConstantString a)
public mvString RAISE(mvString result)
result - string to contain the raised value
public mvString REPLACE(mvString result,
ConstantString attrib,
ConstantString val,
ConstantString subval,
ConstantString replace)
result - string to contain the replaced entryattrib - attribute positionval - value mark positionsubval - subvalue mark postionreplace - mvString to be inserted
public void SELECT(Program program,
mvString result,
Key key)
throws mvException
program - the program the select list is bound toresult - the string to contain the select listkey - criteria for the query
mvExceptionpublic mvString SEQ(mvString mvn)
mvn - The number to contain the ascii value
public mvString SPACE(mvString result)
result - the string to hold the spaces
public mvString SQUOTE(mvString result)
public mvString STR(mvString result,
ConstantString count)
result - the string to hold the repeated substringscount - the number of repetitions
public mvString SUM(mvString result,
ConstantString begin,
ConstantString end)
public abstract java.lang.String toString()
public mvString TRIM(mvString result,
ConstantString chr,
ConstantString type)
result - to hold the trimmed stringchr - the character to be trimmedtype - the type of trim to do.public mvString UPCASE(mvString result)
public mvString XTD(mvString result,
ConstantString width)
result - the string into which to place the outputwidth - the minimum size of the result
If width is specified and the number is of insufficient length
the resulting string is padded with leading zeroes
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||