Siebel eScript Language Reference > C Language Library Reference > Overview of the Clib Object >

Using Siebel eScript Methods Instead of Clib Methods


Table 123 lists each Clib method that has an equivalent method in Siebel eScript. These methods are redundant because their functionality already exists in Siebel eScript. Where possible, you must use the Siebel eScript method instead of the equivalent Clib method. In some situations the Clib method is preferred and is more consistent in a section of script. For example, when working with a string routine that expects a null string.

Table 123. Siebel eScript You Can Use Instead of Clib Methods
Siebel eScript Method
Clib Method
Description

Get Absolute Value Method

abs

Calculates absolute value.

Get Arc Cosine Method

acos

Calculates the arc cosine.

Get Arcsine Method

asin

Calculates the arc sine.

Get Arctangent Method

atan

Calculates the arc tangent.

Get Arctangent 2 Method

atan2

Calculates the arc tangent of a fraction.

Convert String to Floating-Point Number Method

atof

Converts a string to a floating-point number.

Convert String to Integer Method

atoi

Converts a string to an integer.

Automatic conversion

atol

Converts a string to a long integer.

Get Ceiling Method

ceil

Rounds a number up to the nearest integer.

Get Cosine Method

cos

Calculates the cosine.

Get Exponential Method

exp

Calculates the exponential function.

Math absolute

fabs

Calculates the absolute value of a floating-point number.

Get Floor Method

floor

Rounds a number down to the nearest integer.

% operator, modulo

fmod

Calculates the remainder.

Math absolute

labs

Returns the absolute value of a long.

Get Logarithm Method

log

Calculates the natural logarithm.

Get Maximum Method

max

Returns the largest of one or more values.

Get Minimum Method

min

Returns the smallest of one or more values.

Raise Power Method

pow

Calculates x to the power of y.

Get Sine Method

sin

Calculates the sine.

Get Square Root Method

sqrt

Calculates the square root.

+ operator

strcat

Appends one string to another.

== operator

strcmp

Compares two strings.

= operator

strcpy

Copies a string.

Get String Length Method

strlen

Gets the length of a string.

Change String to Lowercase Method

strlwr

Converts a string to lowercase.

Automatic conversion

strtod

Converts a string to decimal.

Automatic conversion

strtol

Converts a string to long.

Change String to Uppercase Method

strupr

Converts a string to uppercase.

Get Tangent Method

tan

Calculates the tangent.

string.toLowerCase

tolower

Converts a character to lowercase.

string.toUpperCase

toupper

Converts a character to uppercase.

The phrase automatic conversion in the Siebel eScript Method column means that Siebel eScript implicitly performs a conversion. For example, when comparing Siebel eScript to the atol Clib method, if the variable that will hold the converted string is of type Number, then Siebel eScript implicitly converts the string from a string to a long integer.

Siebel eScript Language Reference Copyright © 2013, Oracle and/or its affiliates. All rights reserved. Legal Notices.