/*---------------------------------------------------------------------------* Project: Horizon File: socket_Utils.h Copyright (C)2010 Nintendo Co., Ltd. All rights reserved. These coded instructions, statements, and computer programs contain proprietary information of Nintendo of America Inc. and/or Nintendo Company Ltd., and are protected by Federal copyright law. They may not be disclosed to third parties or copied or duplicated in any form, in whole or in part, without the prior written consent of Nintendo. $Rev: 26448 $ *---------------------------------------------------------------------------*/ #ifndef NN_SOCKET_SOCKET_UTILS_H_ #define NN_SOCKET_SOCKET_UTILS_H_ #include #include namespace nn { namespace socket { /*! @name ユーティリティ @{ */ /*! @brief デフォルトゲートウェイのアドレスを取得します。 @param[out] pGateway アドレスの出力先バッファを指定します。 @return 0 以上 成功 */ s32 GetDefaultGateway(u8* pGateway); /*! @brief 自ホストの IP アドレスとネットマスクを取得します。 @param[out] pHostAddress アドレスの出力先バッファを指定します。 @param[out] pNetmask ネットマスクの出力先バッファを指定します。 @return 0 以上 成功 */ s32 GetPrimaryAddress(u8* pHostAddress, u8* pNetmask); /*! @brief 名前解決に使用する DNS サーバのアドレスを取得します。 @param[out] pResolver1 プライマリ DNS サーバのアドレス出力先バッファを指定します。 @param[out] pResolver2 セカンダリ DNS サーバのアドレス出力先バッファを指定します。 @return 0 以上 成功 */ s32 GetResolver(u8* pResolver1, u8* pResolver2); /*! @brief MAC アドレスを取得します。 @param[out] pMacAddress MAC アドレスの出力先バッファを指定します。 @return 0 以上 成功 */ s32 GetMacAddress(u8 pMacAddress[ETH_ALEN]); #ifndef NN_SWITCH_DISABLE_DEBUG_PRINT /*! @brief ルーティングテーブルをコンソールに出力します。 @return 0 以上 成功 */ void DumpRoutingTable(void); #endif /*! @} */ } } #endif // ifndef NN_SOCKET_SOCKET_UTILS_H_