18.10.2014 Views

Object-oriented Software in Ada 95

Object-oriented Software in Ada 95

Object-oriented Software in Ada 95

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

388 Appendix C<br />

Width : <strong>in</strong> Field := 0);<br />

procedure Get(Item : out Num;<br />

Width : <strong>in</strong> Field := 0);<br />

procedure Put(File : <strong>in</strong> File_Type;<br />

Item : <strong>in</strong> Num;<br />

Fore : <strong>in</strong> Field := Default_Fore;<br />

Aft : <strong>in</strong> Field := Default_Aft;<br />

Exp : <strong>in</strong> Field := Default_Exp);<br />

procedure Put(Item : <strong>in</strong> Num;<br />

Fore : <strong>in</strong> Field := Default_Fore;<br />

Aft : <strong>in</strong> Field := Default_Aft;<br />

Exp : <strong>in</strong> Field := Default_Exp);<br />

procedure Get(From : <strong>in</strong> Str<strong>in</strong>g;<br />

Item : out Num;<br />

Last : out Positive);<br />

procedure Put(To : out Str<strong>in</strong>g;<br />

Item : <strong>in</strong> Num;<br />

Aft : <strong>in</strong> Field := Default_Aft;<br />

Exp : <strong>in</strong> Field := Default_Exp);<br />

end Fixed_IO;<br />

generic<br />

type Num is delta digits ;<br />

package Decimal_IO is<br />

Default_Fore : Field := Num'Fore;<br />

Default_Aft : Field := Num'Aft;<br />

Default_Exp : Field := 0;<br />

procedure Get(File : <strong>in</strong> File_Type;<br />

Item : out Num;<br />

Width : <strong>in</strong> Field := 0);<br />

procedure Get(Item : out Num;<br />

Width : <strong>in</strong> Field := 0);<br />

procedure Put(File : <strong>in</strong> File_Type;<br />

Item : <strong>in</strong> Num;<br />

Fore : <strong>in</strong> Field := Default_Fore;<br />

Aft : <strong>in</strong> Field := Default_Aft;<br />

Exp : <strong>in</strong> Field := Default_Exp);<br />

procedure Put(Item : <strong>in</strong> Num;<br />

Fore : <strong>in</strong> Field := Default_Fore;<br />

Aft : <strong>in</strong> Field := Default_Aft;<br />

Exp : <strong>in</strong> Field := Default_Exp);<br />

procedure Get(From : <strong>in</strong> Str<strong>in</strong>g;<br />

Item : out Num;<br />

Last : out Positive);<br />

procedure Put(To : out Str<strong>in</strong>g;<br />

Item : <strong>in</strong> Num;<br />

Aft : <strong>in</strong> Field := Default_Aft;<br />

Exp : <strong>in</strong> Field := Default_Exp);<br />

end Decimal_IO;<br />

--Generic package for Input-Output of Enumeration Types<br />

generic<br />

type Enum is ();<br />

package Enumeration_IO is<br />

Default_Width : Field := 0;<br />

Default_Sett<strong>in</strong>g : Type_Set := Upper_Case;<br />

procedure Get(File : <strong>in</strong> File_Type;<br />

Item : out Enum);<br />

© M A Smith - May not be reproduced without permission

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!