100 likes | 288 Views
Eiffel Overview by Norman Wong. May 10, 2001. Agenda. What’s Eiffel Language Environment Methodology Example Conclusion. What’s Eiffel. Eiffel is a pure object-oriented language Developed in 1985 by Bertrand Meyer (a French Computer Scientist)
E N D
Eiffel Overview byNorman Wong May 10, 2001
Agenda • What’s Eiffel • Language • Environment • Methodology • Example • Conclusion
What’s Eiffel • Eiffel is a pure object-oriented language • Developed in 1985 by Bertrand Meyer (a French Computer Scientist) • Syntax loosely derived from Simula, Pascal, Ada, ALGOL, CLU and Z • Eiffel is a methodology, language and environment for developing high-quality reusable software components.
Language • The Eiffel language includes many important features • Simple, highly readable syntax • Automatic memory management (garbage collection) • Disciplined exception handling • Interoperability with other languages such as C and C++ • Large collections of high-quality reusable class libraries for many application areas
Environment • Eiffel has a fully graphical environment: • Analysis and design workbench • Editor • Browser and debugger • Documentation
Methodology • Clean Multiple Inheritance • Renaming mechanism eliminates name clashes • Static, strong-typing • Errors are caught at compile time, not run time • All message binding is dynamic
Example Example of a bank account balance logic: classACCOUNT feature balance: INTEGER owner: PERSONminimum_balance: INTEGER is1000open (who: PERSON) is -- Assign the account to ownerwho. do owner := who end deposit (sum: INTEGER) is -- Deposit suminto the account. do add (sum) end
Example (Cont.) Withdraw (sum: INTEGER) is - Withdraw sum from the account. Do Add (-sum) End May_withdraw (sum: INTEGER): BOOLEAN is -- Is there enough money to withdrawsum? Do Result := (balance >= sum + minimum_balance) End Feature {NONE} Add (sum: INTEGER) is -- Addsumto the balance. Do Balance := balance + sum End End-- class ACCOUNT
Conclusion • Eiffel is a comprehensive approach to the development of high-quality software • Eiffel is quickly becoming the language of choice for teaching modern software technology
Resources • See the ISE (Interactive Software Engineering) Web page: http://www.eiffel.com/ • “Data Structures and Software Development” Eiffel Edition by Jean-Paul Tremblay and Grant A. Cheston