Programming Interfaces

So far in this chapter we have taken a rather abstract view of communication services; specifying their behaviour in terms of a set of primitive operations that may be performed upon them. If these services are to be realised on systems, then these primitive operations will need to be mapped to constructs in a programming language. In a conventional language such as 'C', it is natural to make a correspondence between the abstract primitive operations and function calls; the parameters of the primitive operations becoming the parameters of the function calls. For the Transport Service considered earlier we might have: verbatim45 There are many decisions still to be made about how these functions should behave. Some of the key ones are: There are no 'best answers', to these questions and different implementors will make their own choices. They are free to do so since, as yet, there are no standards for programming interfaces. This is a little unfortunate since it might have been hoped that one benefit of standardisation would have been the easy portability of service implementations. We can now see that two implementations can conform to an OSI service in an exemplary way but be completely incompatible with respect to programming interfaces. Mapping one such interface to another is by no means a trivial task.