home *** CD-ROM | disk | FTP | other *** search
/ Nebula 1995 August / NEBULA.bin / SourceCode / Palettes / TTools / TToolsPalette / Strings.subproj / StringAgent.m < prev    next >
Encoding:
Text File  |  1993-11-09  |  696 b   |  39 lines

  1. /* StringAgent.m
  2.  * Written By:  Thomas Burkholder
  3.  *
  4.  * You may freely copy, distribute, and reuse the code in this example.
  5.  * NeXT disclaims any warranty of any kind, expressed or  implied, as to its
  6.  * fitness for any particular use.
  7.  */
  8.  
  9. #import "StringAgent.h"
  10. #import "String.h"
  11.  
  12. @implementation StringAgent
  13.  
  14. - subdirectoryFor:anObject sender:sender
  15. {
  16.     return nil;
  17. }
  18.  
  19. - (BOOL)isLeaf:anObject sender:sender
  20. {
  21.     return YES;
  22. }
  23.  
  24. - (const char *)displayStringFor:anObject sender:sender
  25. {
  26.     return [anObject stringValue];
  27. }
  28.  
  29. - (int)compare:first with:second sender:sender
  30. {
  31.     return strcmp([first stringValue],[second stringValue]);
  32. }
  33.  
  34. - (const char *)titleOfColumn:(int)col
  35. {
  36.     return NULL;
  37. }
  38.  
  39. @end