Biferno Language Reference Guide

Tabasoft S.a.s.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled Appendix 1, GNU Free Documentation License.


Table of Contents

1. Biferno Functions Reference
print function - Outputs a string
Eval function - Processes a string of text containing Biferno code
includeFile function -
includeFolder function -
2. Biferno ansi Class Reference
ansi class -
random method -
srandom method -
strch method -
strcmp method -
strcspn method -
strncat method -
strncmp method -
strncpy method -
strpbrk method -
strrch method -
strspn method -
strstr method -
3. Biferno array Class Reference
array class -
array method -
Add method -
Count method -
Delete method -
Find method -
GetElemClass method - Return the array element of class
Index method -
Insert method -
Max method -
Min method -
Reset method -
Reverse method -
SetDim method -
SetElemClass method -
Sort method -
SubArray method -
Swap method -
ToString method -
dim property -
name property -
asc constant -
bubble constant -
desc constant -
shell constant -
ErrBadElementName error -
ErrBadEndIndex error -
ErrBadStartIndex error -
4. Biferno biferno Class Reference
biferno class -
applications property -
classes property -
compilationFlags property -
functions property -
home property -
maxUsers property -
os property -
poolFactor property -
upSince property -
version property -
versionNum property -
5. Biferno boolean Class Reference
boolean class -
boolean method -
6. Biferno byte Class Reference
byte class - Same as int
7. Biferno cacheItem Class Reference
cacheItem class -
cacheItem method -
Flush method -
averageExecTime property -
currentUsers property -
hits property -
lastAccess property -
lastExecTime property -
maxExecTime property -
minExecTime property -
totExecTime property -
userPath property -
8. Biferno char Class Reference
char class -
char method -
ascii property -
9. Biferno classInfo Class Reference
classInfo class -
classInfo method -
GetErrorDescription method -
IsDef method -
cloneIsNeeded property -
constants property -
descr property -
errors property -
extendedClass property -
implem property -
methods property -
note property -
persistentAllowed property -
properties property -
purpose property -
seeAlso property -
sourcePath property -
wantDestructor property -
biferno constant -
c constant -
10. Biferno client Class Reference
client class -
GetIndSID method -
SessionVariable method -
address property -
fromUser property -
ipAddress property -
password property -
user property -
userAgent property -
11. Biferno curApp Class Reference
curApp class - Porvides informations about current app
Flush method - Flush the cache
GetPubVariable method -
Publish method - Makes a variable visible to other apps
RegisterNewApp method - Initializes an application
Reload method - Reload the application
Unpublish method - Undoes a Publish call
cacheItems property - List of files in cache
cacheTotItems property - Total files in cache
cacheTotSize property - Total size of cache
children property - List of subapplication
childrenHomes property -
classes property - List of application classes
functions property - List of application functions
home property - The path of the folder containing the application
name property - The name of the application
12. Biferno curFile Class Reference
curFile class - Provides informations about the current file in process
basePath property - The path of the folder containing the file
cache property -
curLine property -
fromCache property -
path property -
13. Biferno curScript Class Reference
curScript class - Get/Set infos about the current script
Delay method - Temporarily suspends execution
GetCustomOutput method - Custom output function name
GetIndVariable method - Get variables list of current script
GetIndVariableRef method -
GetNumFormat method - Get the current decimal and thousand separators
GetStack method -
GetTotVariables method - Total variables of current script
IsDef method - Checks if a variable is defined
LaunchProcess method - Launch a process from the current script
SetCustomOutput method - Installs function for redirecting script output
SetNumFormat method - Specify decimal and thousand separators for current script
SetStandardOutput method - Restores default output function
Undef method - Deletes a variable
ValueOf method - Evaluates a single line of code
basePath property - The base path of the current script
currentThreads property -
maxThreads property -
timeout property - The timeout of the script
14. Biferno db Class Reference
db class -
db method -
Bind method -
BindAll method -
Call method -
CallExt method -
Commit method -
Escape method -
Exec method -
ExecPrepared method -
FetchRec method -
Free method -
FreePrepare method -
GetAffectedRecs method -
GetCurRecs method -
GetPrepared method -
GetSpecific method -
LobRead method - Reads a portion of a LOB/FILE, as specified by the call, into a string.
LobWrite method - Writes a string into a LOB
Prepare method -
RealEscape method -
RealUnescape method -
RollBack method -
RowSetSize method -
Seek method -
SetSpecific method -
Tell method -
Transaction method -
Warning method -
defaultMode constant -
dynamicMode constant -
inputBindMode constant -
inputOutputBindMode constant -
null constant -
outputBindMode constant -
staticMode constant -
ErrBadCursorID error -
ErrBadCursorMode error -
ErrBadPrepareID error -
ErrBadSeekIndex error -
ErrDBMSError error -
ErrGettingAffectedRecs error -
ErrGettingCurRecs error -
ErrInvalidFree error -
ErrNoCursorAvailable error -
ErrNotEnoughStorageForRecord error -
ErrTooManyCursors error -
ErrTooManyPrepares error -
ErrUndefinedBindVariable error -
ErrUnknownDBType error -
ErrUnknownSpecific error -
15. Biferno double Class Reference
double class - 8-bytes floating point number
double method - Creates an object of class double
Abs method -
Cos method -
Hex method - Hexadecimal representation
Int method -
Pow method -
Round method -
Sin method -
Sqr method -
Sqrt method -
ToString method -
pi constant -
16. Biferno error Class Reference
error class -
error method -
Function method -
Resume method -
State method -
Suspend method -
ThrowException method -
Update method -
classNote property -
descr property -
errClass property -
errNum property -
fileOffset property -
lastMultiStrLine property -
line property -
lineNum property -
msg property -
name property -
path property -
resumable property -
subErr property -
subErrDescr property -
table property -
Err_AbsolutePathRequired error -
Err_ApplicationNameDuplicated error -
Err_ApplicationNameNotFoundInConfig error -
Err_ApplicationNameTooLong error -
Err_ArrayElementNotFound error -
Err_ArrayElementsTypeCastFailed error -
Err_ArrayMismatch error -
Err_ArrayRequired error -
Err_AttachCurrentThreadException error -
Err_BadArrayIndex error -
Err_BadBifernoSID error -
Err_BadBlockSize error -
Err_BadFileRef error -
Err_BadMemoryRef error -
Err_BadPrototype error -
Err_BadSyntax error -
Err_BadSyntaxInApplicationName error -
Err_BadSyntaxInURL error -
Err_BAPI_BifernoTooNew error -
Err_BAPI_BifernoTooOld error -
Err_BAPI_BufferTooSmall error -
Err_BAPI_EndOfObject error -
Err_BAPI_ErrorsAlreadyRegistered error -
Err_BAPI_ExtensionNameRequired error -
Err_BAPI_ExtensionTooNew error -
Err_BAPI_ExtensionTooOld error -
Err_BAPI_InvalidAPIData error -
Err_BAPI_InvalidParameter error -
Err_BAPI_LoopAbort error -
Err_BAPI_MessageNotHandled error -
Err_BAPI_ObjAlreadyToDestruct error -
Err_BAPI_ObjNotPrintable error -
Err_BAPI_ObjNotToDestruct error -
Err_BAPI_SymbolNotFound error -
Err_BAPI_UnknowExtensionType error -
Err_BifernoConfigNotFound error -
Err_BuffersBadID error -
Err_BuffersNotInitialized error -
Err_CacheNotInitialized error -
Err_CachePathTooLong error -
Err_CantAccessThisMember error -
Err_CantCloseShLib error -
Err_CantFindShLibSymbol error -
Err_CantLoadShObject error -
Err_CantModifyLength error -
Err_ClassError error -
Err_ClassIsStatic error -
Err_ClassRedeclared error -
Err_CommaOrRoundSquareExpected error -
Err_ConnectionBroken error -
Err_ConvertingStringToLong error -
Err_CookieDisabled error -
Err_CurlyBracketExpected error -
Err_CurlyBracketNotBalanced error -
Err_DateTimeFormatError error -
Err_DuplicatedArrayElemName error -
Err_DuplicatedConstructor error -
Err_DuplicatedFile error -
Err_DuplicatedLabel error -
Err_DuplicatedObject error -
Err_DuplicatedParameter error -
Err_DuplicatedPropertyName error -
Err_EmptyExpression error -
Err_EmptyName error -
Err_EndOfFile error -
Err_EndOfLineOrSemicolonExpected error -
Err_ExplicitTypeCastRequired error -
Err_FileNotFound error -
Err_FolderIsNotEmpty error -
Err_FolderNotFound error -
Err_FreeBlock error -
Err_FunctionIsVoid error -
Err_FunctionRedeclared error -
Err_HTTPBodyTooLong error -
Err_IllegalArrayInURL error -
Err_IllegalAssignment error -
Err_IllegalConstantExpression error -
Err_IllegalConstantParameter error -
Err_IllegalDeclaration error -
Err_IllegalFlowControl error -
Err_IllegalOperation error -
Err_IllegalOperationOnConstant error -
Err_IllegalOperationOnMethod error -
Err_IllegalRef error -
Err_IllegalScopeForObject error -
Err_IllegalSetProperty error -
Err_IllegalTypeCast error -
Err_IllegalUndef error -
Err_InvalidArrayIndex error -
Err_InvalidCharacter error -
Err_InvalidErrorValue error -
Err_InvalidEscapeSequence error -
Err_InvalidIndex error -
Err_InvalidLength error -
Err_InvalidListRef error -
Err_InvalidListType error -
Err_InvalidName error -
Err_InvalidParameter error -
Err_InvalidParameterName error -
Err_InvalidPosition error -
Err_InvalidRefParameter error -
Err_InvalidScope error -
Err_InvalidSessionCookie error -
Err_InvalidVariableType error -
Err_JavaNotAvailable error -
Err_JVMLoadFailed error -
Err_LabelNotFound error -
Err_ListBufferTooSmall error -
Err_ListDontAcceptNames error -
Err_ListIsLocked error -
Err_ListOutOfBoundary error -
Err_LockNotSupported error -
Err_MemberIsNotStatic error -
Err_MemberIsStatic error -
Err_MemberOnUndefinedIdentifier error -
Err_MemoryFull error -
Err_MemorySlotsFull error -
Err_MethodNameConflict error -
Err_MultipartObjectDuplicated error -
Err_NameTooLong error -
Err_NoResolveOnDupList error -
Err_NoSuchApplication error -
Err_NoSuchClass error -
Err_NoSuchClassOrFunction error -
Err_NoSuchConstant error -
Err_NoSuchFunction error -
Err_NoSuchMember error -
Err_NoSuchMethod error -
Err_NoSuchProperty error -
Err_NotAllowedInDestructor error -
Err_NotAnExtendingClass error -
Err_NotImplemented error -
Err_NullSizeBlock error -
Err_ObjectCantBePersistent error -
Err_ObjectIsLocked error -
Err_ObjectNotFound error -
Err_OnErrorNotBalanced error -
Err_OperatorExpected error -
Err_OSError error -
Err_OutOfBoundary error -
Err_Overflow error -
Err_PageInNotDefined error -
Err_PageOutNotDefined error -
Err_ParameterNameTooLong error -
Err_PathTooLong error -
Err_ProcessShutDown error -
Err_PropertyIsOnlyRead error -
Err_PrototypeMismatch error -
Err_QuotesExpected error -
Err_RefParameterRequired error -
Err_ReservedKeyword error -
Err_ReturnValueRequired error -
Err_RoundBracketExpected error -
Err_RoundBracketNotBalanced error -
Err_ScopeConflict error -
Err_SessionIsDisabled error -
Err_SlotMgrUnavailable error -
Err_SquareBracketExpected error -
Err_StackOverflow error -
Err_StringTooLong error -
Err_SuperConstructorRequired error -
Err_SuperIsUndefined error -
Err_TextUtilsNotInitialized error -
Err_ThisIsUndefined error -
Err_ThreadNotFound error -
Err_ThreadsInternalErr error -
Err_ThreadTimeout error -
Err_Timeout error -
Err_TooLongDefault error -
Err_TooLongHexLiteral error -
Err_TooLongName error -
Err_TooManyIncludes error -
Err_TooManyVariablesInExpression error -
Err_UndefinedIdentifier error -
Err_UnknownError error -
Err_UnknownGroup error -
Err_UnknownOperator error -
Err_UnknownUser error -
Err_UnknownXLibError error -
Err_UnknownXLibHelpersError error -
Err_VariableDuplicatedInURL error -
Err_VariableNotDefined error -
Err_VariableNotInitialized error -
Err_VariableNotPublished error -
Err_WalkFolderAbort error -
Err_XLibCallerTooNew error -
Err_XLibCallerTooOld error -
Err_XLibTooNew error -
Err_XLibTooOld error -
UserBreak error -
17. Biferno file Class Reference
file class -
file method -
Append method -
BifernoPath method -
CheckPath method -
Close method -
Copy method -
Delete method -
Exists method -
fchmod method -
fgetmod method -
Flush method -
Get method -
GetNextLine method -
IsAlias method -
IsFolder method -
IsOpen method -
Lock method -
MakeAlias method -
Move method -
NativePath method -
Open method -
Put method -
Rename method -
ResolveAlias method -
ResolvePath method -
symlink method -
Unlock method -
creatTime property -
curLine property -
curPos property -
group property -
isAlias property -
isOpen property -
length property -
modifTime property -
name property -
openMode property -
osCreator property -
osType property -
path property -
permission property -
resForkLength property -
user property -
all constant -
createFileAlways constant -
createFileNew constant -
dontOpen constant -
EOF constant -
isAliasBit constant -
isFolderBit constant -
openFileAlways constant -
openFileExisting constant -
r constant -
rw constant -
S_IRGRP constant -
S_IROTH constant -
S_IRUSR constant -
S_IWGRP constant -
S_IWOTH constant -
S_IWUSR constant -
S_IXGRP constant -
S_IXOTH constant -
S_IXUSR constant -
ErrBadLen error -
ErrBadName error -
ErrBadOffset error -
ErrBadOpenMode error -
ErrBadOSTypeOrCreator error -
ErrBadPermission error -
ErrCantOpenAlias error -
ErrFileIsNotOpen error -
ErrItemIsFolder error -
ErrNoMoreLinesInFile error -
18. Biferno float Class Reference
float class - Same as double
19. Biferno folder Class Reference
folder class -
folder method -
Create method -
Delete method -
fchmod method -
fgetmod method -
MakeAlias method -
Rename method -
Walk method -
creatTime property -
group property -
modifTime property -
name property -
openMode property -
path property -
user property -
createFolderIfNeeded constant -
createFolderNew constant -
folderExisting constant -
S_IRGRP constant -
S_IROTH constant -
S_IRUSR constant -
S_IWGRP constant -
S_IWOTH constant -
S_IWUSR constant -
S_IXGRP constant -
S_IXOTH constant -
S_IXUSR constant -
ErrBadName error -
ErrBadOpenMode error -
ErrFolderExists error -
ErrFolderNotFound error -
ErrItemIsAlias error -
ErrItemIsNotFolder error -
20. Biferno header Class Reference
header class - HTTP header manipulation
header method - Initializes an header class instance
AddField method - Add field to HTTP header
GetField method - Read the content of HTTP header field
RemoveField method - Removes an HTTP field from the header
SetField method - Modify an HTTP header field
ErrHeaderFieldNotFound error -
ErrInvalidHeader error -
21. Biferno httpPage Class Reference
httpPage class - TCP/IP socket HTTP communication
httpPage method - httpPage class constructor
Exec method - Remote Execution of Internet Resources
body property - Body of the HTTP packet
head property - Header of HTTP packet
ErrResponseHeaderIsInvalid error -
ErrServerRespondedNoData error -
22. Biferno imageUtils Class Reference
imageUtils class -
ConvertImage method -
BesselFilter constant -
BlackmanFilter constant -
BoxFilter constant -
CatromFilter constant -
CubicFilter constant -
GaussianFilter constant -
HammingFilter constant -
HanningFilter constant -
HermiteFilter constant -
LanczosFilter constant -
MitchellFilter constant -
PointFilter constant -
QuadraticFilter constant -
SincFilter constant -
TriangleFilter constant -
UndefinedFilter constant -
23. Biferno int Class Reference
int class - Positive and negative numbers
int method - Create an int number
Abs method -
Cos method -
Hex method - Hexadecimal representation
Pow method -
Sin method -
Sqr method -
Sqrt method -
ToString method -
24. Biferno jclass Class Reference
jclass class - Calling java code from Biferno
jclass method - Connects to a java class
new method - Creates a new java instance and a new jclass object pointing it.
null property - Reference to a Java null object
Err_JavaClassNotFound error -
Err_JavaException error -
Err_JavaFieldNotFound error -
Err_JavaStringTooLong error -
Err_JClassError error -
25. Biferno long Class Reference
long class - 8 byte representation numbers
long method -
Abs method -
Cos method -
Hex method - Hexadecimal representation
Pow method -
Sin method -
Sqr method -
Sqrt method -
ToString method -
26. Biferno memberInfo Class Reference
memberInfo class - Describes e generic member of a class or a function
memberInfo method - Creates a memeberInfo object
IsDef method - Checks if a member exists
className property - Class owning the member
descr property - Description of the member
errors property - Possible errors throwed
implem property - Implementation
isConst property - Constant properties
isStatic property - Static member
memberType property - The type of the member
name property - The name of the member
nonames property - Detecting members with nonames clause declaration
note property - Additional notes
paramAeClass property - Array class of Parameters
paramAeLevel property - Array level of the parameters
paramClass property - Classes of the parameters
paramDefault property - Default values of the parameters
paramDescr property - Descriptions of each parameter
paramName property - Name of the parameters
paramTarget property -
prototype property - Member prototype
purpose property - The purpose of the member (this field)
returnAeClass property - The class of the returned array elements (if any)
returnAeLevel property - The return array level
returnClass property - The class of the return value
returns property - What does the member return
seeAlso property - Useful links
sourcePath property - Source file path
totParams property - Total parameters in prototype
varArgs property - Variable number of arguments
visibility property - Member accessibility
biferno constant - Biferno written member
c constant - C written member
27. Biferno multipart Class Reference
multipart class - Class to handle multipart/form-data file objects
multipart method - Instantiates a multipart object
ToFile method - Write on disk a multipart object
contentType property - The content type of the file
data property - Content of the file
name property - The name of the file
path property - the path of the file
28. Biferno object Class Reference
object class - Get/set infos about objects
ConstructorString method - Returns a string representing the parameters to pass to the constructor to obtain the same object
Create method -
DebuggerString method - Returns a string representing the object as displayed in the debug error page
Hide method - Hides value in debug error table
IsHidden method -
IsInitialized method - Checks if a variable is initialized
Lock method - Prevent object modification
Show method - Undoes the Hide method
Unlock method - Undoes lock operation on object
ValueOfInput method - Correct value to insert in URL
29. Biferno ref Class Reference
ref class -
ref method -
GetTargetInfo method -
target property -
30. Biferno regexp Class Reference
regexp class -
regexp method -
Match method - Matches a regular expression against a text.
eoff property - An array of offsets containing information on regular expression match.
notbol property - Flag to control regular expressions evaluation.
noteol property - Flag to control regular expressions evaluation.
soff property - An array of offsets containing information on regular expression match.
defaultvalue constant -
extended constant -
icase constant -
newline constant -
nosub constant -
ErrRegExp error - Error in regular expression processing.
31. Biferno request Class Reference
request class - Allows to obtain informations on the request for a Biferno script
GetField method - Get a field of the header request
Redirect method - Redirects client request
contentType property - multipart/form-data encoding type
fileName property - The requested file name
filePath property - path requested
host property - Address of web site
method property - The request method
physicalPath property - Physical path requested
port property -
protocol property - The request protocol
referer property - Page originating the request
scheme property -
searchArg property - Parameter list
url property - The url requested
32. Biferno search Class Reference
search class -
search method -
SetOption method -
ToSQL method -
findType property -
group property -
mode property -
oper property -
string property -
tot property -
all constant -
allNot constant -
and constant -
andNot constant -
begins constant -
closePar constant -
contains constant -
ends constant -
noPar constant -
openPar constant -
or constant -
orNot constant -
ErrIndexRequired error -
ErrSearchElementTooLong error -
ErrUnsupportedMode error -
33. Biferno serverInfo Class Reference
serverInfo class - Information on the Web server
domain property - Server domain name
root property - Document root of the web server or site
serverName property - Name of the web server
34. Biferno short Class Reference
short class - Same as int
35. Biferno smtp Class Reference
smtp class - Sending email with Biferno
GetMXRecords method - Get the MX (Mail Exchange) records of a domain
ParseMailFile method - Read an xml Biferno spool file
SendMail method -
SendMailAsync method - Begins a send of an asyncronous email message
SendMailFile method - Sends a spool mail file
ErrAuthTooLong error -
ErrNetDNR error -
ErrNetLostConnection error -
ErrNetOpenDriver error -
ErrNetOpenStream error -
ErrNetTruncated error -
ErrSmtpError error -
36. Biferno stackItem Class Reference
stackItem class -
classOwner property -
filePath property -
line property -
prototype property -
37. Biferno string Class Reference
string class - handle stream of characters
string method - Creates a string object
Begins method - Checks if a string starts with another string
Bin2Hex method -
Capitalize method - Uppercase first character of all words in a string
Compare method - Compares two strings
Contains method - Establishes if a string contains another string
ContainsWordBegin method - Determines if the string that the method is applied to contains a word beginning with the string passed as parameter
ContainsWordEnd method - Determines if the string that the method is applied to contains a word ending with the string passed as parameter
ContainsWordExact method - Determines if the string that the method is applied to contains a word matching exactly the string passed as parameter.
Decode method - ISO 8859-1 Format Decoding
Encode method - ISO 8859-1 Format Encoding
Ends method - Checks if a string ends with another string
Escape method - Escapes a string
Find method - Look for a substring in a string
Hex2Bin method -
Hilite method -
HTUUDecode method - Convert a string from RFC 1113 printable encoding format
HTUUEncode method - Convert a string to RFC 1113 printable encoding format
In method - Compare string at the same time with several different strings
InsertSubString method - Insert string in another
IsANSIStandard method - Check for chars > 127 in string
IsDate method - Check the string for a valid date
IsEMail method - Checks if the string can be a correct email
IsNumeric method - Check the string for a valid number format
Log method - Writes to Biferno log files
LowToUpper method - Transforms lowercase characters into uppercase in a string
MD5 method - Calculates the md5 hash of a string
Pad method - Pads string with characters
RemoveSubString method - Removes a certain number of characters from a string
Substitute method - Replaces a substring of the given string with another
SubString method - Returns a substring of any length of the given string
ToArray method - Converts a string into an array of strings
UpToLower method - Transforms uppercase characters into lowercase in a string
UrlDecode method - Decode URLs
UrlEncode method - Encode URLs
Zap method - Zap gremlins from string
char property - Characters of the string
length property - The length of the string
allTags constant -
htmlTags constant -
ErrBadIndex error -
ErrBadLength error -
ErrTooLongSeparator error -
38. Biferno time Class Reference
time class - Supports manipulation of date and time in various formats.
time method - Initialize a time object
Date method - Returns the Date component of a time variable
GMT method - Timestamp value corresponding to the Greenwich time zone
Hour method - Returns the Hour component of time variable
In method - Checks if time is in a range
Millisecs method - Milliseconds from startup
Strftime method - Time string formatting
ToSecs method - Returns the timestamp of a time variable
UString method - String in the Universal Time format
day property - The day
dayOfWeek property - Day of the week
format property - Format of time variable as passed to constructor
hour property -
minute property - The minutes
month property - the month
second property - The second
year property - The year
friday constant -
monday constant -
saturday constant -
sunday constant -
thursday constant -
tuesday constant -
wednesday constant -
ErrInvalidTimeString error -
39. Biferno unix Class Reference
unix class - UNIX utilities
bash method - Executes unix shell commands (using /bin/bash)
getenv method - Returns value for environment name
getgroup method - The name of the current group
getuser method - The name of the current user
putenv method - Change or add value to environment
setenv method - Change or add an environment variable
unsetenv method - Deletes environment variable
40. Biferno unsigned Class Reference
unsigned class - 4 byte unsigned representation number
unsigned method -
Abs method -
Cos method -
Hex method - Hexadecimal representation
Pow method -
Sin method -
Sqr method -
Sqrt method -
ToString method -
ToTime method - Seconds to time variable
41. Biferno cookie Class Reference
cookie class - Manages client cookies
Get method - Gets the value of a cookie
GetAll method - Retrieves all cookies
GetArray method - Returns an array containing cookies
Set method - Sets a cookie with all parameters
SetPersistent method - Sets a persistent cookie
SetTemp method - Sets a temporary cookie
42. Biferno folderExt Class Reference
folderExt class - Add folder utilities to folder class
Copy method - Copies a folder with its content
43. Biferno headerExt Class Reference
headerExt class - Semplifies HTTP header handling
AddHeader method - Add reposnse header field
GetHeader method - Get an header field of request
SetHeader method - Add/Set reposnse header field
44. Biferno httpExt Class Reference
httpExt class - HTTP connection utilities
ExecRemote method - Retrieves an URL from the WWW
45. Biferno jclassExt Class Reference
jclassExt class - Extends jclass
jclassExt method - Instantiate a "jclassExt" biferno object
DoThumbnail method - Creates a thumbnail from an image
46. Biferno mailAttach Class Reference
mailAttach class -
mailAttach method -
add_attach method -
GetErrMessage method -
send method -
set_async method -
set_from method -
set_message_html method -
set_message_txt method -
set_subject method -
set_timeout method -
set_to method -
tostring method -
async property -
attach property -
attach_mime property -
attach_name property -
class_name property -
from property -
host property -
mailOut property -
message_html property -
message_txt property -
sender_account property -
subject property -
timeout property -
to property -
ErrAsyncFolderNotFound error -
ErrMissingFromField error -
ErrMissingHostField error -
ErrMissingToField error -
47. Biferno requestExt Class Reference
requestExt class -
Redirect method -
48. Biferno smtpExt Class Reference
smtpExt class - SMTP utilities
SendMailWithAttachments method - Send a mail with also attachments
49. Biferno utils Class Reference
utils class - Some utils
Alert method - Display of a javascript alert
1. GNU Free Documentation License
Index

Chapter 1. Biferno Functions Reference

Table of Contents

print function - Outputs a string
Eval function - Processes a string of text containing Biferno code
includeFile function -
includeFolder function -

Name

print — Outputs a string

Synopsis

void print(str);
string str;

Description

Allows to print (insert on the Biferno script output) the value of a variable, a constant, or the result of an expression

Parameters

str

the string to print

Note

Instead of the print keyword it is possible to use the dollar symbol, $$. Using the dollar symbol before and after a variable name, its value can be printed outside of the Biferno code delimiters. This is shown in the following example, where the “val” parameter is passed to the “newpage.bfr” page and takes the value of the myString variable, which is output on the HTML page using the $$ symbol set before and after the variable name. The delimiter tags of the Biferno code are not used. The next row of code shown an alternative manner of obtaining the same result using the print function.

<?
	myString = "Hello World"
?>
<html><body>
<?
	//Print the value of the myString variable
	print(myString)
	//Same effect as previous instruction
	$$myString
?>
<br>
<a href="newpage.bfr?val=$$myString$$">Nuova Pagina</a>
<a href="otherpage.bfr?val=<? print(myString) ?>">Other Page</a>
</body></html>

Name

Eval — Processes a string of text containing Biferno code

Synopsis

string Eval(text, resume);
string text;
boolean resume;

Description

The Eval function processes a string of text containing Biferno code. We can write:

textToEval = "a = 3"
Eval(textToEval)
$a

line 3 of the example will print the value of the variable a, which is 3. The a variable has been defined and assigned the value 3 when the text passed to the Eval function was processed.

Notice that the textToEval string does not start with the "<?" characters. This is because the Eval implicitly assumes a "<?" tag before processing the text. If the textToEval string contains plain text, the text would have to be prefixed with the "?>" characters. An example is:

textToEval = "a = 3?><b>Hello Word</b>"
result = Eval(textToEval)
$result

Notice that this behavior is different from the include behavior. In an included file, before writing Biferno code, the "<?" must be explicitly used.

The last example also shows the meaning of the return variable of the function, which contains the entire text sent as output during execution. The first example generated no output, and the function returned the empty string. In the second example the result string contains the text: "<b>Hello Word</b>".

Parameters

text

the text to process

resume

specifies the resum mode (see note)

Returns

contains the entire text sent as output during execution of text.

Note

What happens if the text passed to the Eval function (textToEval string) generates an error?

In this case the value of the third parameter (resume, left to its default value, false, in the previous examples) is crucial. If an error is generated the following applies:

resume is false: we can control if Eval will interrupt our script using the error.Resume function in the textToEval string with the usual error handling rules. Notice that some errors will interrupt code execution even if error.Resume has been called, as e.g. the Err_BadSyntax error. In any case, the code line after the call to the Eval function the global variable err will contain the code of the generated error.

resume is true: the Eval function will interrupt the execution of the text contained in textToEval according to the error handling rules, but, instead of interrupting the execution of the calling script upon an error, will return the name of the generated error in the return string. In any case, on the code line after the call to the Eval function the global variable err will contain the code of the generated error.


Name

includeFile —

Synopsis

int includeFile(filePath,  
 variant); 
string  filePath;
int  variant;

Description

n.a.

Parameters

filePath

n.a.

variant

n.a.


Name

includeFolder —

Synopsis

void includeFolder(folderPath,  
 recursive); 
string  folderPath;
boolean  recursive;

Description

n.a.

Parameters

folderPath

n.a.

recursive

n.a.

Chapter 2. Biferno ansi Class Reference

Name

ansi —

Synopsis

The ansi class.c

Implemented in the C language.

Description

This class implements some useful ANSI functions in Biferno


Name

random —

Synopsis

int random();

Description

Gets a random number

Returns

The number


Name

srandom —

Synopsis

void srandom(seed);
int seed;

Description

Reinitialize the machine seed to get random numbers (with method.ansi.random)

Parameters

seed

A number to use to restart the random sequence. If 0, the computer clock is used.

Returns

Nothing


Name

strch —

Synopsis

string strch(str, ch);
string str;
char ch;

Description

Locates the first occurrence of char ch in string str

Parameters

str

The string to search in

ch

The character to search for

Returns

A copy of string str starting from the first occurrence until end, or an empty string if ch was not found


Name

strcmp —

Synopsis

int strcmp(str1, str2);
string str1;
string str2;

Description

Compares string str1 with string str2

Parameters

str1

The first string

str2

The second string

Returns

A positive integer if s1 > s2, 0 if s1 == s2, a negative integer if s1 s2


Name

strcspn —

Synopsis

int strcspn(str1, str2);
string str1;
string str2;

Description

Computes the length of the maximum initial segment of string str1 that consists entirely of characters that are not from string str2

Parameters

str1

The first string

str2

The second string

Returns

The length of the segment


Name

strncat —

Synopsis

string strncat(str1,  
 str2,  
 n); 
string  str1;
string  str2;
int  n;

Description

Returns a new string appending string str2 to string str1 until it has appended n characters or it has reached the end of string str2

Parameters

str1

The first string

str2

The second string

n

Max chars to append to str1

Returns

The string result of operation


Name

strncmp —

Synopsis

int strncmp(str1, str2, n);
string str1;
string str2;
int n;

Description

Compares string str1 with string str2 up to a limit of n characters

Parameters

str1

The first string

str2

The second string

n

The number of characters to compare

Returns

A positive integer if str1 > str2, 0 if str1 == str2, a negative integer if str1 str2


Name

strncpy —

Synopsis

string strncpy(str, n);
string str;
int n;

Description

Returns a new string copying characters from string str until either it has copied n characters or it has reached the end of string str

Parameters

str

The string

n

Max chars to append to str

Returns

The string result of operation


Name

strpbrk —

Synopsis

string strpbrk(str1, str2);
string str1;
string str2;

Description

Locates the first occurrence in str1 of any characters from string str2

Parameters

str1

The first string

str2

The second string

Returns

A copy of string str1 starting from the first occurrence until end or an empty string if no characters were found


Name

strrch —

Synopsis

string strrch(str, ch);
string str;
char ch;

Description

Locates the last occurrence of char ch in string str

Parameters

str

The string to search in

ch

The character to search for

Returns

A copy of string str starting from the last occurrence until end, or an empty string if ch was not found


Name

strspn —

Synopsis

int strspn(str1, ch);
string str1;
char ch;

Description

Computes the length of the maximum initial segment of string str1 that consists entirely of characters from string str2:

Parameters

str1

The first string

ch

The second string

Returns

The length of the segment


Name

strstr —

Synopsis

string strstr(str1, str2);
string str1;
string str2;

Description

Looks for string str2 in string str1

Parameters

str1

The first string

str2

The second string

Returns

A string containing the part of str1 beginning with the found string until end if str2 is in str1 (else an empty string)

Chapter 3. Biferno array Class Reference

Name

array —

Synopsis

The array class.c

Implemented in the C language.

Description

n.a.


Name

array —

Synopsis

void array(...);

Description

The class "array" describes mono (or multi) dimensional vector of objects all belonging to the same class. An array can be initialized as follows:

myArray = array(value1, value2, value3 ...)

or:

myArray = array()
myArray[1] = value1 
myArray[2] = value2 
myArray[3] = value3  ...   

An associative array has names for all (or part of) its elements:

myArray = array(name1:value1, name2:value2, name3:value3 ...)

or:

myArray = array() 
myArray[1] = value1 
myArray.name[1] = name1 
myArray[2] = value2 
myArray.name[2] = name2 
myArray[3] = value3 
myArray.name[3] = value3
...

Returns

An istance of the class array


Name

Add —

Synopsis

void Add(element, ...);
obj element;
...;

Description

Adds one or more objects to the array. Objects with index name can be added using: myArray.Add(theName:theValue, theName2:theValue2)

Parameters

element

The object to add

Returns

Nothing


Name

Count —

Synopsis

arrayCount(element);
obj element;

Description

Locates the element element in the array

Parameters

element

The obj to search for

Returns

An array of int representig the positions of element in the array or an empty array if the element was not found

Note

Check the resulting array dimension to see how many times the element is repeated in the array


Name

Delete —

Synopsis

void Delete(start, end);
int start;
int end;

Description

Removes one or more elements from an array

Parameters

start

The first element to remove, default is 1

end

The last element to remove, default is start

Returns

Nothing

See Also

method.array.SetDim, method.array.Reset, method.array.Add, method.array.Insert

Note

To removing just one object, write: myArray.Delete(index)


Name

Find —

Synopsis

int Find(element);
obj element;

Description

Locates the first element whose value matches the specified object value

Parameters

element

The object value to search for . Note that if the object class type does not match the array element class a typecast will be applied

Returns

The position of the element in the array, or 0 if it was not found

Note

In multidimensional arrays the Find method matches entire arrays, not single objects inside arrays.


Name

GetElemClass — Return the array element of class

Synopsis

string GetElemClass();

Description

Returns the class of the array's elements

Returns

A string representing the class of the elements in the array


Name

Index —

Synopsis

int Index(elementName);
string elementName;

Description

Locates an element with name elementName in the array

Parameters

elementName

The name of the element to search for

Returns

The position of the element in the array


Name

Insert —

Synopsis

void Insert(pos, elementN, ...);
int pos;
obj elementN;
...;

Description

Insert one or more objects in the array after the position pos.

Parameters

pos

The position preceeding the new objects position

elementN

Objects to insert

Returns

Nothing


Name

Max —

Synopsis

int Max();

Description

Locates the element with the maximum value in the array

Returns

Th element index (not value) containig the maximum

Note

The "maximum value" is calculated invoking the class "greater" operator. When creating a class make sure to implement basic operators (=, <, >, <=, >= etc) so that this and the Min() method can be applied.


Name

Min —

Synopsis

int Min();

Description

Locates the element with the minimum value in the array

Returns

The element index (not value) containig the minimum

Note

The "minimum value" is calculated invoking the class "less than or equal" operator. When creating a class make sure to implement basic operators (=, >, <, <=, >= etc) so that this and the Max() method can be applied.


Name

Reset —

Synopsis

void Reset();

Description

Removes all the elements of the array

Returns

Nothing


Name

Reverse —

Synopsis

void Reverse();

Description

Reverse the position of elements moving the element in the first position to the last position and so on

Returns

Nothing

See Also

method.array.Sort

Note


Name

SetDim —

Synopsis

void SetDim(newDim);
int newDim;

Description

Sets the dimension of the array to newDim adding or removing elements

Parameters

newDim

The new dimension of the array

Note

Elements added are "undefined" until their initialization


Name

SetElemClass —

Synopsis

void SetElemClass(className);
string className;

Description

n.a.

Parameters

className

n.a.


Name

Sort —

Synopsis

void Sort(mode,  
 compareFunc,  
 alg); 
int  mode;
string  compareFunc;
int  alg;

Description

Sorts elements in array

Parameters

mode, default asc

Determines the order of the array after the sort. Possible values can be constant.array.asc and constant.array.desc (default is constant.array.asc)

compareFunc

If this parameter is "" or not specified, the sort is performed executing a comparison operator for the class type of the array elements. Otherwise, if this parameter is specified, the function with the given name will be called to compare elements of array. The prototype of the function (callback) must be:

function boolean CompareFunc(array *theArray, int index1, int index2, int mode);

The array, two indexes and the mode (asc or desc) will be passed. The function must return:true if elements must be swapped, false if not.

alg

Determines the sort algorithm. Possible values can be constant.array.bubble and constant.array.shell. If it is not specified, shell is used if elements are more than 20, bubble otherwise.

Returns

Nothing


Name

SubArray —

Synopsis

arraySubArray(start, end);
int start;
int end;

Description

Return a portion of the array from start to end

Parameters

start

The first element to include in result array

end

The last element to include in result array

Returns

An array part of the original

Note

Causes error.array.ErrBadStartIndex if start parameter is less than or if it is greater than the dimension of the array. If start is 0, than the sub array begins with the first element of the array. Causes error.array.ErrBadEndIndex if end parameter is less than 0. If end is 0, than the sub array ends with the last element of the array.


Name

Swap —

Synopsis

void Swap(index1, index2);
int index1;
int index2;

Description

Swaps two objects in an array.

Parameters

index1

The first element to be swapped

index2

The second element to be swapped


Name

ToString —

Synopsis

string ToString(separator,  
 alsoName); 
string  separator;
boolean  alsoName;

Description

Returns a string representing the array

Parameters

separator, default ", "

The string to print between elements

alsoName, default false

If true, also the names of indexs are included in the string

Returns

The string representing the array


Name

dim —

Synopsis

int  dim

Description

Returns the number of elements in the array

Note

Is only read


Name

name —

Synopsis

string[]  name

Description

Is an array containing the names of elements

Returns

The name of i-th element

Note

To get the name of the first element write: myArray.name[1]


Name

asc —

Synopsis

int  asc

Description

Constant to sort an array in ascending order


Name

bubble —

Synopsis

int  bubble

Description

Constant to force Sort method to use "bubble" algorithm


Name

desc —

Synopsis

int  desc

Description

Constant to sort an array in descending order


Name

shell —

Synopsis

int  shell

Description

Constant to force Sort method to use "shell" algorithm


Name

ErrBadElementName —

Synopsis

int  ErrBadElementName

Description

This error is caused if an empty name is assigned to an array element index. Foe example: myArray.name[1] = "" -> err ErrBadElementName


Name

ErrBadEndIndex —

Synopsis

int  ErrBadEndIndex

Description

This error is caused if a wrong end parameter is passed to the SubArray method


Name

ErrBadStartIndex —

Synopsis

int  ErrBadStartIndex

Description

This error is caused if a wrong start parameter is passed to the SubArray method

Chapter 4. Biferno biferno Class Reference

Name

biferno —

Synopsis

The biferno class.c

Implemented in the C language.

Description

An utility static class to obtain information about Biferno


Name

applications —

Synopsis

string[]  applications

Description

All the applications currently defined in Biferno


Name

classes —

Synopsis

string[]  classes

Description

All the predefined classes defined in Biferno

Note

Predefined classes are all classes C compiled and available since startup of Biferno


Name

compilationFlags —

Synopsis

string  compilationFlags

Description

The #define used in the version of Biferno currently running


Name

functions —

Synopsis

string[]  functions

Description

All the predefined functions defined in Biferno

Note

Predefined functions are all functions C compiled and available since startup of Biferno


Name

home —

Synopsis

string  home

Description

The path to BifernoHome, that is the central folder containing all the base configuration file.

Returns

A string containing the full path (beginning with "file://").


Name

maxUsers —

Synopsis

int  maxUsers

Description

The MAX_USERS parameters specifies the maximum number of simultaneous connections supported by Biferno. The default value for this parameter is 32 on Unix and Windows, while on Mac OS Classic it depends on the Web server configuration. The maximum value is 10000 (ten thousand).

Note

The property is only read

In most cases the default value of this parameter allows to obtain optimal performances from Biferno. We advise to make modifications only if strictly necessary based on the number of accesses required and on the amount of RAM available on the server.

This value can be modified using the line:

MAX_USERS n

in the file "biferno.conf" in BifernoHome


Name

os —

Synopsis

string  os

Description

Use this property to know which system Biferno is running on

Returns

A string describing the system Biferno is running on. Example: "Unix: Linux 2.2.19-6.2.7 #1 SMP Mon Jul 23 17:11:11 CEST 2001 i686 unknown".

Note

The string begins with: MacOS, Unix or Windows. For MacOSX begins with "Unix: Darwin"


Name

poolFactor —

Synopsis

int  poolFactor

Description

The POOL_FACTOR parameter determines the amount of RAM pre-allocated by Biferno for its internal data structures. The default value for this parameter is 1 and the maximum value is 10 (ten). The total amount of RAM used by Biferno is proportional to the number of simultaneous users (MAX_USERS) and to the value of the POOL_FACTOR parameter.

Note

The property is only read

In most cases the default values of this parameter allows to obtain optimal performances from Biferno. We advise to make modifications only if strictly necessary based on the number of accesses required and on the amount of RAM available on the server.

This value can be modified using the line:

POOL_FACTOR n

in the file "biferno.conf" in BifernoHome


Name

upSince —

Synopsis

time  upSince

Description

This property returns the time of last startup of Biferno

Returns

A class time variable containing the last startup


Name

version —

Synopsis

string  version

Description

The version of Biferno

Returns

A string containing the current version of Biferno. As in: $biferno.version$


Name

versionNum —

Synopsis

unsigned  versionNum

Description

The Biferno version

Returns

A number containing the current version of Biferno, as: $biferno.versionNum$

Note

Can be useful to analyze the number using the Hex method of number, as in: biferno.versionNum.Hex(): $biferno.versionNum.Hex()$

In this case only the last 3 couples of char the relevant.

Chapter 5. Biferno boolean Class Reference

Table of Contents

boolean class -
boolean method -

Name

boolean —

Synopsis

The boolean class.c

Implemented in the C language.

Description

The class boolean describes boolean values ("true" or "false" objects) usually result of logic expressions

Note

A boolean converted to string is: "" if the value is false, "true" otherwise


Name

boolean —

Synopsis

void boolean(var);
obj var;

Description

n.a.

Parameters

var

true, false or a variable convertible to boolean

Chapter 6. Biferno byte Class Reference

Table of Contents

byte class - Same as int

Name

byte — Same as int

Synopsis

The byte class.c

Implemented in the C language.

Description

This class is identical to int and it is introducted by jclass so that Biferno can manage all java primitives. See jclass for details.

See Also

int, jclass

Note

Available (as jclass) from Biferno version 1.1

Chapter 7. Biferno cacheItem Class Reference

Name

cacheItem —

Synopsis

The cacheItem class.c

Implemented in the C language.

Description

n.a.


Name

cacheItem —

Synopsis

void cacheItem(path,  
 openMode,  
 permission); 
string  path;
int  openMode;
int  permission;

Description

The class "cacheItem" extends the file class and can be used to manage files in cache. To activate the cache the application variable "CACHE" must be true

Parameters

path

n.a.

openMode

n.a.

permission

n.a.


Name

Flush —

Synopsis

void Flush();

Description

Removes the file from the cache

Returns

Nothing

Note

If the cache is active, the file will be cached at next access


Name

averageExecTime —

Synopsis

unsigned  averageExecTime

Description

Returns the average of execution time of the script over all the executions of it

Returns

The time of execution (in milliseconds)


Name

currentUsers —

Synopsis

unsigned  currentUsers

Description

Returns the number of users actually executing the file

Returns

Total users


Name

hits —

Synopsis

unsigned  hits

Description

Returns total times the file was requested to the cache, that is, the total number of executions of the file (the "hits")

Returns

The hits


Name

lastAccess —

Synopsis

time  lastAccess

Description

Returns the last time the file was executed

Returns

A variable of class time representing the last time of access


Name

lastExecTime —

Synopsis

unsigned  lastExecTime

Description

Returns the time of execution of the script the last time it was executed

Returns

The time of execution (in milliseconds)


Name

maxExecTime —

Synopsis

unsigned  maxExecTime

Description

Returns the maximum time of execution of the script

Returns

The time of execution (in milliseconds)


Name

minExecTime —

Synopsis

unsigned  minExecTime

Description

Returns the minimum time of execution of the script

Returns

The time of execution (in milliseconds)


Name

totExecTime —

Synopsis

unsigned  totExecTime

Description

Returns the sum of all times of execution of the script

Returns

The time of execution (in milliseconds)


Name

userPath —

Synopsis

string  userPath

Description

Returns the path of the file as it was requested by the user

Returns

A string representing the path

Note

Note that a file with path: "file://c/myFolder/myFile" can be requested as "myFile" from a script in the folder "file://c/myFolder"

Chapter 8. Biferno char Class Reference

Table of Contents

char class -
char method -
ascii property -

Name

char —

Synopsis

The char class.c

Implemented in the C language.

Description

n.a.


Name

char —

Synopsis

void char(str);
string str;

Description

The class "char" describes mono character strings. It inherits all methods and properties of string class.

Parameters

str

n.a.


Name

ascii —

Synopsis

unsigned  ascii

Description

Returns the ASCII number representing the character

Returns

The ASCII code of the character

Note

Characters code greater than 127 are platform dependent

Chapter 9. Biferno classInfo Class Reference

Name

classInfo —

Synopsis

The classInfo class.c

Implemented in the C language.

Description

This class is useful for getting descriptions about a certain class. classInfo can use the xml documentaion file, if it exists.

Note

All properties of this class are only read


Name

classInfo —

Synopsis

void classInfo(className,  
 extended); 
string  className;
boolean  extended;

Description

To inizialize a classInfo call the contrustor passing the name of the class.

Parameters

className

The name of the class to get info about

extended

if true, also the xml doc file (if exists) is parsed for extended documentation

Returns

an instance of class classInfo


Name

GetErrorDescription —

Synopsis

string GetErrorDescription(error);
int error;

Description

Returns the string containing a message for a certain error of the class

Parameters

error

the number of the class error

Returns

the error message

Note

If necessary, this method invokes the GetErrMessage method declared by the class

The prototipe of that method must be:

static string GetErrMessage (int errCode)


Name

IsDef —

Synopsis

boolean IsDef(className,  
 allTypes); 
string  className;
boolean  allTypes;

Description

static method used to check if a class is defined

Parameters

className

the name of the class you want to check for existence

allTypes

if true check also if, generally, an extension exists with that name. Note that an extension declaring only functions doesn't exist as a class, so this is the only way to check for them.

Returns

true if the class exists, false otherwise


Name

cloneIsNeeded —

Synopsis

boolean  cloneIsNeeded

Description

Classes like file or db, whose objects are connected to resources that are external to Biferno, when duplicated, duplicate also the connection to the external resource (file or database).

This poses a risk of opening the same file multiple times or to unnecessarily increase the number of open connections to the same database, which is at best a waste of resources and may have unforeseen consequences.

It is possible to inquire if a class "clones" its objects (as the file and database classes do) using this property

Returns

true if the class clones its objects

Note

Only read property


Name

constants —

Synopsis

string[]  constants

Description

This property returns a list of all public constant properties declared by the class

Returns

An array containing the costant

Note

For users class, constants are properties of class declared as:

const ...

Predefined classes have proper BAPI callback to declare constants.

Only read property


Name

descr —

Synopsis

string  descr

Description

Return a description of the class

Returns

A string containing the description

Note

This property is emptry if the parameter extended of the constructor is false

Only read property


Name

errors —

Synopsis

string[]  errors

Description

This property returns a list of all errors declared by the class

Returns

An array containing the errors

Note

For users class, errors are properties of class declared as:

static const error ...

Predefined classes have proper BAPI callback to declare errors.

Only read property


Name

extendedClass —

Synopsis

string  extendedClass

Description

If the class extends another class, the name of the extended class is contained in this property. If the class doesn't extend another class this property returns an empty string.

Returns

The name of the class extended or an empty string if the class doesn't extend another class

Note

Only read property


Name

implem —

Synopsis

int  implem

Description

This property is used to check if the class is "predefined" (written and compiled in C) or "user" (local or application).

Returns

the value classInfo.c for C implemented class (predefined) or the value classInfo.biferno for user Biferno implemented class (user class)

Note

Only read property


Name

methods —

Synopsis

string[]  methods

Description

This property returns a list of all public methods declared by the class

Returns

An array containing the methods

Note

Only read property


Name

note —

Synopsis

string  note

Description

Return the text of "Note" of the documentation

Returns

A string containing the text of "Note"

Note

This property is emptry if the parameter extended of the constructor is false

Only read property


Name

persistentAllowed —

Synopsis

boolean  persistentAllowed

Description

Persistent variables can not be instantiated for some predefined classes (e.g. this is not possible for the db and file classes). Also, it is not possible to create persistent variables for user defined classes. This property can be used to query the ability of a class to support persistent variables.

Returns

true if the class can instance persistent variables, false otherwise

Note

Only read property


Name

properties —

Synopsis

string[]  properties

Description

This property returns a list of all public properties declared by the class

Returns

An array containing the properties

See Also

errors, constants

Note

The properties of the class that are errors (declared as: const ...) or constant (declared as: static const error...) are in other properties of classInfo

Only read property


Name

purpose —

Synopsis

string  purpose

Description

A text describing the purpose of the class

Returns

A string containing the purpose

Note

This property is emptry if the parameter extended of the constructor is false

Only read property


Name

seeAlso —

Synopsis

string  seeAlso

Description

Return the text of "See Also" of the documentation

Returns

A string containing the text of "See Also"

Note

This property is emptry if the parameter extended of the constructor is false

Only read property


Name

sourcePath —

Synopsis

string  sourcePath

Description

This property can be used to know the bfr source file where the class is implemented. For predefined (C) classes this value is always "" (empty string).

Returns

The full path of the file containing the implementation of the class

Note

Only read property


Name

wantDestructor —

Synopsis

boolean  wantDestructor

Description

To inquire if a class has a destructor method this property can be checked

Returns

true if the class has a destructor

Note

This property always returns true for user classes, because such classes always have a destructor (an internal one if the user has defined none), which frees memory resources allocated by Biferno to manage the class instance.

The value of this property for predefined classes depends on the implementation of the class itself.

Only read property


Name

biferno —

Synopsis

int  biferno

Description

the value of classInfo.implem if the class is user, that is implemented in Biferno language


Name

c —

Synopsis

int  c

Description

the value of classInfo.implem if the class is predefined, that is, compiled in C

Chapter 10. Biferno client Class Reference

Name

client —

Synopsis

The client class.c

Implemented in the C language.

Description

This class is used to get informations about the client requesting a page

Note

All properties are static


Name

GetIndSID —

Synopsis

string GetIndSID(index);
int index;

Description

Used to retrieve the index-th Biferno SID (Session ID) active in a certain moment.

If the index is greater than all users en empty string is returned, so one can use code like:

index = 1
while(sid = client.GetIndSID(index++))
{
  $client.SessionVariable(sid, "mylogin")
}

Parameters

index

The index of the SID to be returned (1-based)

Note

The session ID is a string created by Biferno and stored in the user browser cookies. Biferno uses it to keep trace of a user in an application with sessions active


Name

SessionVariable —

Synopsis

string SessionVariable(SID,  
 name); 
string  SID;
string  name;

Description

Given a SID (Session ID) the value of the variable name for the user identified by SID is returned (see example in client.GetIndSID)

Parameters

SID

the string containing the SID of the user

name

the name of the variable requested

Note

The session ID is a string created by Biferno and stored in the user browser cookies. Biferno uses it to keep trace of a user in an application with sessions active


Name

address —

Synopsis

string  address

Description

This is the domain name of the client

Returns

A string representing the domain name of the client

Note

If the web server has the "Reverse DNS lookup" off, this is simply the IP number of the client (the same of property.client.ipAddress)

Only read property


Name

fromUser —

Synopsis

string  fromUser

Description

This is the "From" header field (e-mail address when supplied)

Returns

A string representing the "From" header field

See Also

header

Note

Only read property


Name

ipAddress —

Synopsis

string  ipAddress

Description

This is the client IP address

Returns

A string representing the client IP address, usually of the form "n.n.n.n" (where 0 n 255)

Note

Only read property


Name

password —

Synopsis

string  password

Description

This is the "Password" for current authentication scheme

Returns

A string representing the password of the client

Note

Only read property


Name

user —

Synopsis

string  user

Description

This is the "Username" for current authentication scheme

Returns

A string representing the username of the client

Note

Only read property


Name

userAgent —

Synopsis

string  userAgent

Description

This is the "User-Agent" HTTP header field value

Returns

A string representing "User-Agent" (usually the Browser) of the client

See Also

header

Note

Only read property

Chapter 11. Biferno curApp Class Reference

Table of Contents

curApp class - Porvides informations about current app
Flush method - Flush the cache
GetPubVariable method -
Publish method - Makes a variable visible to other apps
RegisterNewApp method - Initializes an application
Reload method - Reload the application
Unpublish method - Undoes a Publish call
cacheItems property - List of files in cache
cacheTotItems property - Total files in cache
cacheTotSize property - Total size of cache
children property - List of subapplication
childrenHomes property -
classes property - List of application classes
functions property - List of application functions
home property - The path of the folder containing the application
name property - The name of the application

Name

curApp — Porvides informations about current app

Synopsis

The curApp class.c

Implemented in the C language.

Description

This class provides some informations about the application the current script is running in. It can be used also to communicate with other applications or initialize them.

Note

All properties are only read


Name

Flush — Flush the cache

Synopsis

void Flush();

Description

Use this method to unload all application cache files

Note

This method flushes also the cache af all children applications. To know which are the children application use curApp.children


Name

GetPubVariable —

Synopsis

obj GetPubVariable(application,  
 scope,  
 name); 
string  application;
string  scope;
string  name;

Description

To access the value of a variable published by another applicationuse the function GetPubVariable. The name of the application that published the variable, as well as the scope and name of the published variable, must be specified. The function returns a copy object of the published variable, and therefore modifications of the returned variable have no effect on the original variable.

Parameters

application

the application the variable we are requesting belongs to

scope

the scope of the variable as a string. Possible values are "application", "session" or "persistent"

name

the name of the variable

Returns

a copy of the published variable

Errors

If the application doesn't exist the error Err_NoSuchApplication is throwed.

If the application exists but has not such a variable the error Err_VariableNotDefined is throwed.

If the application exists but has never published the variable the error Err_VariableNotPublished is throwed.

Note

If the user is not sure if the variable exists (or if it has not yet been published) he can wrap the code between error.Resume and error.Suspend calls in order to avoid stop of the script, as in:

error.Resume()
if (a = curApp.GetPubVariable("anApp", "session", "aVar"))
  ...
error.Suspend()

Name

Publish — Makes a variable visible to other apps

Synopsis

void Publish(varToPublish);
obj varToPublish;

Description

Biferno has a mechanism that makes it possible for an application to access variables with application, session, or persistent scope belonging to another application.

The Publish predefined function makes a variable visible to all active applications. Only variables with application, persistent or session scope can be published. E.g. we can write:

	application aWebMasterName = "John Smith"
	Publish(aWebMasterName)

Parameters

varToPublish

the variable to publish

Note

Other applications can use curApp.GetPubVariable to get the value af a published variable.

Only variable of type application, session or persistent can be published


Name

RegisterNewApp — Initializes an application

Synopsis

void RegisterNewApp(applName,  
 fullPath); 
string  applName;
string  fullPath;

Description

This method initializes another application executing also the Biferno.config.bfr of that application. If the application is already initialized this method just does nothing.

Parameters

applName

the name of the application

fullPath

the physical path of the folder containing the application. A file Biferno.config.bfr must exists in this folder

Note

To start an application when the Web server is started, without waiting for the first user click, it is possible to use a code line similar to the following in the "Biferno.config.bfr" file of the Biferno Main application:

curApp.RegisterNewApp(application_name, root_path)

application_name is the name of the application we want to initialize (defined by the APPLICATION_NAME parameter of the "Biferno.config.bfr" file) and root_path is the absolute path of the application root directory. An example is:

curApp.RegisterNewApp("MyWebSite", "file://C/Internet/Web/MySite/")


Name

Reload — Reload the application

Synopsis

void Reload();

Description

Calling this method the current application is reloaded. All files in cache are unloaded and the application is reinitialized with all his application and session variable.

Note

This method executes reload also on all children applications. Use curApp.children to know which are the children application.


Name

Unpublish — Undoes a Publish call

Synopsis

void Unpublish(varToUnpublish);
obj varToUnpublish;

Description

Use this method to undo the effect of a previous call to "Publish" on a certain variable

Parameters

varToUnpublish

the variable to unpublish


Name

cacheItems — List of files in cache

Synopsis

cacheItem[]  cacheItems

Description

Returns an array containing the path of all the files currently in the application cache

Note

If the cache is inactive (variable CACHE is false) this array is always empty. The property is only read


Name

cacheTotItems — Total files in cache

Synopsis

int  cacheTotItems

Description

Returns the number of files currently in the application cache

Note

If the cache is inactive (variable CACHE is false) this value is always zero. The property is only read


Name

cacheTotSize — Total size of cache

Synopsis

unsigned  cacheTotSize

Description

Returns the total size (in bytes) of all files currently in the application cache

Note

If the cache is inactive (variable CACHE is false) this value is always zero. The property is only read


Name

children — List of subapplication

Synopsis

string[]  children

Description

Returns the list of all applications that are subapplication (children) of the current

Note

If we create a configuration file in a subdirectory of an application we have created a subapplication (or children).

Subapplications inherit as default the preferences of the parent application (the parent configuration file is executed before the child application configuration file). All applications running on the same Web server are subapplications of the "BifernoMain" application.

Only read property


Name

childrenHomes —

Synopsis

string[]  childrenHomes

Description

n.a.


Name

classes — List of application classes

Synopsis

string[]  classes

Description

provides a list af all user (application) classes available in the current application

Returns

an array containing the names of application classes

Note

Only read property


Name

functions — List of application functions

Synopsis

string[]  functions

Description

provides a list af all user (application) functions available in the current application

Returns

an array containing the names of application functions

Note

Only read property


Name

home — The path of the folder containing the application

Synopsis

string  home

Description

The home of the application, i.e. the path to the folder containing the 'Biferno.config.bfr' file for this app

Note

Only read property


Name

name — The name of the application

Synopsis

string  name

Description

Provides the name of the current application

Note

To modify the name of the application change the value of APPLICATION_NAME variable in Biferno.config.bfr and reload Biferno (or reload a parent application)

Only read property

Chapter 12. Biferno curFile Class Reference

Table of Contents

curFile class - Provides informations about the current file in process
basePath property - The path of the folder containing the file
cache property -
curLine property -
fromCache property -
path property -

Name

curFile — Provides informations about the current file in process

Synopsis

The curFile class.c

Implemented in the C language.

Description

This class is useful to get some infos about the current file being processed.

It is important to understand the difference between script and file. In fact a script can comprise one file, or many files if it use the include command. To get informations about the current script use the class curScript.

Note

All properties of curFile are only read


Name

basePath — The path of the folder containing the file

Synopsis

string  basePath

Description

This property contains the path of the directory containing the current file

Note

Only read property


Name

cache —

Synopsis

boolean  cache

Description

n.a.


Name

curLine —

Synopsis

int  curLine

Description

n.a.


Name

fromCache —

Synopsis

boolean  fromCache

Description

n.a.


Name

path —

Synopsis

string  path

Description

n.a.

Chapter 13. Biferno curScript Class Reference

Table of Contents

curScript class - Get/Set infos about the current script
Delay method - Temporarily suspends execution
GetCustomOutput method - Custom output function name
GetIndVariable method - Get variables list of current script
GetIndVariableRef method -
GetNumFormat method - Get the current decimal and thousand separators
GetStack method -
GetTotVariables method - Total variables of current script
IsDef method - Checks if a variable is defined
LaunchProcess method - Launch a process from the current script
SetCustomOutput method - Installs function for redirecting script output
SetNumFormat method - Specify decimal and thousand separators for current script
SetStandardOutput method - Restores default output function
Undef method - Deletes a variable
ValueOf method - Evaluates a single line of code
basePath property - The base path of the current script
currentThreads property -
maxThreads property -
timeout property - The timeout of the script

Name

curScript — Get/Set infos about the current script

Synopsis

The curScript class.c

Implemented in the C language.

Description

This static class returns information about the current script and allows to modify some script settings (i.e. its timeout value)

Note

The concept of curScript is different from that of curFile because a script can be composed of on or more files if it invokes the include command during its execution


Name

Delay — Temporarily suspends execution

Synopsis

void Delay(seconds);
int seconds;

Description

Calling this method the execution of the script is suspended for some seconds (the script is put in sleep and waked up after some time)

Parameters

seconds

the number of seconds after the script execution must be resumed


Name

GetCustomOutput — Custom output function name

Synopsis

string GetCustomOutput();

Description

This method returns the name of the custom output function if any has been installed, otherwise returns an empty string.


Name

GetIndVariable — Get variables list of current script

Synopsis

obj GetIndVariable(index,  
 name,  
 sorted,  
 scope,  
 stackIndex); 
int  index;
ref  name;
boolean  sorted;
string  scope;
int  stackIndex;

Description

The GetIndVariables returns the value of the variable corresponding to a given position in the "list" of current script variables and, optionally, the name of the variable itself.

"Lists" are relative to scopes; each scope maintains a list with all variables (of the current script) belonging to that scope (and to specify a list means to specify a scope).

Parameters

index, default 1

the index of the variable in the list

name, parameter target string

on output, the name of the variable requested

sorted, default false

specifies if the list must be sorted alphabetically, before getting the index-th variable

scope, default "local"

defines the list to get the variable from. Possible lists corresponds to possible scopes: local, global, application, session, persistent

stackIndex

n.a.

Note

Example: the following script prints all local variables (with their names) of the current script

totVars = curScript.GetTotVariables("local")
theVar = ""
for(i = 1; i <= totVars; i++)
{
theVar = curScript.GetIndVariable(i, &name, false, "local") 
$name + ": " + theVar + "<br>"
}

Note that the variables i, totVars and theVar will not be included in the printed list because they have been defined after the GetTotVariables call.

Besides, note that theVar is initialized before the loop (to empty string) in order to define its class and to avoid typecast problems. Without that initialization, if the first variable of the list is an int theVar is initialized to int and following typecasts could fail if subsequent variables are not numbers (that is a common case).


Name

GetIndVariableRef —

Synopsis

obj GetIndVariableRef(index,  
 name,  
 sorted,  
 scope,  
 stackIndex); 
int  index;
ref  name;
boolean  sorted;
string  scope;
int  stackIndex;

Description

n.a.

Parameters

index, default 1

n.a.

name, parameter target string

n.a.

sorted, default false

n.a.

scope, default "local"

n.a.

stackIndex

n.a.


Name

GetNumFormat — Get the current decimal and thousand separators

Synopsis

void GetNumFormat(thousSep,  
 decimSep); 
ref  thousSep;
ref  decimSep;

Description

Use this method to get the decimal and thousand separators for current script

Parameters

thousSep, parameter target char

on output, the thousand separator character

decimSep, parameter target char

on output, the decimal separator character

See Also

SetNumFormat


Name

GetStack —

Synopsis

void GetStack();

Description

n.a.


Name

GetTotVariables — Total variables of current script

Synopsis

int GetTotVariables(scope,  
 stackIndex); 
string  scope;
int  stackIndex;

Description

The GetTotVariables returns the total number of variables in the "list" of current script variables.

"Lists" are relative to scopes; each scope maintains a list with all variables (of the current script) belonging to that scope (and to specify a list means to specify a scope).

Parameters

scope, default "local"

defines the list of variables. Possible lists corresponds to possible scopes: local, global, application, session, persistent

stackIndex

n.a.

Note

See exmaple of GetIndVariables method


Name

IsDef — Checks if a variable is defined

Synopsis

boolean IsDef(name);
string name;

Description

If we need to know if a variable is defined or undefined, we can use the method IsDef. This method requires a string called name as a parameter and returns the true value if a variable with identifier name exists, or false if no variable with identifier name exists. Example:

if (curScript.IsDef("myVar"))
	print(myVar)

Parameters

name

the name of the variable to check

See Also

Undef

Note

Notice that the IsDef function, unlike Undef, does not take an object as parameter, but rather a string containing the object name. This avoids an error condition if the variable has never been defined. In the case of the Undef function, an error condition should occur, because it is not legal to invoke Undef on an undefined object.


Name

LaunchProcess — Launch a process from the current script

Synopsis

boolean LaunchProcess(executablePath,  
 commandLineString,  
 waitEnd,  
 timeout_ms); 
string  executablePath;
string  commandLineString;
boolean  waitEnd;
unsigned  timeout_ms;

Description

This method can be used to execute a process on the same computer where Biferno is running.

Parameters

executablePath

a string containing the path of the executable file. This can be, for example, a ".exe" on Windows or an executable command on Unix. The path must be in Biferno file format, NOT native format

commandLineString

parameter arguments to pass to the executabel (as if written on a command line). If commandLineString contains path, they must be expressed in native format

waitEnd

if true, the call blocks until the called process is terminated, or until a timeout (timeout_ms) is reached. If false the call is not blocked and timeout is not used

timeout_ms

if the call wait for the process to terminate, a timeout (in milliseconds) can be set to prevent infinite blocks.

Note

Example: this script executes WZZIP.EXE (in a Windows OS) to zip a folder

zipExePath = "file://D/Program Files/WinZip/WZZIP.EXE"
zipCommand = " -rP myFolder.zip myFolder\\*.*"
curScript.LaunchProcess(zipExePath, zipCommand, true, 1000 * 600);


Name

SetCustomOutput — Installs function for redirecting script output

Synopsis

void SetCustomOutput(outputFunction); 
string  outputFunction;

Description

This method can be used to install a custom "callback" output: after this call, when the print command (or $$ or $$...$$ commands) are invoked the function "outputFunction" is called instead of the simple "print".

The custom function must have the following prototype:

function void myFunc(string text)

and remains installed only during the current script

Parameters

outputFunction

the name of the custom function

Note

Example:

function void PrintRed(string text)
{
	print('<font color="red">')
	print(text)
	print('</font>')
}
curScript.SetCustomOutput("PrintRed")

the above code causes all output strings to be printed in red text color.

To reinstall the default output function ("print") call the method SetStandardOutput


Name

SetNumFormat — Specify decimal and thousand separators for current script

Synopsis

void SetNumFormat(thousSep,  
 decimSep); 
char  thousSep;
char  decimSep;

Description

The SetNumFormat static method allows to specify for a single current script within an application the decimal and thousand separators to be used during string conversion, temporarily replacing the application defaults defined in the “Biferno.config.bfr” file (THOUSAND_SEP and DECIMAL_SEP).

The following example clarifies its use:

a = 1234.567 // a is of classe double
b = a.ToString() //b is "1234,57" – notice rounding
c = a.ToString(true) //c is "1.234,57"
d = a.ToString(true, 1) //d is "1.234,6"
int.SetFormat(",",".")
e = a.ToString(true, 5) //e is "1,234.567"
f = a.ToString(true, 5, false) //f is "1,234.56700"

Parameters

thousSep

the new thousand separator character

decimSep

the new decimal separator character

See Also

GetNumFormat


Name

SetStandardOutput — Restores default output function

Synopsis

void SetStandardOutput();

Description

If a custom output function was installed in the current script, this method restores the default behaviour for output (the default "print" function)


Name

Undef — Deletes a variable

Synopsis

void Undef(variable);
obj variable;

Description

Requires as a parameter an object identifier, i.e. a variable belonging to any class. The supplied object is made undefined and it will behave from now on as if it was have never defined. The Undef method returns void.

Undef(myVar)

Parameters

variable

the variable to delete

Note

Notice that the IsDef function, unlike Undef, does not take an object as parameter, but rather a string containing the object name. This avoids an error condition if the variable has never been defined. In the case of the Undef function, an error condition should occur, because it is not legal to invoke Undef on an undefined object. To validate the parameter to Undef, a code fragment code similar to the following can be used:

if (IsDef("myVar"))
	Undef(myVar)

The Undef function cannot be used on “literal” variables or on the result of an operation. The code fragments:

Undef("foo") // error Err_IllegalUndef!

and

Undef(a + b) // error Err_IllegalUndef!

both generate the Err_IllegalUndef error.


Name

ValueOf — Evaluates a single line of code

Synopsis

obj ValueOf(line);
string line;

Description

This method evaluates a line of code. It can be, for example, a simple name of a variable or a more complex line

Parameters

line

the line to evaluate

Returns

the object resulting from the evaluation or an empty string if the evaluation caused the error Err_UndefinedIdentifier.

See Also

Eval

Note

Examples:

// prints value of aname or empty string
// if aname doesn't exist
$curScript.ValueOf("aname")
// prints value of myString.length
$curScript.ValueOf("myString.length")

Use Eval to evaluates real blocks of code


Name

basePath — The base path of the current script

Synopsis

string  basePath

Description

Returns the path of the folder containing the current script. If the script is composed by more than one file (via include) this is the path of the folder containing the first file of the script (the main file)


Name

currentThreads —

Synopsis

int  currentThreads

Description

Returns the total number of threads involved in the current script.

See Also

maxThreads

Note

Why does Biferno (sometimes) use more than one thread per script?

When a script execution is requested Biferno spawns a thread with a predefined stack size (for C internal variables). The stack size is usually big enough to execute the entire script. Nevertheless some scripts (for example scripts using recursive functions) could need more stack at a certain point of execution. In that case the next block of code is executed in a new thread (joined to the parent) in order to obtain more stack space for execution. Thus the number of threads per script can also be greater than 1.


Name

maxThreads —

Synopsis

int  maxThreads

Description

Returns the max number of threads involved in the current script.

Note

See notes in currentThreads


Name

timeout — The timeout of the script

Synopsis

unsigned  timeout

Description

Get this property to know wich is the current timeout for the script. Set the property to modify that value for the current script

See Also

Err_Timeout

Note

If the execution time of the script exceeds the value of curScript.timeout an error Err_Timeout is thrown. This eliminates the risk of possible endless loops in the code. To avoid timeout at all set timeout to 0 (zero). Note, however, that this removes protection from possible infinite loops.

The following code exits with error Err_Timeout after 1 minute:

curScript.timeout = 1
i = 1
while(i);

The default value for timeout is defined by application variable TIMEOUT and default value for this variable is 2 minutes.

Chapter 14. Biferno db Class Reference

Name

db —

Synopsis

The db class.c

Implemented in the C language.

Description

n.a.


Name

db —

Synopsis

void db(initString, db);
string initString;
string db;

Description

This class is used to interact with database manager systems (DBMS). It can connect to DBMS via ODBC or via native drivers (when they are available).

Parameters

initString

The string to connect to the database. The sintax of this string depends on the db parameter. For example a possible string for odbc connection is "DSN=MYDB;UID=mydbuser;PWD=myPass"

db

the type of connection used ("odbc", "mysql" etc...)


Name

Bind —

Synopsis

void Bind(pos,  
 variableName,  
 bytes,  
 mode,  
 cursorID); 
int  pos;
string  variableName;
int  bytes;
int  mode;
int  cursorID;

Description

Binds a variable to the pos-th parameter mark ("?") in a prepared statement

Parameters

pos

The position of parameter mark to bind

variableName

The name of the variable to bind

bytes

The size (in bytes) of the variable to bind

mode

Specify if the variable has to be bound in input, output or inputOutput mode. Output mode is usefull for stored procedures. Possible costant to use are db.inputBindMode, db. outputBindMode , db. inputOutputBindMode

cursorID

the cursor id to which apply Bind

Note

At bind time is not necessary that a variable with name "variableName" exist. It is important that it will exists at ExecPrepared time


Name

BindAll —

Synopsis

void BindAll(pos,  
 variableName,  
 bytes,  
 mode,  
 prepareID); 
int  pos;
string  variableName;
int  bytes;
int  mode;
int  prepareID;

Description

Binds a variable to the pos-th parameter mark ("?") in a prepared statement in all statements of a prepared pool of cursors

Parameters

pos

The position of parameter mark to bind

variableName

The name of the table field used with the parameter mark

bytes

The name of the variable to bind

mode

The id of the pool as returned by a Prepare call

prepareID

n.a.

Note

At bind time is not necessary that a variable with name "variableName" exist. It is important that it will exists at ExecPrepared time


Name

Call —

Synopsis

string Call(procName, ...);
string procName;
...;

Description

n.a.

Parameters

procName

n.a.


Name

CallExt —

Synopsis

string CallExt(procName,  
 cursID,  
 ...); 
string  procName;
ref  cursID;
 ...;

Description

n.a.

Parameters

procName

n.a.

cursID, parameter target int

n.a.


Name

Commit —

Synopsis

void Commit();

Description

Terminates a transaction committing the operations on the db


Name

Escape —

Synopsis

string Escape(str);
string str;

Description

Escapes the string transforming every single quote in two single quotes (as sql requires)

Parameters

str

The string to escape

Returns

The string result of operation


Name

Exec —

Synopsis

int Exec(sql_statement,  
 mode,  
 rowSetSize,  
 freeCursor); 
string  sql_statement;
int  mode;
int  rowSetSize;
boolean  freeCursor;

Description

Sends to the DBMS the sql query contained in the sql_statement parameter.

Parameters

sql_statement

The string containing the sql statement to execute. Parts of the string must be escaped (with method.db.Escape method) if contain single quote character ("'").

mode, default defaultMode

The type of cursor result of the operation. Possible types are: db.dynamicMode: the cursor is dynamic, data is retrieved from the DBMS in multiple requests db.staticMode: the cursor is static, data is retrieved from the DBMS in a single request db.defaultMode: best mode is choosen by the driver

rowSetSize, default 1

The number of rows requested at every Fetch in order to cache records returned by the DBMS

freeCursor

If this parameter is set to true, the cursor is disposed before returning from Exec

Returns

A cursor id to use in subsequent calls of db class

Errors

When the generic error error.db.ErrDBMSError is returned the real error is contained in the property.error.subErr and property.error.subErrDescr properties of global err error.db.ErrBadCursorMode is returned if an invalid cursor mode is passed to the function

Note

For DBMSs that require prepares, Biferno prepares the query internally


Name

ExecPrepared —

Synopsis

void ExecPrepared(cursorID);
int cursorID;

Description

Executes a statement previously prepared with a Prepare call

Parameters

cursorID

The id of the cursor as returned by GetPrepared


Name

FetchRec —

Synopsis

arrayFetchRec(cursorID,  
 undefNULL,  
 fetchLocator); 
int  cursorID;
boolean  undefNULL;
boolean  fetchLocator;

Description

Fetches the next record from the current selection

Parameters

cursorID

The id of the cursor

undefNULL

Normally NULL fields are retrieved as empty strings and one cannot distinguish between empty cells and NULL cells. If undefNULL is true, NULL field are retrieved as undefined elements of the array.

fetchLocator

If true, the locators are fetched for CLOB/BLOB fields instead of the data. They can then be used with methods LobRead and LobWrite of class db. As of today only the oracle extension takes into account the value of this parameter.

Returns

An associative array containing cells of retrieved records. Element's index names of the array are equal to field title as referenced in the sql statements.

Errors

Can return erros related to the DBMS. In that case the native error(or status, as in ODBC) can be found in err.SubErr

Note

To set and get the position of the cursor use: method.db.Seek and method.db.Tell methods


Name

Free —

Synopsis

void Free(cursorID);
int cursorID;

Description

Free all resources of cursor cursorID

Parameters

cursorID

The id of the cursor


Name

FreePrepare —

Synopsis

void FreePrepare(prepareID);
int prepareID;

Description

n.a.

Parameters

prepareID

n.a.


Name

GetAffectedRecs —

Synopsis

int GetAffectedRecs(cursorID);
int cursorID;

Description

Gets the number of records affected by the statement of the cursor cursorID

Parameters

cursorID

Is the index of the cursor as returned by method.db.Exec, method.db.GetPrepared call. If cursorID is not passed, the last cursor created is used

Returns

The number of rows affected by the operation


Name

GetCurRecs —

Synopsis

int GetCurRecs(cursorID);
int cursorID;

Description

Gets the number of records contained in the selection pointed to by cursor cursorID

Parameters

cursorID

Is the index of the cursor as returned by method.db.Exec, method.db.GetPrepared call. If cursorID is not passed, the last cursor created is used

Returns

The number of rows in the selection


Name

GetPrepared —

Synopsis

int GetPrepared(prepareID);
int prepareID;

Description

Gets a cursor previously prepared with a call to Prepare

Parameters

prepareID

The id of the pool as returned by the Prepare call

Returns

The id of the cursor


Name

GetSpecific —

Synopsis

string GetSpecific(name,  
 cursorID); 
string  name;
int  cursorID;

Description

n.a.

Parameters

name

n.a.

cursorID

n.a.


Name

LobRead — Reads a portion of a LOB/FILE, as specified by the call, into a string.

Synopsis

string LobRead(locator,  
 offset,  
 len); 
int  locator;
int  offset;
int  len;

Description

This function can be used to read a portion (or all) of a LOB field.

Parameters

locator

A LOB/FILE locator that uniquely references the LOB/FILE. This locator can be obtained calling the Fetch method with third parameter to true.

offset

The absolute offset from the beginning of the LOB value. For character LOBs (CLOBs, NCLOBs) it is the number of characters from the beginning of the LOB, for binary LOBs/FILEs it is the number of bytes. The first position is 1.

len

The length in bytes (or characters) to read from the LOB field..

Returns

A string containing the LOB value.

Errors

Example:

	cursID = mydb.Exec("select MYBLOB from MYTABLE")
	lobLocator = mydb.FetchRec(,,true)[1]
	$mydb.LobRead(lobLocator)

Note

As of today only the oracle extension implements this method


Name

LobWrite — Writes a string into a LOB

Synopsis

void LobWrite(locator,  
 content,  
 offset); 
int  locator;
string  content;
int  offset;

Description

This function can be used to write a string into a portion (or all) of a LOB field.

Parameters

locator

A LOB/FILE locator that uniquely references the LOB/FILE. This locator can be obtained calling the Fetch method with third parameter to true.

content

The string to write into the LOB field

offset

It is the absolute offset from the beginning of the LOB value. For character LOBs it is the number of characters from the beginning of the LOB, for binary LOBs it is the number of bytes. The first position is 1.

See Also

LobRead, FetchRec

Note

Example:

	query = "select MYBLOB from MYTABLE where ID=" + id + " FOR UPDATE"
	cursID = mydb.Exec(query)
	lobLocator = mydb.FetchRec(,,true)[1]
	mydb.LobWrite(bLoc, the_content)


Name

Prepare —

Synopsis

int Prepare(sql_statement,  
 totPrepared,  
 mode,  
 rowSetSize); 
string  sql_statement;
int  totPrepared;
int  mode;
int  rowSetSize;

Description

Prepares totPrepared sql statements to be used later

Parameters

sql_statement

The statement to prepare. Usually this string contains "?" chars indicating parameter marks substituted at bind time

totPrepared

The total number of cursors to prepare

mode, default defaultMode

The mode of prepared cursor (see method.db.Exec)

rowSetSize, default 1

The row set size of the cursor (see method.db.Exec)

Returns

A pool id to use in subsequent db calls using prepared pool


Name

RealEscape —

Synopsis

string RealEscape(str,  
 byteEsc); 
string  str;
boolean  byteEsc;

Description

Escapes the string transforming characters as sql of the DBMS requires

Parameters

str

The string to escape

byteEsc

unused

Returns

The string result of operation

Note

The difference between this method and the Escape method is that the RealEscape calls a DBMS API (if any) to escape the string. If there is not a DBMS dedicated API, this method is equivalent to Escape.


Name

RealUnescape —

Synopsis

string RealUnescape(str,  
 byteEsc); 
string  str;
boolean  byteEsc;

Description

n.a.

Parameters

str

n.a.

byteEsc

n.a.


Name

RollBack —

Synopsis

void RollBack();

Description

Terminates a transaction rolling back all changes on the database


Name

RowSetSize —

Synopsis

void RowSetSize(size, cursorID);
int size;
int cursorID;

Description

Sets the number of rows requested at every Fetch in order to cache records returned by the DBMS

Parameters

size

The number of record to cache in every Fetch operation

cursorID

The id of the cursor


Name

Seek —

Synopsis

void Seek(index, cursorID);
int index;
int cursorID;

Description

Sets the position of the cursor, that is, the index of the record fetched at next Fetch call

Parameters

index

The position (1-based) to set for the cursor

cursorID

The id of the cursor

Errors

error.db.ErrBadSeekIndex is returned if a position = 0 is passed to Seek method


Name

SetSpecific —

Synopsis

void SetSpecific(name,  
 value,  
 cursorID); 
string  name;
string  value;
int  cursorID;

Description

n.a.

Parameters

name

n.a.

value

n.a.

cursorID

n.a.


Name

Tell —

Synopsis

int Tell(cursorID);
int cursorID;

Description

Gets the position of the cursor, that is, the index of the record fetched at next Fetch call

Parameters

cursorID

The id of the cursor

Returns

The current position (1-based) of the cursor


Name

Transaction —

Synopsis

void Transaction();

Description

Begins a transaction that can be terminated committing or rolling back


Name

Warning —

Synopsis

string Warning(cursorID);
int cursorID;

Description

Gets the last warning returned by the DBMS

Parameters

cursorID

The cursor id

Returns

A string containing the last warning


Name

defaultMode —

Synopsis

int  defaultMode

Description

Indicates that the cursor mode has to be decided by the underlying driver


Name

dynamicMode —

Synopsis

int  dynamicMode

Description

Indicates that cursor must be dynamic: data is retrieved from the DBMS in multiple requests


Name

inputBindMode —

Synopsis

int  inputBindMode

Description

n.a.


Name

inputOutputBindMode —

Synopsis

int  inputOutputBindMode

Description

n.a.


Name

null —

Synopsis

string  null

Description

n.a.


Name

outputBindMode —

Synopsis

int  outputBindMode

Description

n.a.


Name

staticMode —

Synopsis

int  staticMode

Description

Indicates that the cursor must be static: data is retrieved from the DBMS in a single request


Name

ErrBadCursorID —

Synopsis

int  ErrBadCursorID

Description

n.a.


Name

ErrBadCursorMode —

Synopsis

int  ErrBadCursorMode

Description

Is returned when a cursor mode other than db.dynamicMode, db.staticMode, db.defaultMode is passed to method.db.Exec and method.db.Prepare db methods.


Name

ErrBadPrepareID —

Synopsis

int  ErrBadPrepareID

Description

n.a.


Name

ErrBadSeekIndex —

Synopsis

int  ErrBadSeekIndex

Description

Is returned when a position = 0 is passed to Seek method


Name

ErrDBMSError —

Synopsis

int  ErrDBMSError

Description

Is a generic error indicating that an error at driver level occurred. See property.error.subErr and error.subErrDescr of global err to investigate.


Name

ErrGettingAffectedRecs —

Synopsis

int  ErrGettingAffectedRecs

Description

The underlying driver doesn't support the "get affected recs" call


Name

ErrGettingCurRecs —

Synopsis

int  ErrGettingCurRecs

Description

The underlying driver doesn't support the "get cur recs" call


Name

ErrInvalidFree —

Synopsis

int  ErrInvalidFree

Description

n.a.


Name

ErrNoCursorAvailable —

Synopsis

int  ErrNoCursorAvailable

Description

n.a.


Name

ErrNotEnoughStorageForRecord —

Synopsis

int  ErrNotEnoughStorageForRecord

Description

The class implementing the driver communication didn't allocated enough memory storage to obtain a valid db record (this error should never happen!)


Name

ErrTooManyCursors —

Synopsis

int  ErrTooManyCursors

Description

n.a.


Name

ErrTooManyPrepares —

Synopsis

int  ErrTooManyPrepares

Description

n.a.


Name

ErrUndefinedBindVariable —

Synopsis

int  ErrUndefinedBindVariable

Description

n.a.


Name

ErrUnknownDBType —

Synopsis

int  ErrUnknownDBType

Description

The second parameter of the constructor doesn't match an available DBMS driver communication biferno class

See Also

db


Name

ErrUnknownSpecific —

Synopsis

int  ErrUnknownSpecific

Description

n.a.

Chapter 15. Biferno double Class Reference

Table of Contents

double class - 8-bytes floating point number
double method - Creates an object of class double
Abs method -
Cos method -
Hex method - Hexadecimal representation
Int method -
Pow method -
Round method -
Sin method -
Sqr method -
Sqrt method -
ToString method -
pi constant -

Name

double — 8-bytes floating point number

Synopsis

The double class.c

Implemented in the C language.

Description

The double describes positive or negative real numbers with values ranging from 1.7E-308 to 1.7E+308 (8 byte representation).

See Also

long, int


Name

double — Creates an object of class double

Synopsis

void double(num);
obj num;

Description

Describes an 8-bytes floating point number

Parameters

num

the number

Returns

An instance of double

Errors

Can return Err_IllegalTypeCast if the num parameter cannot be typecasted to a valid floating point number

Note

Some methods of double class get parameters of class obj to indicate numbers of class int, unsigned etc...


Name

Abs —

Synopsis

obj Abs();

Description

Computes the absolute value of the number

Returns

The absolute value of the number


Name

Cos —

Synopsis

obj Cos();

Description

Computes the cosine of the number

Returns

The cosine of the number


Name

Hex — Hexadecimal representation

Synopsis

string Hex();

Description

Returns a string representing the number in hexadecimal </b>


Name

Int —

Synopsis

int Int();

Description

gets the nearest lower integer of the number


Name

Pow —

Synopsis

obj Pow(exp);
obj exp;

Description

Computes the number raised to the power of exp

Parameters

exp

The exponent


Name

Round —

Synopsis

int Round();

Description

gets the nearest lower integer if decimal is = .5


Name

Sin —

Synopsis

obj Sin();

Description

Computes the sine of the number

Returns

The sine of the number


Name

Sqr —

Synopsis

obj Sqr();

Description

Computes the square of the number


Name

Sqrt —

Synopsis

obj Sqrt();

Description

Computes the square root of the number


Name

ToString —

Synopsis

string ToString(wantThousandSep,  
 decimals,  
 cutRightZero); 
boolean  wantThousandSep;
int  decimals;
boolean  cutRightZero;

Description

Convert the number in a string

Parameters

wantThousandSep, default false

If true the thousand separators are inserted in the string. Thousand separator character can be defined using SetNumFormat or using the THOUSAND_SEP application variable

decimals, default 2

Indicates how many digits to put after the decimal sign (default is 2)

cutRightZero, default true

If true the zero characters after the last non-zero char after the decimal point will be removed

Returns

the string result of the operation

Note

Decimal separator character can be defined using SetNumFormat or using the DECIMAL_SEP application variable


Name

pi —

Synopsis

double  pi

Description

The Pi number.Its value is: 3.141592653589793238462643383279

Chapter 16. Biferno error Class Reference

Table of Contents

error class -
error method -
Function method -
Resume method -
State method -
Suspend method -
ThrowException method -
Update method -
classNote property -
descr property -
errClass property -
errNum property -
fileOffset property -
lastMultiStrLine property -
line property -
lineNum property -
msg property -
name property -
path property -
resumable property -
subErr property -
subErrDescr property -
table property -
Err_AbsolutePathRequired error -
Err_ApplicationNameDuplicated error -
Err_ApplicationNameNotFoundInConfig error -
Err_ApplicationNameTooLong error -
Err_ArrayElementNotFound error -
Err_ArrayElementsTypeCastFailed error -
Err_ArrayMismatch error -
Err_ArrayRequired error -
Err_AttachCurrentThreadException error -
Err_BadArrayIndex error -
Err_BadBifernoSID error -
Err_BadBlockSize error -
Err_BadFileRef error -
Err_BadMemoryRef error -
Err_BadPrototype error -
Err_BadSyntax error -
Err_BadSyntaxInApplicationName error -
Err_BadSyntaxInURL error -
Err_BAPI_BifernoTooNew error -
Err_BAPI_BifernoTooOld error -
Err_BAPI_BufferTooSmall error -
Err_BAPI_EndOfObject error -
Err_BAPI_ErrorsAlreadyRegistered error -
Err_BAPI_ExtensionNameRequired error -
Err_BAPI_ExtensionTooNew error -
Err_BAPI_ExtensionTooOld error -
Err_BAPI_InvalidAPIData error -
Err_BAPI_InvalidParameter error -
Err_BAPI_LoopAbort error -
Err_BAPI_MessageNotHandled error -
Err_BAPI_ObjAlreadyToDestruct error -
Err_BAPI_ObjNotPrintable error -
Err_BAPI_ObjNotToDestruct error -
Err_BAPI_SymbolNotFound error -
Err_BAPI_UnknowExtensionType error -
Err_BifernoConfigNotFound error -
Err_BuffersBadID error -
Err_BuffersNotInitialized error -
Err_CacheNotInitialized error -
Err_CachePathTooLong error -
Err_CantAccessThisMember error -
Err_CantCloseShLib error -
Err_CantFindShLibSymbol error -
Err_CantLoadShObject error -
Err_CantModifyLength error -
Err_ClassError error -
Err_ClassIsStatic error -
Err_ClassRedeclared error -
Err_CommaOrRoundSquareExpected error -
Err_ConnectionBroken error -
Err_ConvertingStringToLong error -
Err_CookieDisabled error -
Err_CurlyBracketExpected error -
Err_CurlyBracketNotBalanced error -
Err_DateTimeFormatError error -
Err_DuplicatedArrayElemName error -
Err_DuplicatedConstructor error -
Err_DuplicatedFile error -
Err_DuplicatedLabel error -
Err_DuplicatedObject error -
Err_DuplicatedParameter error -
Err_DuplicatedPropertyName error -
Err_EmptyExpression error -
Err_EmptyName error -
Err_EndOfFile error -
Err_EndOfLineOrSemicolonExpected error -
Err_ExplicitTypeCastRequired error -
Err_FileNotFound error -
Err_FolderIsNotEmpty error -
Err_FolderNotFound error -
Err_FreeBlock error -
Err_FunctionIsVoid error -
Err_FunctionRedeclared error -
Err_HTTPBodyTooLong error -
Err_IllegalArrayInURL error -
Err_IllegalAssignment error -
Err_IllegalConstantExpression error -
Err_IllegalConstantParameter error -
Err_IllegalDeclaration error -
Err_IllegalFlowControl error -
Err_IllegalOperation error -
Err_IllegalOperationOnConstant error -
Err_IllegalOperationOnMethod error -
Err_IllegalRef error -
Err_IllegalScopeForObject error -
Err_IllegalSetProperty error -
Err_IllegalTypeCast error -
Err_IllegalUndef error -
Err_InvalidArrayIndex error -
Err_InvalidCharacter error -
Err_InvalidErrorValue error -
Err_InvalidEscapeSequence error -
Err_InvalidIndex error -
Err_InvalidLength error -
Err_InvalidListRef error -
Err_InvalidListType error -
Err_InvalidName error -
Err_InvalidParameter error -
Err_InvalidParameterName error -
Err_InvalidPosition error -
Err_InvalidRefParameter error -
Err_InvalidScope error -
Err_InvalidSessionCookie error -
Err_InvalidVariableType error -
Err_JavaNotAvailable error -
Err_JVMLoadFailed error -
Err_LabelNotFound error -
Err_ListBufferTooSmall error -
Err_ListDontAcceptNames error -
Err_ListIsLocked error -
Err_ListOutOfBoundary error -
Err_LockNotSupported error -
Err_MemberIsNotStatic error -
Err_MemberIsStatic error -
Err_MemberOnUndefinedIdentifier error -
Err_MemoryFull error -
Err_MemorySlotsFull error -
Err_MethodNameConflict error -
Err_MultipartObjectDuplicated error -
Err_NameTooLong error -
Err_NoResolveOnDupList error -
Err_NoSuchApplication error -
Err_NoSuchClass error -
Err_NoSuchClassOrFunction error -
Err_NoSuchConstant error -
Err_NoSuchFunction error -
Err_NoSuchMember error -
Err_NoSuchMethod error -
Err_NoSuchProperty error -
Err_NotAllowedInDestructor error -
Err_NotAnExtendingClass error -
Err_NotImplemented error -
Err_NullSizeBlock error -
Err_ObjectCantBePersistent error -
Err_ObjectIsLocked error -
Err_ObjectNotFound error -
Err_OnErrorNotBalanced error -
Err_OperatorExpected error -
Err_OSError error -
Err_OutOfBoundary error -
Err_Overflow error -
Err_PageInNotDefined error -
Err_PageOutNotDefined error -
Err_ParameterNameTooLong error -
Err_PathTooLong error -
Err_ProcessShutDown error -
Err_PropertyIsOnlyRead error -
Err_PrototypeMismatch error -
Err_QuotesExpected error -
Err_RefParameterRequired error -
Err_ReservedKeyword error -
Err_ReturnValueRequired error -
Err_RoundBracketExpected error -
Err_RoundBracketNotBalanced error -
Err_ScopeConflict error -
Err_SessionIsDisabled error -
Err_SlotMgrUnavailable error -
Err_SquareBracketExpected error -
Err_StackOverflow error -
Err_StringTooLong error -
Err_SuperConstructorRequired error -
Err_SuperIsUndefined error -
Err_TextUtilsNotInitialized error -
Err_ThisIsUndefined error -
Err_ThreadNotFound error -
Err_ThreadsInternalErr error -
Err_ThreadTimeout error -
Err_Timeout error -
Err_TooLongDefault error -
Err_TooLongHexLiteral error -
Err_TooLongName error -
Err_TooManyIncludes error -
Err_TooManyVariablesInExpression error -
Err_UndefinedIdentifier error -
Err_UnknownError error -
Err_UnknownGroup error -
Err_UnknownOperator error -
Err_UnknownUser error -
Err_UnknownXLibError error -
Err_UnknownXLibHelpersError error -
Err_VariableDuplicatedInURL error -
Err_VariableNotDefined error -
Err_VariableNotInitialized error -
Err_VariableNotPublished error -
Err_WalkFolderAbort error -
Err_XLibCallerTooNew error -
Err_XLibCallerTooOld error -
Err_XLibTooNew error -
Err_XLibTooOld error -
UserBreak error -

Name

error —

Synopsis

The error class.c

Implemented in the C language.

Description

n.a.


Name

error —

Synopsis

void error(theError,  
 theSubError,  
 class); 
int  theError;
string  theSubError;
string  class;

Description

Describes an object representing a Biferno error.Usually biferno initializes a global variable named "err" in every script. If an error occurs that variable is set automatically to the error, than the execution of the script is stopped, unless method.error.Resume is set.

Parameters

theError

The number of the error

theSubError

The number of the sub error if theError parameter indicates a family of errors (i.e. "Err_OSError")

class

If the error is a class error, the name of the class

Note

Normally the user has no need to initialize an error variable, he needs only to analyze the global err variable


Name

Function —

Synopsis

string Function();

Description

n.a.


Name

Resume —

Synopsis

void Resume(funcName);
string funcName;

Description

n.a.

Parameters

funcName

n.a.


Name

State —

Synopsis

boolean State();

Description

n.a.


Name

Suspend —

Synopsis

void Suspend();

Description

n.a.


Name

ThrowException —

Synopsis

void ThrowException(errNum,  
 class); 
int  errNum;
string  class;

Description

This method causes an exception in the script. The process is than suspended depending on OnErrorResume value.

Parameters

errNum

The number of the error to be throwed

class

If the error is a class error, the class of the error

See Also

OnErrorResume


Name

Update —

Synopsis

void Update();

Description

This method updates all the properties of an error variable to the correct values. In fact, when an error is initialized, some properties remain invalid until Update is invoked on it. For example biferno calls Update on global err whenever an error occurrs.


Name

classNote —

Synopsis

string  classNote

Description

If the error was caused by a class method or property, classNote can contain a message of the class describing the cause of the error.


Name

descr —

Synopsis

string  descr

Description

A short description of the error


Name

errClass —

Synopsis

string  errClass

Description

If the error was caused by a class method or property, errClass contains the name of the class causing the error.


Name

errNum —

Synopsis

int  errNum

Description

The error number


Name

fileOffset —

Synopsis

int  fileOffset

Description

n.a.


Name

lastMultiStrLine —

Synopsis

int  lastMultiStrLine

Description

n.a.


Name

line —

Synopsis

string  line

Description

The line of the script file containing the statement that caused the error


Name

lineNum —

Synopsis

int  lineNum

Description

The number of the line of the script file containing the statement that caused the error


Name

msg —

Synopsis

string  msg

Description

A message that can help to solve the problem that caused the error


Name

name —

Synopsis

string  name

Description

The name of the error. Generally, it is an error of a class ("error" or others)


Name

path —

Synopsis

string  path

Description

The complete path of the file in which the error occurred


Name

resumable —

Synopsis

boolean  resumable

Description

If false, the error is blocking also if OnErrorResume is on. If true the error resumes normal operation if OnErrorResume is on.


Name

subErr —

Synopsis

string  subErr

Description

If the error contains a sub error (as, for example, Err_OSError), subErr contains the sub error string. It can be platform or DBMS (or other) dependent


Name

subErrDescr —

Synopsis

string  subErrDescr

Description

If the error contains a sub error (as, for example, Err_OSError), subErrDescr contains a description of the sub error string. It can be platform or DBMS (or other) dependent


Name

table —

Synopsis

string  table

Description

Contains an (html) text with a table of all the variables state at error time. It is the same displayed in the standard biferno error page.


Name

Err_AbsolutePathRequired —

Synopsis

int  Err_AbsolutePathRequired

Description

An absolute (not relative) path is required


Name

Err_ApplicationNameDuplicated —

Synopsis

int  Err_ApplicationNameDuplicated

Description

An application with this name already exist


Name

Err_ApplicationNameNotFoundInConfig —

Synopsis

int  Err_ApplicationNameNotFoundInConfig

Description

n.a.


Name

Err_ApplicationNameTooLong —

Synopsis

int  Err_ApplicationNameTooLong

Description

The name of the application is too long (> 255)


Name

Err_ArrayElementNotFound —

Synopsis

int  Err_ArrayElementNotFound

Description

An array element with this name doesn't exist


Name

Err_ArrayElementsTypeCastFailed —

Synopsis

int  Err_ArrayElementsTypeCastFailed

Description

n.a.


Name

Err_ArrayMismatch —

Synopsis

int  Err_ArrayMismatch

Description

n.a.


Name

Err_ArrayRequired —

Synopsis

int  Err_ArrayRequired

Description

Variable must be an array


Name

Err_AttachCurrentThreadException —

Synopsis

int  Err_AttachCurrentThreadException

Description

n.a.


Name

Err_BadArrayIndex —

Synopsis

int  Err_BadArrayIndex

Description

The index of the array is invalid (= 0 or inappropriate string)


Name

Err_BadBifernoSID —

Synopsis

int  Err_BadBifernoSID

Description

The BifernoSID string contains invalid character (valid chars are: '.', '-' and numbers)


Name

Err_BadBlockSize —

Synopsis

int  Err_BadBlockSize

Description

The size of the block is invalid (= 0)


Name

Err_BadFileRef —

Synopsis

int  Err_BadFileRef

Description

The file ref passed to XLib function is invalid


Name

Err_BadMemoryRef —

Synopsis

int  Err_BadMemoryRef

Description

The memory ref passed to XLib function is invalid


Name

Err_BadPrototype —

Synopsis

int  Err_BadPrototype

Description

There was a sintax error in function/method prototype declaration


Name

Err_BadSyntax —

Synopsis

int  Err_BadSyntax

Description

Invalid syntax


Name

Err_BadSyntaxInApplicationName —

Synopsis

int  Err_BadSyntaxInApplicationName

Description

The "Biferno.config.bfr" declaration of "APPLICATION_NAME" was not correct


Name

Err_BadSyntaxInURL —

Synopsis

int  Err_BadSyntaxInURL

Description

Invalid syntax in url


Name

Err_BAPI_BifernoTooNew —

Synopsis

int  Err_BAPI_BifernoTooNew

Description

Biferno context is too new to correctly load this extension

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_BifernoTooOld —

Synopsis

int  Err_BAPI_BifernoTooOld

Description

Biferno context is too old to correctly load this extension

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_BufferTooSmall —

Synopsis

int  Err_BAPI_BufferTooSmall

Description

The storage for the request object is too small to contain it

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_EndOfObject —

Synopsis

int  Err_BAPI_EndOfObject

Description

BAPI_ReadObj reached the end of the object data

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_ErrorsAlreadyRegistered —

Synopsis

int  Err_BAPI_ErrorsAlreadyRegistered

Description

n.a.


Name

Err_BAPI_ExtensionNameRequired —

Synopsis

int  Err_BAPI_ExtensionNameRequired

Description

The name of the extension was not filled

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_ExtensionTooNew —

Synopsis

int  Err_BAPI_ExtensionTooNew

Description

The extension is too new to run in this Biferno context

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_ExtensionTooOld —

Synopsis

int  Err_BAPI_ExtensionTooOld

Description

The extension is too old to run in this Biferno context

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_InvalidAPIData —

Synopsis

int  Err_BAPI_InvalidAPIData

Description

An invalid api_data was passed to a BAPI call

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_InvalidParameter —

Synopsis

int  Err_BAPI_InvalidParameter

Description

Invalid parameters were passed to a BAPI call

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_LoopAbort —

Synopsis

int  Err_BAPI_LoopAbort

Description

Error sed to stop the BAPI_ArrayLoop

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_MessageNotHandled —

Synopsis

int  Err_BAPI_MessageNotHandled

Description

The extension didn't handle the message (Divert to super?)

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_ObjAlreadyToDestruct —

Synopsis

int  Err_BAPI_ObjAlreadyToDestruct

Description

BAPI_ForceDestructor was called twice on an object

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_ObjNotPrintable —

Synopsis

int  Err_BAPI_ObjNotPrintable

Description

The object can't be printable (method tostring not found)

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_ObjNotToDestruct —

Synopsis

int  Err_BAPI_ObjNotToDestruct

Description

BAPI_AvoidDestructor was called twice on an object

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_SymbolNotFound —

Synopsis

int  Err_BAPI_SymbolNotFound

Description

BAPI_GetSymbol couldn't find the requested symbol

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BAPI_UnknowExtensionType —

Synopsis

int  Err_BAPI_UnknowExtensionType

Description

The extension is not a C or Biferno extension (should never happen)

Note

BAPI (Biferno Application Programming Interface) error


Name

Err_BifernoConfigNotFound —

Synopsis

int  Err_BifernoConfigNotFound

Description

A "Biferno.config.bfr" file was not found


Name

Err_BuffersBadID —

Synopsis

int  Err_BuffersBadID

Description

The buffer id is invalid


Name

Err_BuffersNotInitialized —

Synopsis

int  Err_BuffersNotInitialized

Description

The Buffer manager is not initialized


Name

Err_CacheNotInitialized —

Synopsis

int  Err_CacheNotInitialized

Description

The Cache manager is not initialized


Name

Err_CachePathTooLong —

Synopsis

int  Err_CachePathTooLong

Description

The path passed to the cache is too long (> 255)


Name

Err_CantAccessThisMember —

Synopsis

int  Err_CantAccessThisMember

Description

The member is private or protected from external access


Name

Err_CantCloseShLib —

Synopsis

int  Err_CantCloseShLib

Description

Close of DLL failed


Name

Err_CantFindShLibSymbol —

Synopsis

int  Err_CantFindShLibSymbol

Description

The DLL symbol can't be found


Name

Err_CantLoadShObject —

Synopsis

int  Err_CantLoadShObject

Description

The DLL can't be loaded


Name

Err_CantModifyLength —

Synopsis

int  Err_CantModifyLength

Description

Attempt to change a size of a fixed size object failed


Name

Err_ClassError —

Synopsis

int  Err_ClassError

Description

n.a.


Name

Err_ClassIsStatic —

Synopsis

int  Err_ClassIsStatic

Description

The class is completely static and refuses to instance objects


Name

Err_ClassRedeclared —

Synopsis

int  Err_ClassRedeclared

Description

n.a.


Name

Err_CommaOrRoundSquareExpected —

Synopsis

int  Err_CommaOrRoundSquareExpected

Description

Character "," or ")" was expected


Name

Err_ConnectionBroken —

Synopsis

int  Err_ConnectionBroken

Description

The connection was reset by the server


Name

Err_ConvertingStringToLong —

Synopsis

int  Err_ConvertingStringToLong

Description

Conversion from string to long long failed


Name

Err_CookieDisabled —

Synopsis

int  Err_CookieDisabled

Description

The user agent has cookie disabled


Name

Err_CurlyBracketExpected —

Synopsis

int  Err_CurlyBracketExpected

Description

n.a.


Name

Err_CurlyBracketNotBalanced —

Synopsis

int  Err_CurlyBracketNotBalanced

Description

n.a.


Name

Err_DateTimeFormatError —

Synopsis

int  Err_DateTimeFormatError

Description

The format string for date/time record is invalid


Name

Err_DuplicatedArrayElemName —

Synopsis

int  Err_DuplicatedArrayElemName

Description

An array element with this name already exists


Name

Err_DuplicatedConstructor —

Synopsis

int  Err_DuplicatedConstructor

Description

n.a.


Name

Err_DuplicatedFile —

Synopsis

int  Err_DuplicatedFile

Description

A file with the same name exists in this location


Name

Err_DuplicatedLabel —

Synopsis

int  Err_DuplicatedLabel

Description

A label with this name already exists


Name

Err_DuplicatedObject —

Synopsis

int  Err_DuplicatedObject

Description

A DLM object with this name already exists


Name

Err_DuplicatedParameter —

Synopsis

int  Err_DuplicatedParameter

Description

Function's parameters name or position must be unique


Name

Err_DuplicatedPropertyName —

Synopsis

int  Err_DuplicatedPropertyName

Description

Property names must be univoque


Name

Err_EmptyExpression —

Synopsis

int  Err_EmptyExpression

Description

The expression can't be empty


Name

Err_EmptyName —

Synopsis

int  Err_EmptyName

Description

n.a.


Name

Err_EndOfFile —

Synopsis

int  Err_EndOfFile

Description

The end of file was reached


Name

Err_EndOfLineOrSemicolonExpected —

Synopsis

int  Err_EndOfLineOrSemicolonExpected

Description

n.a.


Name

Err_ExplicitTypeCastRequired —

Synopsis

int  Err_ExplicitTypeCastRequired

Description

An explicit typeCast is required


Name

Err_FileNotFound —

Synopsis

int  Err_FileNotFound

Description

The requested file was not found


Name

Err_FolderIsNotEmpty —

Synopsis

int  Err_FolderIsNotEmpty

Description

The operation failed because he directory is not empty


Name

Err_FolderNotFound —

Synopsis

int  Err_FolderNotFound

Description

The requested path doesn't exist


Name

Err_FreeBlock —

Synopsis

int  Err_FreeBlock

Description

Attempt to dispose a memory block twice


Name

Err_FunctionIsVoid —

Synopsis

int  Err_FunctionIsVoid

Description

Invalid return value in void function


Name

Err_FunctionRedeclared —

Synopsis

int  Err_FunctionRedeclared

Description

n.a.


Name

Err_HTTPBodyTooLong —

Synopsis

int  Err_HTTPBodyTooLong

Description

The size of POST data is greater then MAX specified in form action


Name

Err_IllegalArrayInURL —

Synopsis

int  Err_IllegalArrayInURL

Description

Multidimensional arrays cannot be declared in URL


Name

Err_IllegalAssignment —

Synopsis

int  Err_IllegalAssignment

Description

Assignment of a void object


Name

Err_IllegalConstantExpression —

Synopsis

int  Err_IllegalConstantExpression

Description

Invalid constant expression


Name

Err_IllegalConstantParameter —

Synopsis

int  Err_IllegalConstantParameter

Description

A constant cannot be passed as reference


Name

Err_IllegalDeclaration —

Synopsis

int  Err_IllegalDeclaration

Description

n.a.


Name

Err_IllegalFlowControl —

Synopsis

int  Err_IllegalFlowControl

Description

This flow control is inappropriate here


Name

Err_IllegalOperation —

Synopsis

int  Err_IllegalOperation

Description

Operation not permitted


Name

Err_IllegalOperationOnConstant —

Synopsis

int  Err_IllegalOperationOnConstant

Description

Constant variables cannot be modified


Name

Err_IllegalOperationOnMethod —

Synopsis

int  Err_IllegalOperationOnMethod

Description

Can't operate on a method


Name

Err_IllegalRef —

Synopsis

int  Err_IllegalRef

Description

n.a.


Name

Err_IllegalScopeForObject —

Synopsis

int  Err_IllegalScopeForObject

Description

n.a.


Name

Err_IllegalSetProperty —

Synopsis

int  Err_IllegalSetProperty

Description

Can't set a property of a initialized instance


Name

Err_IllegalTypeCast —

Synopsis

int  Err_IllegalTypeCast

Description

TypeCast between classes failed


Name

Err_IllegalUndef —

Synopsis

int  Err_IllegalUndef

Description

Can't undef a literal or operation resulting variable


Name

Err_InvalidArrayIndex —

Synopsis

int  Err_InvalidArrayIndex

Description

The index of the array is invalid


Name

Err_InvalidCharacter —

Synopsis

int  Err_InvalidCharacter

Description

n.a.


Name

Err_InvalidErrorValue —

Synopsis

int  Err_InvalidErrorValue

Description

The value of an error in a class declaration is invalid (=0)


Name

Err_InvalidEscapeSequence —

Synopsis

int  Err_InvalidEscapeSequence

Description

n.a.


Name

Err_InvalidIndex —

Synopsis

int  Err_InvalidIndex

Description

The specified index is invalid


Name

Err_InvalidLength —

Synopsis

int  Err_InvalidLength

Description

The length of the object to add is invalid


Name

Err_InvalidListRef —

Synopsis

int  Err_InvalidListRef

Description

The DLM list ref is invalid


Name

Err_InvalidListType —

Synopsis

int  Err_InvalidListType

Description

The list type is invalid (possible values are: ID_LIST, NAME_LIST, NAMECS_LIST)


Name

Err_InvalidName —

Synopsis

int  Err_InvalidName

Description

A generic identifier is not valid


Name

Err_InvalidParameter —

Synopsis

int  Err_InvalidParameter

Description

n.a.


Name

Err_InvalidParameterName —

Synopsis

int  Err_InvalidParameterName

Description

A parameter with this name doesn't exist


Name

Err_InvalidPosition —

Synopsis

int  Err_InvalidPosition

Description

The position of the new object is invalid


Name

Err_InvalidRefParameter —

Synopsis

int  Err_InvalidRefParameter

Description

n.a.


Name

Err_InvalidScope —

Synopsis

int  Err_InvalidScope

Description

This scope is invalid (possible scopes are: local, global, application, session, persistent)


Name

Err_InvalidSessionCookie —

Synopsis

int  Err_InvalidSessionCookie

Description

The cookie sent from the user agent (BIFERNO_SID) is invalid


Name

Err_InvalidVariableType —

Synopsis

int  Err_InvalidVariableType

Description

n.a.


Name

Err_JavaNotAvailable —

Synopsis

int  Err_JavaNotAvailable

Description

n.a.


Name

Err_JVMLoadFailed —

Synopsis

int  Err_JVMLoadFailed

Description

n.a.


Name

Err_LabelNotFound —

Synopsis

int  Err_LabelNotFound

Description

The requested label to go was not found


Name

Err_ListBufferTooSmall —

Synopsis

int  Err_ListBufferTooSmall

Description

The storage passed to DLM is too small to contain the requested object


Name

Err_ListDontAcceptNames —

Synopsis

int  Err_ListDontAcceptNames

Description

The list doesn't accept object names


Name

Err_ListIsLocked —

Synopsis

int  Err_ListIsLocked

Description

Attempt to change an object in a locked list


Name

Err_ListOutOfBoundary —

Synopsis

int  Err_ListOutOfBoundary

Description

The id of the object is out of list boundary


Name

Err_LockNotSupported —

Synopsis

int  Err_LockNotSupported

Description

The lock of files is not supported


Name

Err_MemberIsNotStatic —

Synopsis

int  Err_MemberIsNotStatic

Description

Trying to call a non static member without an instance


Name

Err_MemberIsStatic —

Synopsis

int  Err_MemberIsStatic

Description

Trying to call a static member using an instance


Name

Err_MemberOnUndefinedIdentifier —

Synopsis

int  Err_MemberOnUndefinedIdentifier

Description

Can't apply a member to an undefined identifier


Name

Err_MemoryFull —

Synopsis

int  Err_MemoryFull

Description

There is not enough memory to perform operation


Name

Err_MemorySlotsFull —

Synopsis

int  Err_MemorySlotsFull

Description

n.a.


Name

Err_MethodNameConflict —

Synopsis

int  Err_MethodNameConflict

Description

A method with this name already exists in the class


Name

Err_MultipartObjectDuplicated —

Synopsis

int  Err_MultipartObjectDuplicated

Description

A multipart objects with this name already exists from POST data

In the same form cannot be declared two input fields of type "file" with the same name. In that case the target script will return the error: Err_MultipartObjectDuplicated.


Name

Err_NameTooLong —

Synopsis

int  Err_NameTooLong

Description

the name of the object is too long (> 255)


Name

Err_NoResolveOnDupList —

Synopsis

int  Err_NoResolveOnDupList

Description

DLM_ResolveArrayElem can't be called on a list with duplicated names


Name

Err_NoSuchApplication —

Synopsis

int  Err_NoSuchApplication

Description

An application with this name doesn't exist


Name

Err_NoSuchClass —

Synopsis

int  Err_NoSuchClass

Description

A class with this name doesn't exist


Name

Err_NoSuchClassOrFunction —

Synopsis

int  Err_NoSuchClassOrFunction

Description

A class or function with this name doesn't exist


Name

Err_NoSuchConstant —

Synopsis

int  Err_NoSuchConstant

Description

The object has not a constant property with this name


Name

Err_NoSuchFunction —

Synopsis

int  Err_NoSuchFunction

Description

A function with this name doesn't exist


Name

Err_NoSuchMember —

Synopsis

int  Err_NoSuchMember

Description

The class or the object has not a member with this name


Name

Err_NoSuchMethod —

Synopsis

int  Err_NoSuchMethod

Description

The object has not a method with this name


Name

Err_NoSuchProperty —

Synopsis

int  Err_NoSuchProperty

Description

The object has not a property with this name


Name

Err_NotAllowedInDestructor —

Synopsis

int  Err_NotAllowedInDestructor

Description

n.a.


Name

Err_NotAnExtendingClass —

Synopsis

int  Err_NotAnExtendingClass

Description

The class doesn't extend another class, so it has no super object


Name

Err_NotImplemented —

Synopsis

int  Err_NotImplemented

Description

The function is not implemented in this version of XLib


Name

Err_NullSizeBlock —

Synopsis

int  Err_NullSizeBlock

Description

Can't allocate a null size block of memory


Name

Err_ObjectCantBePersistent —

Synopsis

int  Err_ObjectCantBePersistent

Description

The variable belong to a class incompatible with persistent scope


Name

Err_ObjectIsLocked —

Synopsis

int  Err_ObjectIsLocked

Description

Attempt to change a locked object failed


Name

Err_ObjectNotFound —

Synopsis

int  Err_ObjectNotFound

Description

An object with this name was not found


Name

Err_OnErrorNotBalanced —

Synopsis

int  Err_OnErrorNotBalanced

Description

Calls to OnErrorSuspend didn't match calls to OnErrorResume


Name

Err_OperatorExpected —

Synopsis

int  Err_OperatorExpected

Description

An operator (and not an identifier) was expected


Name

Err_OSError —

Synopsis

int  Err_OSError

Description

Operating System error


Name

Err_OutOfBoundary —

Synopsis

int  Err_OutOfBoundary

Description

The index exceeds the limits of the array


Name

Err_Overflow —

Synopsis

int  Err_Overflow

Description

The variable cannot contain this value (see limits for numeric classes)


Name

Err_PageInNotDefined —

Synopsis

int  Err_PageInNotDefined

Description

Variable global pageIn is not correctly initialized


Name

Err_PageOutNotDefined —

Synopsis

int  Err_PageOutNotDefined

Description

Variable global pageOut is not correctly initialized


Name

Err_ParameterNameTooLong —

Synopsis

int  Err_ParameterNameTooLong

Description

n.a.


Name

Err_PathTooLong —

Synopsis

int  Err_PathTooLong

Description

The path is too long (> 255)


Name

Err_ProcessShutDown —

Synopsis

int  Err_ProcessShutDown

Description

The operation failed because Biferno is reloading or shutting down


Name

Err_PropertyIsOnlyRead —

Synopsis

int  Err_PropertyIsOnlyRead

Description

The property can only be accessed for read, not write, operation


Name

Err_PrototypeMismatch —

Synopsis

int  Err_PrototypeMismatch

Description

The call doesn't match the function/method prototype


Name

Err_QuotesExpected —

Synopsis

int  Err_QuotesExpected

Description

Quotas (' or " ) expected


Name

Err_RefParameterRequired —

Synopsis

int  Err_RefParameterRequired

Description

n.a.


Name

Err_ReservedKeyword —

Synopsis

int  Err_ReservedKeyword

Description

Can't use this name for a variable because it is a reserved keyword


Name

Err_ReturnValueRequired —

Synopsis

int  Err_ReturnValueRequired

Description

The function requires a return value


Name

Err_RoundBracketExpected —

Synopsis

int  Err_RoundBracketExpected

Description

n.a.


Name

Err_RoundBracketNotBalanced —

Synopsis

int  Err_RoundBracketNotBalanced

Description

n.a.


Name

Err_ScopeConflict —

Synopsis

int  Err_ScopeConflict

Description

n.a.


Name

Err_SessionIsDisabled —

Synopsis

int  Err_SessionIsDisabled

Description

Seesion are disabled (set application SESSION to true)


Name

Err_SlotMgrUnavailable —

Synopsis

int  Err_SlotMgrUnavailable

Description

n.a.


Name

Err_SquareBracketExpected —

Synopsis

int  Err_SquareBracketExpected

Description

n.a.


Name

Err_StackOverflow —

Synopsis

int  Err_StackOverflow

Description

n.a.


Name

Err_StringTooLong —

Synopsis

int  Err_StringTooLong

Description

The string is too long


Name

Err_SuperConstructorRequired —

Synopsis

int  Err_SuperConstructorRequired

Description

n.a.


Name

Err_SuperIsUndefined —

Synopsis

int  Err_SuperIsUndefined

Description

Using the keyword "super" is inappropriate here


Name

Err_TextUtilsNotInitialized —

Synopsis

int  Err_TextUtilsNotInitialized

Description

The XLib Text Manager manager is not initialized