Rename SonarCppBridgingResponder

Summary: Renames SonarCppBridgingResponder

Reviewed By: passy

Differential Revision: D10028084

fbshipit-source-id: d45b50a659710fb6e535241780a335a124582a47
This commit is contained in:
Pritesh Nandgaonkar
2018-09-25 13:27:32 -07:00
committed by Facebook Github Bot
parent ccf47e75fd
commit e6aeb24fcc
4 changed files with 6 additions and 31 deletions

View File

@@ -9,7 +9,7 @@
#import <FBCxxUtils/FBCxxFollyDynamicConvert.h>
#import "SonarCppBridgingResponder.h"
#import "FlipperCppBridgingResponder.h"
@implementation FlipperCppBridgingConnection
{
@@ -36,8 +36,8 @@
const auto lambda = [receiver](const folly::dynamic &message,
std::unique_ptr<facebook::flipper::FlipperResponder> responder) {
@autoreleasepool {
SonarCppBridgingResponder *const objCResponder =
[[SonarCppBridgingResponder alloc] initWithCppResponder:std::move(responder)];
FlipperCppBridgingResponder *const objCResponder =
[[FlipperCppBridgingResponder alloc] initWithCppResponder:std::move(responder)];
receiver(facebook::cxxutils::convertFollyDynamicToId(message), objCResponder);
}
};

View File

@@ -13,6 +13,6 @@ SonarCppBridgingResponder is a simple ObjC wrapper around FlipperResponder
that forwards messages to the underlying C++ responder. This class allows
pure Objective-C plugins to send messages to the underlying responder.
*/
@interface SonarCppBridgingResponder : NSObject <FlipperResponder>
@interface FlipperCppBridgingResponder : NSObject <FlipperResponder>
- (instancetype)initWithCppResponder:(std::unique_ptr<facebook::flipper::FlipperResponder>)responder;
@end

View File

@@ -5,11 +5,11 @@
* file in the root directory of this source tree.
*
*/
#import "SonarCppBridgingResponder.h"
#import "FlipperCppBridgingResponder.h"
#import <FBCxxUtils/FBCxxFollyDynamicConvert.h>
@implementation SonarCppBridgingResponder {
@implementation FlipperCppBridgingResponder {
std::unique_ptr<facebook::flipper::FlipperResponder> responder_;
}

View File

@@ -1,25 +0,0 @@
/*
* Copyright (c) 2018-present, Facebook, Inc.
*
* This source code is licensed under the MIT license found in the LICENSE
* file in the root directory of this source tree.
*
*/
#import <Foundation/Foundation.h>
/**
Acts as a hook for providing return values to remote called from Sonar desktop plugins.
*/
@protocol SonarResponder
/**
Respond with a successful return value.
*/
- (void)success:(NSDictionary *)response;
/**
Respond with an error.
*/
- (void)error:(NSDictionary *)response;
@end