OpenSDN source code
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
PhysicalInterface Class Reference

#include <physical_interface.h>

Inheritance diagram for PhysicalInterface:
Collaboration diagram for PhysicalInterface:

Classes

struct  Bond_ChildIntf
 

Public Types

enum  SubType { FABRIC, VMWARE, CONFIG, INVALID }
 
enum  EncapType { ETHERNET, RAW_IP }
 
typedef std::map< const
std::string, Bond_ChildIntf
BondChildIntfMap
 
typedef
BondChildIntfMap::const_iterator 
BondChildIntfMapIterator
 
- Public Types inherited from Interface
enum  Type {
  INVALID, PHYSICAL, REMOTE_PHYSICAL, LOGICAL,
  VM_INTERFACE, INET, PACKET
}
 
enum  Trace {
  ADD, DEL, ACTIVATED, DEACTIVATED,
  FLOATING_IP_CHANGE, SERVICE_CHANGE
}
 
enum  MirrorDirection { MIRROR_RX_TX, MIRROR_RX, MIRROR_TX, UNKNOWN }
 
enum  Transport {
  TRANSPORT_INVALID, TRANSPORT_VIRTUAL, TRANSPORT_ETHERNET, TRANSPORT_SOCKET,
  TRANSPORT_PMD
}
 
- Public Types inherited from AgentDBEntry
typedef boost::intrusive_ptr
< AgentDBEntry
AgentDBEntyRef
 
- Public Types inherited from DBEntryBase
typedef DBTableBase::ListenerId ListenerId
 
typedef std::unique_ptr
< DBRequestKey
KeyPtr
 

Public Member Functions

 PhysicalInterface (const std::string &name, const boost::uuids::uuid &logical_router_uuid)
 
virtual ~PhysicalInterface ()
 
virtual bool CmpInterface (const DBEntry &rhs) const
 
virtual std::string ToString () const
 
virtual KeyPtr GetDBRequestKey () const
 
virtual void PostAdd ()
 
virtual bool Delete (const DBRequest *req)
 
virtual bool OnChange (const InterfaceTable *table, const PhysicalInterfaceData *data)
 
SubType subtype () const
 
PhysicalDevicephysical_device () const
 
const std::string & display_name () const
 
bool persistent () const
 
EncapType encap_type () const
 
bool no_arp () const
 
Ip4Address ip_addr () const
 
bool OnChange (PhysicalInterfaceData *data)
 
virtual void ObtainOsSpecificParams (const std::string &name, Agent *agent)
 
const BondChildIntfMapgetBondChildIntfMap () const
 
void setBondChildIntfMap (const BondChildIntfMap bondChildIntfMap)
 
- Public Member Functions inherited from Interface
 Interface (Type type, const boost::uuids::uuid &uuid, const std::string &name, VrfEntry *vrf, bool os_oper_state, const boost::uuids::uuid &logical_router_uuid)
 
virtual ~Interface ()
 
virtual void SetKey (const DBRequestKey *key)
 
virtual void Add ()
 
virtual void SendTrace (const AgentDBTable *table, Trace event) const
 
virtual void GetOsParams (Agent *agent)
 
void SetPciIndex (Agent *agent, size_t index)
 
bool IsLess (const DBEntry &rhs) const
 
uint32_t vrf_id () const
 
uint32_t GetRefCount () const
 
bool DBEntrySandesh (Sandesh *sresp, std::string &name) const
 
bool IsTunnelEnabled () const
 
Type type () const
 
const boost::uuids::uuidGetUuid () const
 
const std::string & name () const
 
VrfEntryvrf () const
 
bool ipv4_active () const
 
bool ipv6_active () const
 
bool is_hc_active () const
 
bool metadata_ip_active () const
 
bool metadata_l2_active () const
 
bool ip_active (Address::Family family) const
 
bool l2_active () const
 
const uint32_t id () const
 
bool dhcp_enabled () const
 
bool dhcp_enabled_v6 () const
 
bool dns_enabled () const
 
uint32_t label () const
 
uint32_t l2_label () const
 
bool IsL2LabelValid (uint32_t label) const
 
uint32_t os_index () const
 
const MacAddressmac () const
 
bool os_oper_state () const
 
bool admin_state () const
 
void set_test_oper_state (bool val)
 
void set_flow_key_nh (const NextHop *nh)
 
const NextHopflow_key_nh () const
 
Interface::Transport transport () const
 
bool IsUveActive () const
 
const AgentQosConfigqos_config () const
 
void UpdateOperStateOfSubIntf (const InterfaceTable *table)
 
bool NeedDefaultOsOperStateDisabled (Agent *agent) const
 
boost::optional
< InterfaceOsParams::IfGuid
os_guid () const
 
const boost::uuids::uuidlogical_router_uuid () const
 
void set_logical_router_uuid (const boost::uuids::uuid &logical_router_uuid)
 
InterfaceOsParams get_os_params ()
 
- Public Member Functions inherited from AgentOperDBEntry
 AgentOperDBEntry ()
 
virtual ~AgentOperDBEntry ()
 
IFMapNodeifmap_node () const
 
void SetIFMapNodeState (IFMapDependencyManager::IFMapNodePtr sref)
 
- Public Member Functions inherited from AgentDBEntry
 AgentDBEntry ()
 
virtual ~AgentDBEntry ()
 
void SetRefState () const
 
void ClearRefState () const
 
bool IsActive () const
 
DBStateGetAgentDBEntryState (int listener_id)
 
const DBStateGetAgentDBEntryState (int listener_id) const
 
virtual void AllocateResources (ResourceManager *resource_manager)
 
virtual void FreeResources (ResourceManager *resource_manager)
 
- Public Member Functions inherited from DBEntry
 DBEntry ()
 
virtual ~DBEntry ()
 
bool operator< (const DBEntry &rhs) const
 
- Public Member Functions inherited from DBEntryBase
 DBEntryBase ()
 
virtual ~DBEntryBase ()
 
virtual bool IsMoreSpecific (const std::string &match) const
 
virtual bool IsLessSpecific (const std::string &match) const
 
void SetState (DBTableBase *tbl_base, ListenerId listener, DBState *state)
 
void ClearState (DBTableBase *tbl_base, ListenerId listener)
 
DBStateGetState (DBTableBase *tbl_base, ListenerId listener) const
 
const DBStateGetState (const DBTableBase *tbl_base, ListenerId listener) const
 
bool is_state_empty (DBTablePartBase *tpart)
 
bool is_state_empty_unlocked (DBTablePartBase *tpart)
 
void Delete ()
 
void MarkDelete ()
 
void ClearDelete ()
 
bool IsDeleted () const
 
void set_onlist ()
 
void clear_onlist ()
 
bool is_onlist ()
 
void SetOnRemoveQ ()
 
bool IsOnRemoveQ ()
 
void ClearOnRemoveQ ()
 
void set_last_change_at (uint64_t time)
 
void set_last_change_at_to_now ()
 
const uint64_t last_change_at () const
 
const std::string last_change_at_str () const
 
void set_last_update_at (uint64_t time)
 
void set_last_update_at_to_now ()
 
const uint64_t last_update_at () const
 
DBTablePartBaseget_table_partition () const
 
void set_table_partition (DBTablePartBase *tpart)
 
DBTableBaseget_table () const
 
void Notify ()
 

Static Public Member Functions

static void CreateReq (InterfaceTable *table, const std::string &ifname, const std::string &vrf_name, SubType subtype, EncapType encap, bool no_arp, const boost::uuids::uuid &device_uuid, const Ip4Address &ip, Interface::Transport transport)
 
static void Create (InterfaceTable *table, const std::string &ifname, const std::string &vrf_name, SubType subtype, EncapType encap, bool no_arp, const boost::uuids::uuid &device_uuid, const Ip4Address &ip, Interface::Transport transport_)
 
static void DeleteReq (InterfaceTable *table, const std::string &ifname)
 
static void Delete (InterfaceTable *table, const std::string &ifname)
 

Private Member Functions

std::string GetPhysicalInterfaceName () const
 
 DISALLOW_COPY_AND_ASSIGN (PhysicalInterface)
 

Private Attributes

bool persistent_
 
SubType subtype_
 
EncapType encap_type_
 
bool no_arp_
 
PhysicalDeviceRef physical_device_
 
std::string display_name_
 
Ip4Address ip_
 
BondChildIntfMap bond_childIntf_map_
 

Friends

struct PhysicalInterfaceKey
 
struct PhysicalInterfaceOsOperStateData
 
class TestVnswIf
 

Additional Inherited Members

- Public Attributes inherited from DBEntryBase
boost::intrusive::list_member_hook chg_list_
 
- Static Public Attributes inherited from Interface
static const uint32_t kInvalidIndex = 0xFFFFFFFF
 
- Protected Member Functions inherited from Interface
void SetItfSandeshData (ItfSandeshData &data) const
 
- Protected Attributes inherited from Interface
Type type_
 
boost::uuids::uuid uuid_
 
VrfEntryRef vrf_
 
uint32_t label_
 
uint32_t l2_label_
 
bool ipv4_active_
 
bool ipv6_active_
 
bool is_hc_active_
 
bool metadata_ip_active_
 
bool metadata_l2_active_
 
bool l2_active_
 
size_t id_
 
bool dhcp_enabled_
 
bool dhcp_enabled_v6_
 
bool dns_enabled_
 
bool admin_state_
 
bool test_oper_state_
 
NextHopConstRef flow_key_nh_
 
Transport transport_
 
AgentQosConfigConstRef qos_config_
 
struct InterfaceOsParams os_params_
 
boost::uuids::uuid logical_router_uuid_
 

Detailed Description

Definition at line 16 of file physical_interface.h.

Member Typedef Documentation

typedef std::map<const std::string, Bond_ChildIntf> PhysicalInterface::BondChildIntfMap

Definition at line 36 of file physical_interface.h.

typedef BondChildIntfMap::const_iterator PhysicalInterface::BondChildIntfMapIterator

Definition at line 37 of file physical_interface.h.

Member Enumeration Documentation

Enumerator
ETHERNET 
RAW_IP 

Definition at line 25 of file physical_interface.h.

Enumerator
FABRIC 
VMWARE 
CONFIG 
INVALID 

Definition at line 18 of file physical_interface.h.

Constructor & Destructor Documentation

PhysicalInterface::PhysicalInterface ( const std::string &  name,
const boost::uuids::uuid logical_router_uuid 
)

Definition at line 28 of file physical_interface.cc.

PhysicalInterface::~PhysicalInterface ( )
virtual

Definition at line 35 of file physical_interface.cc.

Member Function Documentation

bool PhysicalInterface::CmpInterface ( const DBEntry rhs) const
virtual

Implements Interface.

Definition at line 46 of file physical_interface.cc.

Here is the call graph for this function:

void PhysicalInterface::Create ( InterfaceTable table,
const std::string &  ifname,
const std::string &  vrf_name,
SubType  subtype,
EncapType  encap,
bool  no_arp,
const boost::uuids::uuid device_uuid,
const Ip4Address ip,
Interface::Transport  transport_ 
)
static

Definition at line 347 of file physical_interface.cc.

Here is the call graph for this function:

void PhysicalInterface::CreateReq ( InterfaceTable table,
const std::string &  ifname,
const std::string &  vrf_name,
SubType  subtype,
EncapType  encap,
bool  no_arp,
const boost::uuids::uuid device_uuid,
const Ip4Address ip,
Interface::Transport  transport 
)
static

Definition at line 333 of file physical_interface.cc.

Here is the call graph for this function:

bool PhysicalInterface::Delete ( const DBRequest req)
virtual

Reimplemented from Interface.

Definition at line 111 of file physical_interface.cc.

Here is the call graph for this function:

static void PhysicalInterface::Delete ( InterfaceTable table,
const std::string &  ifname 
)
static
void PhysicalInterface::DeleteReq ( InterfaceTable table,
const std::string &  ifname 
)
static

Definition at line 362 of file physical_interface.cc.

Here is the call graph for this function:

PhysicalInterface::DISALLOW_COPY_AND_ASSIGN ( PhysicalInterface  )
private
const std::string& PhysicalInterface::display_name ( ) const
inline

Definition at line 54 of file physical_interface.h.

EncapType PhysicalInterface::encap_type ( ) const
inline

Definition at line 63 of file physical_interface.h.

const BondChildIntfMap& PhysicalInterface::getBondChildIntfMap ( ) const
inline

Definition at line 88 of file physical_interface.h.

DBEntryBase::KeyPtr PhysicalInterface::GetDBRequestKey ( ) const
virtual

Implements Interface.

Definition at line 51 of file physical_interface.cc.

Here is the call graph for this function:

std::string PhysicalInterface::GetPhysicalInterfaceName ( ) const
private

Definition at line 117 of file physical_interface.cc.

Here is the call graph for this function:

Ip4Address PhysicalInterface::ip_addr ( ) const
inline

Definition at line 65 of file physical_interface.h.

bool PhysicalInterface::no_arp ( ) const
inline

Definition at line 64 of file physical_interface.h.

void PhysicalInterface::ObtainOsSpecificParams ( const std::string &  name,
Agent agent 
)
virtual

Reimplemented from Interface.

Definition at line 55 of file interface_params.cc.

Here is the call graph for this function:

bool PhysicalInterface::OnChange ( const InterfaceTable table,
const PhysicalInterfaceData data 
)
virtual

Definition at line 56 of file physical_interface.cc.

Here is the call graph for this function:

bool PhysicalInterface::OnChange ( PhysicalInterfaceData data)
bool PhysicalInterface::persistent ( ) const
inline

Definition at line 62 of file physical_interface.h.

PhysicalDevice * PhysicalInterface::physical_device ( ) const

Definition at line 38 of file physical_interface.cc.

void PhysicalInterface::PostAdd ( )
virtual

Reimplemented from AgentDBEntry.

Definition at line 125 of file physical_interface.cc.

Here is the call graph for this function:

void PhysicalInterface::setBondChildIntfMap ( const BondChildIntfMap  bondChildIntfMap)
inline

Definition at line 91 of file physical_interface.h.

SubType PhysicalInterface::subtype ( ) const
inline

Definition at line 52 of file physical_interface.h.

string PhysicalInterface::ToString ( ) const
virtual

Implements DBEntryBase.

Definition at line 42 of file physical_interface.cc.

Here is the call graph for this function:

Friends And Related Function Documentation

friend struct PhysicalInterfaceKey
friend

Definition at line 84 of file physical_interface.h.

friend struct PhysicalInterfaceOsOperStateData
friend

Definition at line 85 of file physical_interface.h.

friend class TestVnswIf
friend

Definition at line 86 of file physical_interface.h.

Member Data Documentation

BondChildIntfMap PhysicalInterface::bond_childIntf_map_
private

Definition at line 106 of file physical_interface.h.

std::string PhysicalInterface::display_name_
private

Definition at line 103 of file physical_interface.h.

EncapType PhysicalInterface::encap_type_
private

Definition at line 100 of file physical_interface.h.

Ip4Address PhysicalInterface::ip_
private

Definition at line 104 of file physical_interface.h.

bool PhysicalInterface::no_arp_
private

Definition at line 101 of file physical_interface.h.

bool PhysicalInterface::persistent_
private

Definition at line 98 of file physical_interface.h.

PhysicalDeviceRef PhysicalInterface::physical_device_
private

Definition at line 102 of file physical_interface.h.

SubType PhysicalInterface::subtype_
private

Definition at line 99 of file physical_interface.h.


The documentation for this class was generated from the following files: