products/sources/formale Sprachen/VDM/VDMPP/TempoCollaborativePP image not shown  

Quellcode-Bibliothek

© Kompilation durch diese Firma

[Weder Korrektheit noch Funktionsfähigkeit der Software werden zugesichert.]

Datei: Clock.vdmpp   Sprache: VDM

\section{The Class Clock}

This class models a clock which maintains a date. 

\begin{vdm_al}
class Clock

types
  public Date = seq of char;

instance variables
  date : Date := [];

operations
  public SetDate : Date ==> ()
  SetDate(d) ==
    date := d;

  pure public GetDate : () ==> Date
  GetDate() ==
    return date;

end Clock
\end{vdm_al}

[ zur Elbe Produktseite wechseln0.16Quellennavigators  Analyse erneut starten  ]