Display Preferences
RTL Changes for XE2
From RAD Studio XE2
Go Up to What's New in Delphi and C++Builder XE2
Contents |
Changes to the RTL
- Cross-platform RTL: You can now use the Delphi RTL for cross-platform development on the following platforms:
- Unit scope names: In RAD Studio libraries, unit names now have a unit scope or dotted-name prefix. You can see the unit scope names in the uses and includes generated by the wizards and templates in RAD Studio. The help, however, is using the non-unit-scoped names. For more information, see Unit Scope Names.
- System.SysUtils provides the TOSVersion record so that the application can get information about the operating system on which it runs.
- Use the System. SysUtils.FileSystemAttributes function to find whether the file system on a specific drive supports symbolic links, and so on. See the supported attributes here: System.SysUtils.TFileSystemAttribute.
- Support has been added for low-level operations on floating-point variables: Use the following records to perform low-level changes on floating-point values:
- System.SysUtils.TEncoding.Default returns a System.SysUtils.SysUtils.TUTF8Encoding variable on Mac OS X.
- A new unit, System.UITypes, contains a number of pre-existing members that are grouped together for ease of use in cross-platform development.
- There is a new System.Zip utility for creating and extracting Zip files.
- The TList member FList is now of type TPointerList (it was PPointerList).
- TLoginCredentialService represents an extensible, framework agnostic, login credential service with support for callbacks (success, failure).
- New methods for TPoint, TRect, TSize. These types have now floating-point versions: TPointF, TRectF, TSizeF.
Changes to the RTTI
RTTI for Indexed Properties
Indexed properties can have RTTI generated. See Run-Time Operations on Types (section "Working with Indexed Properties").
RTTI for Record Methods
Record methods can have RTTI generated. See the Rtti.TRttiRecordType functions and the TRttiRecordType (Delphi) code example.
System.Rtti.TVirtualInterface
The System.Rtti.TVirtualInterface class provides additional support for remote procedure call marshaling. Use this class to create an implementation of an interface at run time. This functionality is necessary when working with SOAP, for example.
System.Rtti.TRttiInstanceType
System.Rtti.TRttiInstanceType provides RTTI for implemented interfaces. Use the following methods to get the interfaces implemented by a specific type: