23 inline operator zfbool (
void)
const {
50 void _ZFP_addr(
ZF_IN void *addr);
51 void *_ZFP_addr(
void)
const;
53 _ZFP_ZFUdpAddrPrivate *d;
217 _ZFP_ZFUdpPrivate *d;
#define zffinal
dummy macro shows that a method or class is designed must not to be overrided
Definition ZFCoreTypeDef_ClassType.h:63
#define zfclassLikePOD
shows the class is not a POD type, but you may use it like a POD except memset it to 0
Definition ZFCoreTypeDef_ClassType.h:41
#define zfextend
dummy macro shows class inherit from another
Definition ZFCoreTypeDef_ClassType.h:53
#define zfoverride
dummy macro shows that method override parent's method
Definition ZFCoreTypeDef_ClassType.h:58
#define ZF_IN
dummy macro that shows the param used as required input
Definition ZFCoreTypeDef_ClassType.h:180
#define ZF_IN_OUT
dummy macro that shows the param used as required input and output
Definition ZFCoreTypeDef_ClassType.h:196
#define zfclassFwd
forward declaration of a class type
Definition ZFCoreTypeDef_ClassType.h:31
_ZFT_t_zfbool zfbool
bool type
Definition ZFCoreTypeDef_CoreType.h:103
_ZFT_t_zfindex zfindex
similar to size_t, used for index and size only
Definition ZFCoreTypeDef_CoreType.h:154
_zft_zftimet zftimet
time unit, ensured at least 64 bit, ensured signed
Definition ZFCoreTypeDef_CoreType.h:203
#define zfnull
same as NULL, defined for future use
Definition ZFCoreTypeDef_CoreType.h:88
_ZFT_t_zfuint zfuint
same as unsigned int, see zfindex
Definition ZFCoreTypeDef_CoreType.h:169
#define ZFOUTPUT_TYPE(T_Type, outputAction)
declare your custom type conversion to string, convenient for debug
Definition ZFCoreTypeDef_OtherType.h:221
zft_zfstring< zfchar > zfstring
see zft_zfstring
Definition ZFCoreTypeDef_StringType.h:15
#define ZFMP_OUT_OPT(ParamType, paramName, DefaultValue)
see ZFMP_IN
Definition ZFMethod.h:114
#define ZFMP_IN_OPT(ParamType, paramName, DefaultValue)
see ZFMP_IN
Definition ZFMethod.h:108
#define ZFMP_IN(ParamType, paramName)
macro to wrap param types for ZFMETHOD_INLINE_0 series
Definition ZFMethod.h:105
#define ZFMETHOD_DECLARE_0(ReturnType, MethodName)
see ZFMethod
Definition ZFMethodDeclare.h:693
#define ZFMETHOD_DECLARE_4(ReturnType, MethodName, ZFMP_0, ZFMP_1, ZFMP_2, ZFMP_3)
see ZFMethod
Definition ZFMethodDeclare.h:1397
#define ZFMETHOD_DECLARE_3(ReturnType, MethodName, ZFMP_0, ZFMP_1, ZFMP_2)
see ZFMethod
Definition ZFMethodDeclare.h:1206
#define ZFMETHOD_DECLARE_1(ReturnType, MethodName, ZFMP_0)
see ZFMethod
Definition ZFMethodDeclare.h:854
#define ZF_NAMESPACE_GLOBAL_BEGIN
begin namespace ZFFramework
Definition ZFNamespace.h:97
#define ZF_NAMESPACE_GLOBAL_END
end namespace ZFFramework
Definition ZFNamespace.h:98
global header for ZFNet module
#define ZFLIB_ZFNet
used to export symbols
Definition ZFNetDef.h:15
#define zfclass
same as class, shows that this class is a ZFObject type
Definition ZFObjectClassTypeFwd.h:38
#define ZFOBJECT_DECLARE(ChildClass, SuperClass,...)
necessary for every class inherit from ZFObject
Definition ZFObjectDeclare.h:126
#define ZFTYPEID_ACCESS_ONLY_REG(ZFLIB_, TypeName, Type,...)
see ZFTYPEID_DECLARE
Definition ZFTypeIdDeclare.h:205
#define ZFTYPEID_ACCESS_ONLY_DECLARE(ZFLIB_, TypeName, Type)
see ZFTYPEID_DECLARE
Definition ZFTypeIdDeclare.h:195
udp packet
Definition ZFUdp.h:16
zfbool valid(void) const
whether the addr is valid
zfstring objectInfo(void) const
return object info
Definition ZFUdp.h:43
zfstring remoteInfo(void) const
get remote info
void objectInfoT(zfstring &ret) const
see objectInfo
void clear(void)
clear the resolved addr
zfbool remoteInfoT(zfstring &remoteAddr) const
get remote info
virtual zfstring recv(ZFUdpAddr *addr=(zft_zfnull), zfuint *port=(zft_zfnull), zftimet timeout=(-1))
recv packet until timeout
virtual void objectOnInit(void)
override this to init your object
virtual zfbool open(zfuint port=(0))
open a socket ready for send or recv
virtual zfuint port()
current opened port, or 0 if not opened or opened with 0 port
virtual ZFUdpAddr addrResolve(const zfstring &host)
resolve host for send
virtual zfbool valid()
true if open successfully
virtual void objectInfoImpl(zfstring &ret)
see objectInfo
virtual zfbool send(const ZFUdpAddr &addr, zfuint port, const zfstring &data)
send packet
virtual void close()
close the socket, see open
virtual void objectOnDealloc(void)
override this to destroy your object