XBase

Procedure main () msgbox ( "Hello World "; " Xbase 1.90.355 " ) return

And Procedural Language

Xbase is a programming language for 32- bit and 64- bit platforms, the Alaska Software Inc. You can be both procedural and object-oriented uses, together with the unique strengths lie in the object orientation.

Functions

Xbase is equipped with an internal set of commands for working with dBASE or FoxPro databases, so no additional drivers ( no ODBC) or DBMS are required for working with DBF files. Xbase provides a complete integration of all common Windows Forms that are encapsulated within the program code as objects. In all Xbase object-oriented approaches are supported ( single and multiple inheritance, abstract classes, abstract methods, ...). In standard linguistic scope or in the supplied runtime libraries support for standard network protocols (except NetBIOS), such as TCP / IP, which can be compensated by a number of additional products but missing. There are also a number of other add-on libraries, with which, for example e- mail functionality via SMTP and POP3 protocol can be used. In addition, you can use the OpenGL interface or access any database via ODBC. The integration of ActiveX components is possible, as the use of. Net components. About a so-called Web Application Adaptor it is even possible to do business processes via the Internet and direct access via the Internet to dBASE databases. The result can then be easily represented in any browser or ActiveX components even in their own user interface.

In addition to the command-line commands Alaska provides the licensees to develop the free tool Visual Xbase is available.

Versions

  • Xbase 1.82, March 2003
  • Xbase 1.9, May 2006
  • Xbase 1.9 SL1 (build 1.90.355 level ), April 2009
  • Xbase 2.0 Arctica, on the occasion of the 4th European Xbase Developer Conference in April 2012 was provided to the participants in a conference build. Delivery of the RC1 version should be done for the 4th quarter of 2012.

Position in the market

Xbase is not so popular as other products, such as C , Visual Basic or C #. A major disadvantage is a direct result of the relatively low penetration of the market with products of this language, which inevitably reflected by the developers. The fact is his work not to the extent information is available, as is the case with the "big" languages ​​and many things, additional functionalities as described above, must be purchased from other suppliers for often a lot of money during this far into the used languages ​​are already part of the basic equipment. Until a few years ago there was for Xbase No officially by the manufacturer of the language ( Alaska Software ) displaced IDE. For some time now but the IDE Visual Xbase is offered, which is now to have version 2.0 (as of September 24, 2004 ).

A rival project to Xbase , the manufacturer xHarbour.

Xbase is compatible with Clipper, which enables a port of Clipper programs in the 32-bit Windows world and in the browser world.

Disadvantage of Xbase

It is not possible, component- based and cross-language working with Xbase . So you can indeed use in C or Visual Basic DLLs written, but conversely you can create with Xbase no DLLs that can be use from other languages ​​out.

Another disadvantage is that this language does not correspond to internationally recognized standard, but specified by a single company and is proprietary developed ( such as Visual Basic also, C does not ). With Xbase , it is still not possible to develop cross-platform, as it is a supported platform only Windows and the Web.

Syntax Example

The following sample source code shows a class whose object instances have only one method by which they collect all existing in a specified directory files of a certain type, store it in a class variable and display it in a simple message box.

# include " xbtsys.ch " # include " directry.ch "    / / First the class is defined    CLASS Folder Scanner       EXPORTED:          VAR Afiles          VAR cFileMask          VAR aFileMask          VAR CDIRectory             METHOD Init          METHOD List File From Folder    ENDCLASS       / / Then the methods are defined    METHOD Folder Scanner: Init ( cMask, CDIRectory )       / / The passed variables cMask and CDIRectory are automatically defined as LOCAL       IF ValType ( cMask ) == "C". AND.! EMPTY ( ALLTRIM ( cMask ) )          cFileMask ::: = ALLTRIM ( cMask )       ELSE          :: cFileMask: = ""       ENDIF          IF ValType ( CDIRectory ) == "C". AND.! EMPTY ( ALLTRIM ( CDIRectory ) )          / / But there should be no further instance variables with the same name          CDIRectory ::: = ALLTRIM ( CDIRectory )       ELSE          MSGBOX ( " No path specified for browsing. Program termination ", " Warning " )          QUIT       ENDIF       Afiles :: = { }       aFileMask :: = { }    RETURN self       METHOD Folder Scanner: List File From Folder ( )       LOCAL aX, i / / strict typing is not necessary       LOCAL cMessageString: = "" / / when declaring values ​​can be assigned             IF! Dirchange (:: CDIRectory ) == NO_DISK_ERR          / / Constants as NO_DISK_ERR can be defined in include files, similar to the *. H files in C          MSGBOX ( " The specified directory does not exist. Program termination ", " Warning " )          QUIT       ELSE          aX: = DIRECTORY ("*. " :: cFileMask )       ENDIF             FOR i: = 1 TO LEN ( aX )          IF UPPER ( RIGHT ( aX [i, F_NAME ], LEN ( cFileMask :: ))) == :: cFileMask             AADD (:: aFileMask, :: CDIRectory "\ " aX [i, F_NAME ] )             cMessageString = aX [i, F_NAME ] CHR ( 13 ) CHR ( 10)          ENDIF       NEXT             MSGBOX ( " For file mask " :: cFileMask;          " The following files were found in the specified directory :" ;          cMessageString, "result" )          RETURN self          / / For example, the class can be used    PROCEDURE Main ()       LOCAL oFolderscanner       oFolderscanner: = Folder scanner (): New ( "EXE ", "C: \ TEMP" )       oFolderscanner: List File From Folder ( )    RETURN References

de