commit | author | age
|
bad748
|
1 |
// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. |
W |
2 |
// |
|
3 |
// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, |
|
4 |
// copy, modify, and distribute this software in source code or binary form for use |
|
5 |
// in connection with the web services and APIs provided by Facebook. |
|
6 |
// |
|
7 |
// As with any software that integrates with the Facebook platform, your use of |
|
8 |
// this software is subject to the Facebook Developer Principles and Policies |
|
9 |
// [http://developers.facebook.com/policy/]. This copyright notice shall be |
|
10 |
// included in all copies or substantial portions of the software. |
|
11 |
// |
|
12 |
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
|
13 |
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS |
|
14 |
// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR |
|
15 |
// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER |
|
16 |
// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN |
|
17 |
// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
|
18 |
|
|
19 |
#import <Foundation/Foundation.h> |
|
20 |
|
|
21 |
#import <FBSDKCoreKit/FBSDKCopying.h> |
|
22 |
|
|
23 |
#import <FBSDKShareKit/FBSDKShareOpenGraphValueContainer.h> |
|
24 |
|
9febd9
|
25 |
/** |
W |
26 |
An Open Graph Object for sharing. |
|
27 |
|
|
28 |
The property keys MUST have namespaces specified on them, such as `og:image`, |
bad748
|
29 |
and `og:type` is required. |
W |
30 |
|
|
31 |
See https://developers.facebook.com/docs/sharing/opengraph/object-properties for other properties. |
|
32 |
|
|
33 |
You can specify nested namespaces inline to define complex properties. For example, the following |
|
34 |
code will generate a fitness.course object with a location: |
|
35 |
|
|
36 |
FBSDKShareOpenGraphObject *course = [FBSDKShareOpenGraphObject objectWithProperties: |
|
37 |
@{ |
|
38 |
@"og:type": @"fitness.course", |
|
39 |
@"og:title": @"Sample course", |
|
40 |
@"fitness:metrics:location:latitude": @"41.40338", |
|
41 |
@"fitness:metrics:location:longitude": @"2.17403", |
|
42 |
}]; |
|
43 |
*/ |
|
44 |
@interface FBSDKShareOpenGraphObject : FBSDKShareOpenGraphValueContainer <FBSDKCopying, NSSecureCoding> |
|
45 |
|
9febd9
|
46 |
/** |
W |
47 |
Convenience method to build a new action and set the object for the specified key. |
13e53a
|
48 |
@param properties Properties for the Open Graph object, which will be parsed into the proper models |
bad748
|
49 |
*/ |
W |
50 |
+ (instancetype)objectWithProperties:(NSDictionary *)properties; |
|
51 |
|
9febd9
|
52 |
/** |
W |
53 |
Compares the receiver to another Open Graph Object. |
13e53a
|
54 |
@param object The other object |
H |
55 |
@return YES if the receiver's values are equal to the other object's values; otherwise NO |
bad748
|
56 |
*/ |
W |
57 |
- (BOOL)isEqualToShareOpenGraphObject:(FBSDKShareOpenGraphObject *)object; |
|
58 |
|
|
59 |
@end |