Open Lighting Architecture: ola::network::InterfaceBuilder Class Reference

| Open Lighting Architecture 0.10.9

Loading...
Searching...
No Matches
Public Member Functions | List of all members
ola::network::InterfaceBuilder Class Reference

## Detailed Description

An InterfaceBuilder, this can construct Interface objects

## Public Member Functions
| InterfaceBuilder ()
void | SetName (const std::string &name)
bool | SetAddress (const std::string &ip_address)
void | SetAddress (const IPV4Address &ip_address)
bool | SetBroadcast (const std::string &broadcast_address)
void | SetBroadcast (const IPV4Address &broadcast_address)
bool | SetSubnetMask (const std::string &mask)
void | SetSubnetMask (const IPV4Address &mask)
void | SetHardwareAddress (const MACAddress &mac_address)
void | SetLoopback (bool loopback)
void | SetIndex (int32_t index)
void | SetType (uint16_t type)
void | Reset ()
Interface | Construct ()

## Constructor & Destructor Documentation

## ◆ InterfaceBuilder()

ola::network::InterfaceBuilder::InterfaceBuilder | ( |  | ) |

Create a new interface builder

## Member Function Documentation

## ◆ Construct()

Interface ola::network::InterfaceBuilder::Construct | ( |  | ) |

Return a new interface object. Maybe in the future we should check that the broadcast address, ip address and netmask are consistent. We could even infer the broadcast_address if it isn't provided.

## ◆ Reset()

void ola::network::InterfaceBuilder::Reset | ( |  | ) |

Reset the builder object

## ◆ SetAddress()

bool ola::network::InterfaceBuilder::SetAddress | ( | const std::string & | ip_address | ) |

Set the address of the interface to build.

## ◆ SetBroadcast()

bool ola::network::InterfaceBuilder::SetBroadcast | ( | const std::string & | broadcast_address | ) |

Set the broadcast address of the interface to build.

## ◆ SetIndex()

void ola::network::InterfaceBuilder::SetIndex | ( | int32_t | index | ) |

Set the index.

## ◆ SetLoopback()

void ola::network::InterfaceBuilder::SetLoopback | ( | bool | loopback | ) |

Set the loopback flag.

## ◆ SetSubnetMask()

bool ola::network::InterfaceBuilder::SetSubnetMask | ( | const std::string & | mask | ) |

Set the subnet mask of the interface to build.

## ◆ SetType()

void ola::network::InterfaceBuilder::SetType | ( | uint16_t | type | ) |

Set the type.

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

- include/ola/network/Interface.h
- common/network/Interface.cpp