Summary


In this chapter, the file handling APIs were discussed with examples provided for each. The character interfaces were first explored ( fputc , fgetc ), followed by the string interfaces ( fputs , fgets ). Some of the more structured methods for generating and parsing files were then investigated (such as the fprintf and fscanf functions), in addition to some of the other possibilities ( sprintf and sscanf ). Finally, the topics of binary files and random (nonsequential) access were discussed, including methods for saving and restoring file positions .




GNU/Linux Application Programming
GNU/Linux Application Programming (Programming Series)
ISBN: 1584505680
EAN: 2147483647
Year: 2006
Pages: 203
Authors: M. Tim Jones

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net