#ifndef CHROME_BROWSER_EXTENSIONS_API_SYSTEM_NETWORK_SYSTEM_NETWORK_API_H_
#define CHROME_BROWSER_EXTENSIONS_API_SYSTEM_NETWORK_SYSTEM_NETWORK_API_H_
#include "chrome/common/extensions/api/system_network.h"
#include "extensions/browser/extension_function.h"
#include "net/base/net_util.h"
namespace extensions {
namespace api {
class SystemNetworkGetNetworkInterfacesFunction
: public AsyncExtensionFunction {
public:
DECLARE_EXTENSION_FUNCTION("system.network.getNetworkInterfaces",
SYSTEM_NETWORK_GETNETWORKINTERFACES)
SystemNetworkGetNetworkInterfacesFunction();
protected:
virtual ~SystemNetworkGetNetworkInterfacesFunction();
virtual bool RunImpl() OVERRIDE;
private:
void GetListOnFileThread();
void HandleGetListError();
void SendResponseOnUIThread(const net::NetworkInterfaceList& interface_list);
};
}
}
#endif