Line data Source code
1 : /* 2 : * Copyright (c) 2013 Juniper Networks, Inc. All rights reserved. 3 : * Copyright Contributors to the OpenSDN project 4 : */ 5 : 6 : #include "kstate.h" 7 : #include "drop_stats_kstate.h" 8 : #include <iomanip> 9 : #include <sstream> 10 : #include "vr_defs.h" 11 : 12 : using namespace std; 13 : 14 0 : DropStatsKState::DropStatsKState(KDropStatsResp *obj, 15 : const std::string &resp_ctx, 16 0 : vr_drop_stats_req &req) 17 0 : : KState(resp_ctx, obj) { 18 0 : req.set_h_op(sandesh_op::GET); 19 0 : req.set_vds_rid(0); 20 0 : } 21 : 22 0 : void DropStatsKState::Handler() { 23 0 : KDropStatsResp *resp = static_cast<KDropStatsResp *>(response_object_); 24 0 : if (resp) { 25 0 : resp->set_context(response_context_); 26 0 : resp->Response(); 27 : } 28 0 : } 29 :