Archive for June, 2012

The implementation side of framing

The specification In the previous article the specification of a buffer of elements of a certain type has been described. Let us repeat here shortly the essence of the specification. class BUFFER[G] feature capacity: NATURAL content: ghost LIST[G] count: NATURAL ensure Result = content.count end [] (i:NATURAL): G require i < count ensure Result ~ […]

Leave a comment

Abstraction wins: An approach to framing and mutability

Basics Modern Eiffel has immutable and mutable types. An object of immutable type cannot be modified, an object of mutable type can be modified. Therefore we say that an object is mutable or immutable depending on its type. Immutable objects don’t have an own identity. The identity of an immutable object is completely determined by […]