ANTAREX API

Clava API

LARA API

LARA Common Language API

Global Functions

getClassNameMethod

getClassNameMethod(m)

Parameters

m: any

Returns

any - the name of the class of a method (m)

getEffectiveParameters

getEffectiveParameters($target)

Parameters

$target: any

getFileOf

getFileOf($vtree)

Parameters

$vtree: any

Returns

any - the file of an ast object.

getFileSeparator

getFileSeparator()

getFormalParameters

getFormalParameters($target)

Parameters

$target: any

getFunctionOrMethod

getFunctionOrMethod($stmt)

Parameters

$stmt: any

Returns

any - the function, the method or undefined of a statement ($stmt).

getStrClassOf

getStrClassOf($fm)

Parameters

$fm: any

Returns

any - the name of the class of a method, empty string for a function.

getStrNameParams

getStrNameParams($target)

Parameters

$target: any

Returns

any - a string (p1,...pn) where the pi is a name of the i-th parameter of a function ($target).

getStrNameParams0

getStrNameParams0($params, bprefix)

Parameters

$params: any
bprefix: any

Returns

any - a string p1,...pn where the pi is a name of the i-th parameter of a function ($target).

getStrParams

getStrParams($target)

Parameters

$target: any

Returns

any - a string (delc1,...decln) where decli is the i-th formal parameter a function/method ($target).

getStrParams0

getStrParams0($params, bprefix)

Parameters

$params: any
bprefix: any

Returns

any - a string delc1,...decln where decli is the i-th formal parameter a function/method ($target).

getStrReturnType

getStrReturnType($target)

Parameters

$target: any

Returns

any - the code of the returned type of a function/method ($target).

insertElem

insertElem(varray, velem)

Insert a element ($velem) in an array (tabDecl). It ensures the unicity of element in varray.

Parameters

varray: any
velem: any

isAConstantDecl

isAConstantDecl($vstmt)

Parameters

$vstmt: any

Returns

any - true if a statement ($vstmt) is a declaration of a constant, false otherwise.

isGlobalVariable

isGlobalVariable($vardecl)

Parameters

$vardecl: any

Returns

any - true if a declaration ($vardecl) is a global one, false otherwise.

isParameterDeclaration

isParameterDeclaration($aDecl)

Parameters

$aDecl: any

isaFunction

isaFunction($vFunction)

Parameters

$vFunction: any

Returns

any - true if $vFunction is a function, false otherwise.

isaMethod

isaMethod($vFunction)

Parameters

$vFunction: any

Returns

any - true if $vFunction is a method, false otherwise.

mkCallToRenamed

mkCallToRenamed($function, $name)

Parameters

$function: any
$name: any

Returns

any - a call $name(p1,...pn) where the pi is a name of the i-th parameter of a function ($function).

printArray

printArray(varray, message)

Insert a element ($velem) in an array (tabDecl). It ensures the unicity of element in varray.

Parameters

varray: any
message: any

printChildrenOf

printChildrenOf($statement)

Debugging

Parameters

$statement: any

renameFunctionMethod

renameFunctionMethod($fm, name)

Renames a function or a method ($fm) by name.

Parameters

$fm: any
name: any