torawsocket.hh
来自「Click is a modular router toolkit. To us」· HH 代码 · 共 52 行
HH
52 行
// -*- mode: c++; c-basic-offset: 2 -*-#ifndef CLICK_TORAWSOCKET_HH#define CLICK_TORAWSOCKET_HH#include <click/element.hh>#include "rawsocket.hh"CLICK_DECLS/*=cToRawSocket("TCP", <TCP source port number>)ToRawSocket("UDP", <UDP source port number>)ToRawSocket("GRE", <GRE key or PPTP call ID>)ToRawSocket("ICMP", <ICMP identifier>)=s commsends IP packets through a safe raw socket (user-level)=dWrites data to a raw IPv4 socket. The raw IPv4 socket may optionallybe bound to a source port number in the case of TCP/UDP, a GRE key orPPTP call ID in the case of GRE, or an identifier in the case ofICMP. Binding a port to a raw IPv4 socket to reserve it and suppressTCP RST and ICMP Unreachable errors, is specific to PlanetLab Linux.This element exists only for backward compatibility. See the moregeneral RawSocket implementation for details, and for supportedkeyword arguments. A ToRawSocket is equivalent to a RawSocket withno outputs.=e ... -> ToRawSocket(UDP, 47)=a FromRawSocket, RawSocket, Socket */class ToRawSocket : public RawSocket { public: ToRawSocket(); ~ToRawSocket(); const char *class_name() const { return "ToRawSocket"; } const char *processing() const { return PULL; } const char *flow_code() const { return "x/y"; }};CLICK_ENDDECLS#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?