mirror of
https://github.com/Instagram/IGListKit
synced 2026-05-06 15:08:50 +00:00
Summary: Updating license language to meet FB open source standards. Pull Request resolved: https://github.com/Instagram/IGListKit/pull/1272 Differential Revision: D12844366 Pulled By: rnystrom fbshipit-source-id: 27ae49ae00d963c5c012c79c5738365c232a5773
38 lines
1.5 KiB
Objective-C
38 lines
1.5 KiB
Objective-C
/**
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
#import "IGListBatchUpdateData+DebugDescription.h"
|
|
|
|
@implementation IGListBatchUpdateData (DebugDescription)
|
|
|
|
- (NSArray<NSString *> *)debugDescriptionLines {
|
|
NSMutableArray *debug = [NSMutableArray new];
|
|
#if IGLK_DEBUG_DESCRIPTION_ENABLED
|
|
[debug addObject:[NSString stringWithFormat:@"Insert sections: %@", self.insertSections]];
|
|
[debug addObject:[NSString stringWithFormat:@"Delete sections: %@", self.deleteSections]];
|
|
|
|
for (IGListMoveIndex *move in self.moveSections) {
|
|
[debug addObject:[NSString stringWithFormat:@"Move from section %li to %li", (long)move.from, (long)move.to]];
|
|
}
|
|
|
|
for (NSIndexPath *path in self.deleteIndexPaths) {
|
|
[debug addObject:[NSString stringWithFormat:@"Delete section %li item %li", (long)path.section, (long)path.item]];
|
|
}
|
|
|
|
for (NSIndexPath *path in self.insertIndexPaths) {
|
|
[debug addObject:[NSString stringWithFormat:@"Insert section %li item %li", (long)path.section, (long)path.item]];
|
|
}
|
|
|
|
for (IGListMoveIndexPath *move in self.moveIndexPaths) {
|
|
[debug addObject:[NSString stringWithFormat:@"Move from section %li item %li to section %li item %li",
|
|
(long)move.from.section, (long)move.from.item, (long)move.to.section, (long)move.to.item]];
|
|
}
|
|
#endif // #if IGLK_DEBUG_DESCRIPTION_ENABLED
|
|
return debug;
|
|
}
|
|
|
|
@end
|