FBGraphPerson.h 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. /*
  2. * Copyright 2010-present Facebook.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. #import <Foundation/Foundation.h>
  17. #import "FBGraphObject.h"
  18. /*!
  19. @protocol
  20. @abstract
  21. The `FBGraphPerson` protocol enables typed access to a person's name, photo
  22. and context-specific identifier as represented in the Graph API.
  23. @discussion
  24. The `FBGraphPerson` protocol provides access to the name, picture and context-specific
  25. ID of a person represented by a graph object. It may be used to access an `NSDictionary`
  26. object that has been wrapped with an <FBGraphObject> facade.
  27. */
  28. @protocol FBGraphPerson<FBGraphObject>
  29. /*!
  30. @property
  31. @abstract Typed access to the user ID.
  32. @discussion Note this typically refers to the "id" field of the graph object (i.e., equivalent
  33. to `[self objectForKey:@"id"]`) but is differently named to avoid conflicting with Apple's
  34. non-public selectors.
  35. */
  36. @property (retain, nonatomic) NSString *objectID;
  37. /*!
  38. @property
  39. @abstract Typed access to the user's name.
  40. */
  41. @property (retain, nonatomic) NSString *name;
  42. /*!
  43. @property
  44. @abstract Typed access to the user's first name.
  45. */
  46. @property (retain, nonatomic) NSString *first_name;
  47. /*!
  48. @property
  49. @abstract Typed access to the user's middle name.
  50. */
  51. @property (retain, nonatomic) NSString *middle_name;
  52. /*!
  53. @property
  54. @abstract Typed access to the user's last name.
  55. */
  56. @property (retain, nonatomic) NSString *last_name;
  57. @end