Realbasic: Difference between revisions

Content deleted Content added
SmackBot (talk | contribs)
m Date maintenance tags and general fixes
{{redr}} is deprecated - converting to {{Redirect category shell|}} using AWB
 
(92 intermediate revisions by 53 users not shown)
Line 1:
#REDIRECT [[Xojo]]
{{Infobox software
| name = REALbasic
| logo =
| screenshot = [[Image:Realbasic2007winide.png|center|250px|REALbasic 2007 IDE]]
| caption = The REALbasic IDE running on [[Windows Vista]]
| developer = REAL Software, Inc.
| latest_release_version = 2009 Release 4
| latest_release_date = {{release_date|2009|9|29}}
| operating_system = [[Mac OS X]], [[Microsoft Windows]], [[Linux]]
| genre = [[Programming]]
| license = [[Proprietary software|Proprietary]]
| website = http://www.realsoftware.com
}}
'''REALbasic''' ('''RB''') is an [[object-oriented]] dialect of the [[BASIC programming language]] developed and commercially marketed by REAL Software, Inc of [[Austin, Texas]] for [[Mac OS X]], [[Microsoft Windows]], and 32-bit x86 [[Linux]].
 
{{Redirect category shell|
== History ==
{{R from former name}}
REALbasic was created by Andrew Barry. It was originally called CrossBasic due to its ability to compile the same programming code for Mac OS and [[Java (programming language)|Java]] (although the [[integrated development environment]] was Mac only). In [[1997]] CrossBasic was purchased by FYI Software which renamed it REALbasic as well as renaming the company REAL Software. At this time they dropped the Java target, later replacing it with a Windows target and database support. The [[Integrated development environment|IDE]] is now available for [[Microsoft Windows]], [[Mac OS X]], and 32-bit x86 [[Linux]] and can compile applications for Windows (Windows 2000 and higher), Mac OS X ([[PowerPC]], [[Intel]], and [[Universal Binary]]) and 32-bit [[x86]] Linux.
{{R from merge}}
 
== Language features ==
 
Although REALbasic (RB) uses the word "basic" in its description as a variant of the BASIC programming language, RB is not compliant with the ANSI Standard for the BASIC programming language. For example, the ANSI Standard source code of simple demo programs in TrueBASIC will not compile in RB without a complete rewrite. RB also does not support the standard matrix math operations "MAT" that make ANSI BASIC a helpful{{Citation needed|date=December 2009}} tool for the teaching of introductory programming concepts.
 
RB is a [[strongly typed]] language with minimal automatic type conversion, which supports [[single inheritance]] and [[Interface (computer science)|interfaces]], [[Class (computer science)|class]] [[Method (computer science)|methods]] and class properties, automatic memory management via [[reference counting]], and [[operator overloading]]. A very important feature is the ability to '''extend''' (not just [[Inheritance (computer science)|inherit]] from) existing classes, like [[Objective-C#Categories (Programming languages)|Objective-C Categories]]. This considerably reduces the need for the [[Abstract factory pattern|Abstract Factory Pattern]], which complicates using Application Frameworks in [[Java (programming language)|Java]] and [[C++]]. REALbasic also includes [[Delegation (programming)|delegates]], [[Introspection (computer science)|introspection]], and [[Namespace (computer science)|namespace]] support, which allows modules to contain classes, interfaces and other modules.
 
== Framework features ==
As described in the language reference, its built-in framework supports (REAL Software 2008):
* [[hash table|dictionaries]],
* [[declaration]]s to external libraries (dll, dylib)
* [[Visual Basic]] datatypes compatibility,
* full [[Unicode]] support,
* [[regular expression]]s,
* [[application programming interface]] calls to compiled [[C (programming language)|C]] libraries on all supported platforms,
* [[ActiveX]] and basic [[OLE]] support (on Windows); [[Component Object Model|COM]] objects are '''not''' fully supported,
* [[Taskbar|Notification icons]] (on Windows),
* [[Windows registry]] (on Windows),
* [[Thread (computer science)|cooperative threads]],
* [[scripting language]] embedded in REALbasic programs through [[RBScript]],
* [[XML]] parsing and generation,
* [[Command line interface|console]] and [[Daemon (computer software)|service]] application support (Professional edition only)
* [[Apple events]] (on Mac),
* [[Address Book|Address book]] (on Mac),
* [[Keychain (Mac OS)|Keychain]] (on Mac),
* [[Spotlight (software)|Spotlight]] (on Mac),
* [[QuickTime]] (on Mac and Windows),
* sound,
* real-time [[3D computer graphics|3D graphics]],
* [[serial communications]],
* sockets (both [[TCP/IP|TCP]], [[UDP/IP|UDP]] and [[IPC|Inter-process_communication]]),
* [[Transport Layer Security|SSL]] (Professional edition only),
* [[HTTP]], [[Post Office Protocol|POP3]], [[Simple Mail Transfer Protocol|SMTP]] and [[SOAP]]
 
The framework functionality can also be extended by creating [[plugin]]s using the [http://realsoftware.cachefly.net/REALbasic2007r5/PluginsSDK.zip Plugin SDK] provided by REAL Software. Plugins are created using C/C++ with a variety of supported compilers, including [[Xcode]], [[Visual Studio 2005|Microsoft Visual Studio]] and [[GNU Compiler Collection|gcc]]. Plugins can support any platform REALbasic supports, but are not required to support all platforms.
 
== File format ==
The source file format contains window and control placement data and is proprietary, although XML import and export are supported. All source code can be contained in one project file, but it is also possible to have classes/modules in separate files in the same way as most other languages or dialects can. REALbasic compiles directly to [[machine language]] for each platform that it supports. REALbasic 2006 Release 3 and newer also supports a human-readable [[Revision control|version control]] format which allows easy collaboration with tools such as [[Subversion (software)|Subversion]] or [[Concurrent Versions System|CVS]].
 
== Current editions of IDE ==
[[Image:REALbasic2006r3.png|thumbnail|300px|A typical GUI building session in REALbasic's IDE]]
There are three versions of the IDE:
*REAL Studio has all features of the Professional edition plus other features for full-time programmers.
* The professional edition can compile programs for Mac OS X (PowerPC Carbon [[Mach-O]], i386 Carbon Mach-O and Universal Binary), Linux and Windows from the same [[source code]] file; it can also access [[database]]s ([[REAL Server]],[[MySQL]],[[Oracle database|Oracle]], [[PostgreSQL]], [[ODBC]], etc.) including the built-in single-user REAL SQL Database engine based on [[SQLite]]; it compiles console applications, has a code profiler, can remote debug and has numerous other features.
* The personal edition only compiles programs for the platform that the IDE is running on (either Windows, Linux or Mac), and does not allow access to databases other than the built-in REAL SQL Database.
 
== IDE features ==
Both versions of the IDE permit building the application's [[graphical user interface]] by dragging the controls from a toolbar to their parent window. Layout of the controls is helped by the IDE, which permits aligning them (both horizontally and vertically) and which gives information about the distance between controls or between a control and the window borders.
 
Like many modern IDEs, the [[code editor]] supports customizable [[syntax highlighting]], [[Autocomplete|autocompletion]] and [[refactoring]] tools. The IDE also includes editors for [[Menu (computing)|menus]] and database [[logical schema|schema]] and viewers for multimedia files such as pictures, movies or sounds.
 
The IDE gives the programmer access to scripting features via RBScript, which allows control of the IDE for automating tasks such as running [[Regression testing|regression tests]] or doing nightly builds. The scripts can be either global or project-specific.
 
REALbasic supports [[Incremental compiler|incremental compilation]], whereby the compiler needs to recompile only those parts of a project which have been modified. For instance, if only the body of a method is modified, then only the project item containing that method need be recompiled.
 
== Example code ==
This is an example of operator overloading for a hypothetical Complex class which permits to sum a [[Real number|real]] to a [[complex number]], and to sum two complex numbers:
 
<source lang="vbnet">
Function Operator_Add (rhs As Single) As Complex
Dim ret As New Complex
ret.Real = Self.Real + rhs
ret.Imaginary = Self.Imaginary
Return ret
End Function
Function Operator_Add (rhs As Complex) As Complex
Dim ret As New Complex
ret.Real = Self.Real + rhs.Real
ret.Imaginary = Self.Imaginary + rhs.Imaginary
Return ret
End Function
</source>
 
The same function can be defined to accept [[Double precision|Double]] [[datatype]] values.
This code shows how to use the Complex class to sum a real with a complex number:
 
<source lang="vbnet">
Dim First As New Complex (0, 1)
Dim Second As New Complex (1, 1)
Dim Sum As Complex
Sum = First + 5.0 + Second
// Sum will be (6, 2)
</source>
 
== See also ==
* [[RBScript]] - related scripting language
 
=== Comparable Basic Dialects ===
* [[Gambas]] - a free approach to object basic
* [[Visual Basic]]
 
=== Other Programming Languages ===
* [[Comparison of programming languages]]
 
== References ==
{{refbegin}}
* {{cite web
|url=http://www.theregister.co.uk/2005/09/13/review_realbasic_2005/
|title=RealBasic 2005 for Mac, Windows and Linux
|date=September 13, 2005
|last=Smith
|first=Tony
|accessdate=2006-04-11
|publisher=[[The Register]]
}}
* {{cite web
|url=http://programming.linux.com/programming/05/08/03/1639214.shtml?tid=22
|title=Review: REALBasic 2005 for Linux
|date=August 4, 2005
|last=Barr
|first=Joe
|accessdate=2006-04-11
|publisher=Linux.com
}}
* {{cite web
|url=http://www.realsoftware.com/download/individual/
|title=REALbasic Language Reference
|date=May 6, 2008
|last=REAL Software
|accessdate=2008-05-06
|publisher=REAL Software
}}
* [[Erick Tejkowski|Tejkowski, Erick]] (2001). REALbasic for Dummies. Hungry Minds. ISBN 0764507931.
{{refend}}
 
==External links==
*[http://www.realsoftware.com/ REAL Software, Inc.], makers of REALbasic
*[http://forums.realsoftware.com/ REALbasic forums], Official REALbasic discussion forums
*[http://www.arbpmembers.org Association of REALbasic Professionals], Empowering the REALbasic community
*[http://ttpsoftware.com/ReallyBasicRB/index.html Really Basic REALbasic], introducing programming and REALbasic to beginners
*[http://www.rbgarage.com/rbg/ RB Garage], an open repository listing plugins, classes, modules, code examples etc.
*[http://www.rbdeveloper.com/ REALbasic Developer Magazine], a bi-monthly magazine about REALbasic development
*[http://www.rblibrary.com/ RBLibrary], a commercial resource of third party articles and tutorials
*[http://www.classicteck.com/rbdn.php REALDev], a wiki-powered developer community and code repository
*[http://www.rbdevzone.com RBDevZone], a community for professional REALbasic developers
*[http://www.declareSub.com declareSub.com], code, articles, and a book on declares
*[http://declaresub.com/wiki/index.php/Main_Page REALbasic Wiki], independent effort to extend REALbasic documentation
*[http://realbasic.tutspolis.com/ REALbasic City], a great collection of REALbasic tutorials
 
{{BASIC}}
 
[[Category:Articles with example BASIC code]]
[[Category:Integrated development environments]]
[[Category:Object-oriented programming languages]]
[[Category:Apple Design Award winners]]
 
[[de:REALbasic]]
[[et:REALBasic]]
[[es:REALbasic]]
[[fr:REALbasic]]
[[it:REALbasic]]
[[nl:REALbasic]]
[[ja:REALbasic]]
[[pt:RealBasic]]
[[ru:REALbasic]]
[[fi:REALBasic]]
[[sv:REALbasic]]
[[zh:REALbasic]]