Content deleted Content added
No edit summary |
Jerryobject (talk | contribs) →Database support: WP:LINKs: update-standardizes, needless-WP:PIPEs > WP:NOPIPEs, adds. MOS:FIRSTABBReviations clarify, define before parenthetic WP:ABBRs. Small WP:COPYEDITs WP:EoS: WP:TERSE, clarify. |
||
(10 intermediate revisions by 9 users not shown) | |||
Line 1:
{{
{{
{{
{{
}}
{{Use dmy dates|date=June 2014}}
{{Infobox programming language
| name
| logo
| logo caption
| screenshot =
| paradigm = [[Multi-paradigm programming language|multi-paradigm]]: [[Imperative programming|imperative]], [[Functional programming|functional]], [[Object-oriented programming|object-oriented]], [[Reflective programming|reflective]]▼
| screenshot caption =
| year = {{Start date and age|1999}}▼
▲| paradigm
| designer = Antonio Linares▼
| family = [[xBase]]
| developer = Viktor Szakáts and community▼
| latest_release_date = {{Start date and age|df=yes|2011|07|17}}▼
| latest_preview_version = [https://sourceforge.net/projects/harbour-project/files/binaries-windows/nightly/ 3.2.0dev]▼
| latest release version = 3.0.0
| typing = Optionally [[duck typing|duck]], [[dynamic typing|dynamic]], [[type safety|safe]], partially [[strong typing|strong]]▼
| implementations =▼
▲|
| dialects = Clipper, Xbase++, FlagShip, FoxPro, xHarbour▼
▲| typing
| influenced = [[xHarbour]]▼
| operating system = [[Cross-platform software|Cross-platform]]
| license
| website
|
| wikibooks
| influenced by = [[dBase]], [[Clipper (programming language)|Clipper]]
}}
'''Harbour''' is a computer [[programming language]],
Harbour code
==History==
The idea of a free software Clipper compiler had been
In 2009, Harbour was substantially redesigned, mainly by Viktor Szakáts and Przemyslaw Czerpak.
==Database support==
Harbour extends the Clipper Replaceable Database Drivers (RDD) approach. It offers multiple RDDs such as [[
Harbour also offers [[ODBC]] support by means of an [[
[[xBase]] technologies
==Programming philosophy==
Harbour aims to be [[Write once, compile anywhere|written once, compiled anywhere]]. As the same compiler is available for all of the above operating systems, there is no need for
Under Linux and Windows Mobile, Clipper source code can be compiled with Harbour with very little adaptation. Most software originally written to run on Xbase++, FlagShip, FoxPro, xHarbour and others dialects can be compiled with Harbor with some adaptation. As of 2010 many efforts have been made to make the transition from other [[xBase]] dialects easier.
Line 55 ⟶ 56:
[[MinGW]],
[[Clang]],
[[Intel C++ Compiler
[[Microsoft Visual C++]] (6.0+),
[[Borland C++]],
Line 64 ⟶ 65:
Harbour can make use of multiple Graphical Terminal emulation, including console drivers, and Hybrid Console/GUIs, such as GTWvt, and GTWvg.
Harbour supports external GUI's, free (e.g. HBQt, HWGui, Mini-GUI (latest version based on Qt and QtContribs<ref>{{cite web |title=QtContribs - Harbour Qt Projects |url=https://sourceforge.net/projects/qtcontribs/ |website=SourceForge |date=6 July 2023 |language=en}}</ref>) and commercial (e.g. FiveWin, Xailer). HBQt is a library providing bindings to Qt. HBIDE application is a sample of HBQt potential.
Harbour is 100% Clipper-compatible<ref>{{cite web|url=https://harbour.github.io/ |title=Official Harbour page |publisher=The Harbour Project |access-date=2013-12-09}}</ref> and supports many language syntax extensions including greatly extended run-time libraries such as [[OLE Automation|OLE]], Blat, [[OpenSSL]], Free Image, [[GD Graphics Library|GD]], hbtip, hbtpathy, [[PCRE]], hbmzip ([[zlib]]), hbbz2 ([[bzip2]]), [[cURL]], [[Cairo (graphics)|Cairo]], its own implementation of CA-Tools, updated NanFor libraries and many others. Harbour has an active development community and extensive third party support.
Line 70 ⟶ 71:
Any [[xBase]] language provides a very productive way to build business and data intensive applications. Harbour is not an exception.
===Macro
One of the most powerful features of xBase languages is the [[Macro (computer science)|Macro]] Operator '&'. Harbour's implementation of the Macro Operator allows for runtime compilation of any valid Harbour expression. Such a compiled expression may be used as a VALUE, i.e. the right side of an assignment (rvalue)
Additionally, the Macro Operator may compile and execute function calls, complete assignments, or even list of arguments, and the result
The latest Macro compiler can compile any valid Harbour code including code to per-process before compile.
Line 91 ⟶ 92:
is the short form of &( SomeId + "postfix" ).
===Object-oriented
Programming in an OOP style is a broader issue than a specific library or a specific interface, but OOP programming is something many Clipper programmers have come to expect. CA-Clipper 5.2 and especially 5.3 added a number of base classes, and a matching OOP syntax. Libraries such as [https://web.archive.org/web/20010501165630/http://appsolutions.com/Classy/ Class(y)], FieWin, Clip4Win, and Top Class provide additional OOP functionality.
Line 117 ⟶ 118:
Hashes may use ''any'' type including other Hashes as the ''Key'' for any element. Hashes and Arrays may contain ''any'' type as the ''Value'' of any member, including nesting arrays, and Hashes.
Codeblocks may have references to Variables of the Procedure/Function>method in which it was defined. Such Codeblocks may be returned as a value, or by means of an argument passed {{
Detached variables will maintain their value for as long as a Codeblock referencing them still exists. Such values will be shared with any other Codeblock which may have access to those same variables. If the Codeblock did not outlive its containing routine, and will be evaluated within the lifetime of the routine in which it is defined, changes to its ''Detached Variables''(s) by means of its evaluation, will be reflected back at its parent routine.
Codeblocks can be evaluated any number of times, by means of the {{
===Variables===
Line 128 ⟶ 129:
'''Variables have one of the following scopes:'''
* {{
* {{
* {{
* {{
{{
Due to the dynamic nature of {{
=== Control structures ===
The basic control structures include all of the standard [[dBase]], and [[Clipper (programming language)|Clipper]] control structures as well as additional ones inspired by the [[C (programming language)|C]] or [[Java (programming language)|Java]] programming languages:
Line 255 ⟶ 256:
===Sample code===
The typical "[["Hello, World!" program|hello world]]" program would be:
<syntaxhighlight lang="foxpro">
? "Hello, world!"
Line 354 ⟶ 355:
==xHarbour comparison==
The Harbour developers have attempted to document all hidden behaviour in the Clipper language and test Harbour-compiled code alongside the same code compiled with Clipper to maintain compatibility.
Line 363 ⟶ 364:
==GUI libraries and tools==
*
*
*
*
*
*
*
==See also==
* [[Visual FoxPro]]
* [[Visual Objects]]
* [[XBase
* [[PWCT]] free open source visual programming language support Harbour through [[PWCT#Visual
==References==
Line 381 ⟶ 382:
==External links==
* {{
* [https://harbour.github.io/the-oasis/ The Oasis] Clipper, FoxPro and Xbase++ community repository
* [http://hbide.vouch.info/ HBIDE]
Line 387 ⟶ 388:
* [https://groups.google.com/group/harbour-users/ Harbour Users Mailing List]
* [http://www.kresin.ru/en/harbour.html Extensive Harbour documentation, libraries, tools site]
*
{{xBase}}
Line 408 ⟶ 409:
[[Category:Free software programmed in C]]
[[Category:Multi-paradigm programming languages]]
[[Category:Table-oriented programming]]
<!-- Hidden categories below -->
[[Category:Articles with example code]]
|