Author:admin

Date:2008-09-19T14:06:51.000000Z


git-svn-id: https://svn.eiffel.com/eiffel-org/trunk@28 abb3cda0-5349-4a8f-a601-0c33ac3a8c38
This commit is contained in:
jfiat
2008-09-19 14:06:51 +00:00
parent 4087eb614e
commit a903078386
100 changed files with 122 additions and 16 deletions

View File

@@ -13,8 +13,8 @@ In order for us to communicate effectively about the activities of the method we
The method is laid out in wonderful detail in [http://www.eiffel.com/doc/oosc/ Object-oriented Software Construction, 2nd Edition]. But, if you're just getting started, you will find some good introductory material on this page. The invitation to Eiffel is fairly short introduction to the method and language. and the tutorial gives a more detailed look.
* An [[Invitation to Eiffel|Invitation to Eiffel]]
* [[An Eiffel Tutorial|Eiffel tutorial]]
* [[Invitation to Eiffel|Invitation to Eiffel]]
* [[An Eiffel Tutorial|An Eiffel tutorial]]
* Developers' quick reference to Eiffel the language

View File

@@ -1,6 +1,7 @@
[[Property:title|4 Classes]]
[[Property:link_title|I2E: Classes]]
[[Property:weight|-11]]
[[Property:uuid|218bead9-428e-f61d-1e45-7eea4291d895]]
A class, it was said above, is an implementation of an abstract data type. This means that it describes a set of run-time objects, characterized by the ''' features''' (operations) applicable to them, and by the formal properties of these features.
Such objects are called the '''direct instances''' of the class. Classes and objects should not be confused: "class" is a compile-time notion, whereas objects only exist at run time. This is similar to the difference that exists in classical programming between a program and one execution of that program, or between a type and a run-time value of that type.
@@ -13,7 +14,9 @@ A class <code> X </code> may become a client of <code> ACCOUNT </code> by declar
<code>acc: ACCOUNT</code>
The term "entity" generalizes the more common notion of "variable". An entity declared of a reference type, such as <code>acc</code>, may at any time during execution become " '''attached to''' " an object; the type rules imply that this object must be a direct instance of <code> ACCOUNT </code> -- or, as seen below, of a "descendant" of that class.
[[Image:invitation-2]]
[[Image:invitation-2]]
An entity is said to be void if it is not attached to any object. By default, entities are void at initialization. To obtain objects at run-time, a routine <code> r </code> appearing in the client class <code> X </code> may use a '''creation instruction''' of the form
<code>create acc</code>