home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / snip9707.zip / SNIPPETS.RAT < prev    next >
Text File  |  1997-07-05  |  4KB  |  89 lines

  1. +++Date last modified: 05-Jul-1997
  2.  
  3.                         SNIPPETS Rationale
  4.                         ------------------
  5.  
  6.  
  7. Where do SNIPPETS come from?
  8.  
  9. I'm constantly on the lookout for new SNIPPETS material. The goal of SNIPPETS
  10. has been to collect useful pieces of code that would be free for reuse. This
  11. limits consideration to code that is either explicitly in the public domain
  12. or which carries a free use license with few or no restrictions which would
  13. prevent its use. Current SNIPPETS material has been collected from the
  14. FidoNet C_Echo, comp.lang.c on the Internet, various public domain archives,
  15. and my own commercial library (MFL).
  16.  
  17.  
  18. How are SNIPPETS selected?
  19.  
  20. As the collection has evolved, it's taken on distinguishing characteristics
  21. based largely, I'm afraid, on what sorts of things interest me. A primary
  22. focus of SNIPPETS is portability - first of all between DOS compilers, and
  23. secondly with the larger world of Unix and other platforms. I tend to be
  24. interested in the same problem domain as Posix - system and utility
  25. functions. What I'm not interested in trying to include are things which
  26. really require massive amounts of code to do right (e.g.  GUIs, databases,
  27. interrupt-driven comm I/O, game-quality graphics, multimedia, etc.) and are
  28. therefore better addressed by large single-purpose packages, whether
  29. commercial or otherwise.
  30.  
  31. In addition to the utility stuff, I also snag anything that seems moderately
  32. obscure (e.g. ISBN validation, wind chill, sunrise/set time, etc.) Whether I
  33. need to know these things or not, someone sometime will need to be able to do
  34. these and I like to be able to provide the option of a simple canned solution
  35. rather than sending them on a research spree.
  36.  
  37.  
  38. What makes one SNIPPETS entry "better" than other candidates?
  39.  
  40. Anything that enhances portability or usability is better in my book. Note
  41. that I'm not necessarily soliciting completion to full library standards. As
  42. the name SNIPPETS implies, many of the entries knowingly have minimal
  43. bullet-proofing. Most of the entries I've excerpted from MFL differ only in
  44. that my commercial code provides bullet-proof error trapping at the cost of
  45. slightly obfuscating the algorithms. In cases where error trapping would, in
  46. my opinion, make the algorithm harder to follow, I've generally opted for
  47. clarity over safety. This was a conscious decision since the target audience
  48. for SNIPPETS includes both newbies and experienced programmers. The pros will
  49. recognize the shortcomings and know to add the error trapping, but the tyros
  50. can tend to get lost. My yardstick on this has been feedback. If too many
  51. tyros have to ask how it works, then I try to simplify and/or make the
  52. underlying algorithm stand out. If too many folks complain about it being
  53. unsafe, I add more bullet-proofing. When I hear as little from both sides as
  54. possible, I figure I've achieved the desired balance. 
  55.  
  56.  
  57. Is the SNIPPETS collection only for PC's?
  58.  
  59. No. More and more portable code has been introduced into the collection over
  60. the years so that now there is more portable code (although some will require
  61. minor work) than PC-specific code. Beginning with the October, 1995 release,
  62. operating system and/or environmental dependencies are listed in the SNIPPETS
  63. master index file, SNIPPETS.NDX. Beginning with the same release, SNIPPETS
  64. testing has become more thorough with the goal of verifying portability
  65. claims. The current testing regimen seeks to assure a minimum level of
  66. portability between all major DOS/Windows compilers, extended DOS, OS/2,
  67. Linux, and as many Unix systems as I can find with people willing to test
  68. (currently I have testers signed up using HP/UX, Solaris, AIX, and Linux).
  69. Increased testing is also underway under Win 32 (Windows 95 & NT), with more
  70. added all the time.
  71.  
  72.  
  73. Is SNIPPETS only a collection of C code?
  74.  
  75. No. There have always been a few PC-specific assembly routines in SNIPPETS,
  76. and the current collection includes a growing number of reusable C++ classes.
  77. In some cases, SNIPPETS includes both a C and C++ solution to a particular
  78. programming question.
  79.  
  80.  
  81. Bob Stout
  82. FidoNet:    1:106/2000.6
  83.             C_Echo moderator (1990-1991, 1996-1997)
  84. Internet:   rbs@snippets.org
  85.             rbs@brokersys.com
  86. SnailMail:  MicroFirm
  87.             P.O. Box 428
  88.             Alief, TX 77411
  89.