Out (keyword)
From RemObjects Software
The out keyword causes arguments to be passed into method by reference. Similar to var, but it does not need to be initialized by the caller.
Example
method Method1(out i: Integer); begin i := 44; end; method Method2; begin var value: Integer; Method1(out value); // value is now 44 end;
The .NET runtime does not really support out params though, so when you define them in Oxygene (or C#) they are really just var parameters with that attribute. The compiler doesn't really treat the [Out] attribute as special, but just uses it when it finds the out keyword.
See Also
- Special Attributes
- var keyword
Product: RemObjects Oxygene (formerly known as Chrome)
Current version: 3.0
Previous Versions: 'Joyride' (2.0), 'Floorshow' (1.5), 'Adrenochrome' (1.0)
Glossary — Keywords — Language Features — Platform Features — Samples — Articles — How To — Issues
Categories: Text | Oxygene | Language | Keyword
