home *** CD-ROM | disk | FTP | other *** search
/ OpenStep 4.2J (Developer) / os42jdev.iso / NextDeveloper / OpenStepConversion / 3.3Headers / eoaccess / EOAttributeOrdering.h < prev    next >
Encoding:
Text File  |  1994-05-24  |  1.4 KB  |  45 lines

  1. // EOAttributeOrdering.h
  2. // Copyright (c) 1994, NeXT Computer, Inc. All rights reserved.
  3.  
  4. #import <foundation/NSArray.h>
  5. #import <foundation/NSData.h>
  6. #import <foundation/NSDictionary.h>
  7. #import <foundation/NSObject.h>
  8. #import <foundation/NSString.h>
  9.  
  10. @class EOAttribute;
  11.  
  12. typedef enum {
  13.     EOAnyOrder, EOAscendingOrder, EODescendingOrder
  14. } EOOrdering;
  15.     // EOOrdering encodes the three possible orders for a set of values.
  16.  
  17.  
  18. // EOAttributeOrdering defines the order in which rows/objects are returned
  19. // when fetching.  You usually create EOAttributeOrderings and put them into
  20. // an NSArray for a select operation.  The order within the array determines
  21. // the precedence when sorting.  See any of the methods that use a fetchOrder:
  22. // keyword in the selector for further information.
  23.  
  24.  
  25. @interface EOAttributeOrdering:NSObject <NSCopying>
  26. {
  27.     EOAttribute *_attribute;
  28.     EOOrdering _ordering;
  29. }
  30.  
  31. + attributeOrderingWithAttribute:(EOAttribute *)attribute 
  32.     ordering:(EOOrdering)ordering;
  33.     // Convenience method to return an autoreleased EOAttributeOrdering.
  34.  
  35. - initWithAttribute:(EOAttribute *)attribute ordering:(EOOrdering)ordering;
  36.     // Initializes the receiver with attribute and ordering. Returns self.
  37.  
  38. - (EOAttribute *)attribute;
  39.     // Returns the attribute that the ordering is defined for.
  40.  
  41. - (EOOrdering)ordering;
  42.     // Returns the ordering defined for the attribute.
  43.  
  44. @end
  45.