home *** CD-ROM | disk | FTP | other *** search
/ OpenStep (Enterprise) / OpenStepENTCD.toast / OEDEV / EODEV.Z / EOMInspector.h < prev    next >
Encoding:
Text File  |  1996-09-09  |  1.7 KB  |  69 lines

  1. /*    Inspector.h
  2.     Abstract class for all inspectors
  3.     Bertrand, Sep 95
  4.     Copyright 1995, NeXT Software, Inc.
  5.     All rights reserved.
  6. */
  7.  
  8. #import <EOInterface/EOInterface.h>
  9.  
  10. @interface EOMInspector:NSObject {
  11.     NSView    *view;
  12.     NSWindow    *window;
  13.     NSImage    *image;             // required, by convention same as class name
  14.     NSImage    *hilightedImage; // computed
  15. }
  16.  
  17. + (NSArray *)allRegisteredInspectors;
  18.  
  19. + (NSArray *)allInspectorsThatCanInspectObject:(id)selObj;
  20.     // calls canInspectObject: on all registered inspectors
  21.     // and returns result
  22.  
  23. + (EOMInspector *)sharedInspector;
  24.  
  25. - init;
  26.     // designated initializer
  27.  
  28. - (NSString *)displayName;
  29.     // defaults to the the window name
  30.  
  31. - (NSImage *)image;
  32.  
  33. - (NSImage *)hilightedImage;
  34.  
  35. - (float)displayOrder;
  36.     // subclasses override to specify where they should appear in
  37.     // inspector list
  38.  
  39. - (BOOL)canInspectObject:(id)selObj;
  40.     // subclasses override to determine whether they can inspect the current
  41.     // object.  E.g.: return [selObj isKindOfClass:[EOAttribute class]]
  42.  
  43. - (void)load;
  44.     // should load.  default implementation loads nib file with
  45.     // name matching class name.  Subclasses should do other initialization
  46.     // here.
  47.  
  48. - (void)prepareForDisplay;
  49.     // is view==nil, calls load  
  50.  
  51. - (NSView *)view;
  52.     // defined for all Inspector subclasses
  53.     // used by InspectorController
  54.  
  55. - (void)refresh;
  56.     // must be redefined by subclass
  57.     // default is to do nothing
  58.  
  59. - (NSArray *)selectedObjects;
  60.     // Convenience to facilitate implementation of an inspector
  61.  
  62. - (id)selectedObject;
  63.     // Convenience to facilitate implementation of an inspector
  64.  
  65. - (BOOL)isAdvanced;
  66.     // advanced inspectors are displayed only if the user checks
  67.     // "Display Advanced Options"  Default is NO.
  68. @end
  69.