reformat source code

according to code styles, 'AccessModifierOffset' should be -2.
This commit is contained in:
gm
2021-06-16 15:48:42 +08:00
committed by MizuhaHimuraki
parent 8c4a2f26a6
commit 4a92b6d7df
3314 changed files with 23131 additions and 23401 deletions

View File

@ -34,7 +34,7 @@ class Service {
// Deliver is the class that transfers the result of unpacking RpcHandler to the corresponding queue. Here will be
// countered The deliver method of Service facilitates the integration of logic into the Service class.
class Deliver : public ObReqQDeliver {
public:
public:
Deliver(ObiReqQHandler& qhandler, Service& service) : ObReqQDeliver(qhandler), service_(service)
{}
int init() override
@ -45,24 +45,24 @@ class Service {
{}
int deliver(rpc::ObRequest& req) override;
private:
private:
Service& service_;
};
// Translator is responsible for translating an ObRequest request into the corresponding Processor. Here will
// Reverse the translate method of Service, so that the logic is concentrated in the Service.
class Translator : public ObReqTranslator {
public:
public:
Translator(Service& service) : service_(service)
{}
protected:
protected:
ObReqProcessor* get_processor(ObRequest& req) override;
private:
private:
Service& service_;
};
public:
public:
Service(int listen_port = 33244)
: easy_(),
translator_(*this),
@ -95,11 +95,11 @@ class Service {
template <class Proc>
int reg_processor(Proc* p);
protected:
protected:
ObReqProcessor* translate(ObRequest& req);
int deliver(ObRequest& req);
private:
private:
ObNetEasy easy_;
Translator translator_;
ObReqQHandler qhandler_;