Data abstraction

From: Glen Goodwin <acme_ent_at_bellsouth.net>
Date: Sun Mar 3 01:32:14 2002

> From: Fred Cisin (XenoSoft) <cisin_at_xenosoft.com>

> Consider three hypothetical forms of source code:
>
> A: MOV AH, 2
> MOV DL, 41h
> INT 21h
>
> B: MOV AH, 2 ; character display function
> MOV DL, 'B'
> INT 21h ; DOS API
>
> C: MOV AH, DISPLAY
> MOV DL, OURCHAR
> INT DOSSERVICES
>
> I prefer B, but there were a few cases where I felt that he was tending
> towards C. (and plenty of times when I slip into writing A)

Yeah, the book is pretty much type 'C' code.
 
> Abstraction is very useful and necessary for some types of portability.
> But I don't like to have to go thorough a separate .H file to find out
> what the code is that is being abstracted.

Yeah, it's a hassle, but I think it's worth it to get easily-portable code.
 Only a few lines need to be changed to move the code to another machine.
All in all I would recommend this book. Plus you, Fred Cisin, got double
kudos ;>)

Glen
0/0
Received on Sun Mar 03 2002 - 01:32:14 GMT

This archive was generated by hypermail 2.3.0 : Fri Oct 10 2014 - 23:35:09 BST