Ryo Iizuka / libMiMic

Dependents:   MbedFileServer_1768MiniDK2 RedWireBridge IssueDebug_gcc MiMicRemoteMCU-for-Mbed ... more

Committer:
nyatla
Date:
Fri Sep 13 06:38:16 2013 +0000
Revision:
57:bc4330dfa62f
Parent:
41:2389bd6b6f74
update mimic core r329;

Who changed what in which revision?

UserRevisionLine numberNew contents of line
nyatla 37:fc4b4fd6a649 1 /*********************************************************************************
nyatla 37:fc4b4fd6a649 2 * PROJECT: MiMic
nyatla 37:fc4b4fd6a649 3 * --------------------------------------------------------------------------------
nyatla 37:fc4b4fd6a649 4 *
nyatla 37:fc4b4fd6a649 5 * This file is part of MiMic
nyatla 37:fc4b4fd6a649 6 * Copyright (C)2011 Ryo Iizuka
nyatla 37:fc4b4fd6a649 7 *
nyatla 37:fc4b4fd6a649 8 * MiMic is free software: you can redistribute it and/or modify
nyatla 37:fc4b4fd6a649 9 * it under the terms of the GNU Lesser General Public License as published
nyatla 37:fc4b4fd6a649 10 * by the Free Software Foundation, either version 3 of the License, or
nyatla 37:fc4b4fd6a649 11 * (at your option) any later version.
nyatla 37:fc4b4fd6a649 12 *
nyatla 37:fc4b4fd6a649 13 * This program is distributed in the hope that it will be useful,
nyatla 37:fc4b4fd6a649 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
nyatla 37:fc4b4fd6a649 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
nyatla 37:fc4b4fd6a649 16 * GNU General Public License for more details.
nyatla 37:fc4b4fd6a649 17 *
nyatla 37:fc4b4fd6a649 18 * You should have received a copy of the GNU Lesser General Public License
nyatla 37:fc4b4fd6a649 19 * along with this program. If not, see <http://www.gnu.org/licenses/>.
nyatla 37:fc4b4fd6a649 20 *
nyatla 37:fc4b4fd6a649 21 * For further information please contact.
nyatla 37:fc4b4fd6a649 22 * http://nyatla.jp/
nyatla 37:fc4b4fd6a649 23 * <airmail(at)ebony.plala.or.jp> or <nyatla(at)nyatla.jp>
nyatla 37:fc4b4fd6a649 24 *
nyatla 37:fc4b4fd6a649 25 *********************************************************************************/
nyatla 37:fc4b4fd6a649 26 #ifndef NYLPC_CBASESOCKET_H_
nyatla 37:fc4b4fd6a649 27 #define NYLPC_CBASESOCKET_H_
nyatla 37:fc4b4fd6a649 28 #ifdef __cplusplus
nyatla 37:fc4b4fd6a649 29 extern "C" {
nyatla 37:fc4b4fd6a649 30 #endif /* __cplusplus */
nyatla 37:fc4b4fd6a649 31
nyatla 37:fc4b4fd6a649 32 #include "NyLPC_stdlib.h"
nyatla 57:bc4330dfa62f 33 #include "NyLPC_cIPv4_typedef.h"
nyatla 37:fc4b4fd6a649 34
nyatla 37:fc4b4fd6a649 35 /**
nyatla 37:fc4b4fd6a649 36 * Base socket class
nyatla 37:fc4b4fd6a649 37 * cIPv4 classが管理するソケットオブジェクトのベースクラスです。
nyatla 37:fc4b4fd6a649 38 */
nyatla 37:fc4b4fd6a649 39 typedef struct NyLPC_TcBaseSocket NyLPC_TcBaseSocket_t;
nyatla 37:fc4b4fd6a649 40
nyatla 37:fc4b4fd6a649 41 #define NyLPC_TcBaseSocket_TYPEID_UDP_SOCK 1
nyatla 37:fc4b4fd6a649 42 #define NyLPC_TcBaseSocket_TYPEID_TCP_SOCK 2
nyatla 37:fc4b4fd6a649 43 #define NyLPC_TcBaseSocket_TYPEID_TCP_LISTENER 3
nyatla 37:fc4b4fd6a649 44
nyatla 37:fc4b4fd6a649 45 struct NyLPC_TcBaseSocket
nyatla 37:fc4b4fd6a649 46 {
nyatla 41:2389bd6b6f74 47 /**タイプID 継承クラスのinitializerで設定。 */
nyatla 57:bc4330dfa62f 48 NyLPC_TUInt8 _typeid;
nyatla 57:bc4330dfa62f 49 NyLPC_TUInt8 _padding8;
nyatla 57:bc4330dfa62f 50 NyLPC_TUInt16 _padding16;
nyatla 57:bc4330dfa62f 51 /** 所属してるIPv4コンローラ*/
nyatla 57:bc4330dfa62f 52 NyLPC_TcIPv4_t* _parent_ipv4;
nyatla 37:fc4b4fd6a649 53 };
nyatla 57:bc4330dfa62f 54 void NyLPC_cBaseSocket_initialize(NyLPC_TcBaseSocket_t* i_inst,NyLPC_TUInt8 i_typeid);
nyatla 37:fc4b4fd6a649 55 #define NyLPC_cBaseSocket_finalize(i_inst)
nyatla 37:fc4b4fd6a649 56
nyatla 37:fc4b4fd6a649 57
nyatla 37:fc4b4fd6a649 58
nyatla 37:fc4b4fd6a649 59 #ifdef __cplusplus
nyatla 37:fc4b4fd6a649 60 }
nyatla 37:fc4b4fd6a649 61 #endif /* __cplusplus */
nyatla 37:fc4b4fd6a649 62
nyatla 37:fc4b4fd6a649 63 #endif /* NYLPC_CBASESOCKET_H_ */