上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 61 下一页
摘要: 当一个客户端发出一个REGISTER请求,它可能包含一个过期参数用来表示这个注册的地址的有效期。(注册服务器(registrar)根据自己的策略选取实际的时间间隔来计算有效期)。 客户端设置有效期的方法有两种:一个是通过设置Expires头域,一个是通过设置“expires”contact头域的参数 阅读全文
posted @ 2023-04-17 10:14 opensmarty 阅读(407) 评论(0) 推荐(0) 编辑
摘要: Definition: The #define Directive You can use the #define directive to give a meaningful name to a constant in your program. The two forms of the synt 阅读全文
posted @ 2023-04-17 09:32 opensmarty 阅读(145) 评论(0) 推荐(0) 编辑
摘要: strdup函数简介 收藏 用法:#include <string.h> 功能:复制字符串s 说明:返回指向被复制的字符串的指针,所需空间由malloc()分配且可以由free()释放。 举例: // strdup.c #include <syslib.h> #include <string.h> 阅读全文
posted @ 2023-04-14 10:21 opensmarty 阅读(500) 评论(0) 推荐(0) 编辑
摘要: extern "C"的主要作用就是为了能够正确实现C++代码调用其他C语言代码。加上extern "C"后,会指示编译器这部分代码按C语言的进行编译,而不是C++的。由于C++支持函数重载,因此编译器编译函数的过程中会将函数的参数类型也加到编译后的代码中,而不仅仅是函数名;而C语言并不支持函数重载, 阅读全文
posted @ 2023-04-06 09:47 opensmarty 阅读(1262) 评论(0) 推荐(0) 编辑
摘要: char []定义的是一个字符数组,注意强调是数组。char * 定义的是一个字符串指针,注意强调是指针。char *s定义了一个char型的指针,它只知道所指向的内存单元,并不知道这个内存单元有多大,所以: 当char *s = “hello”;后,不能使用s[0]=‘a’;语句进行赋值。这是将提 阅读全文
posted @ 2023-04-06 09:38 opensmarty 阅读(323) 评论(0) 推荐(0) 编辑
摘要: 教程集为您提供谈谈一致性哈希算法及其 Golang 实现(含负载均衡算法概述)等资源,欢迎您收藏本站,我们将为您提供最新的谈谈一致性哈希算法及其 Golang 实现(含负载均衡算法概述)资源 文章目录 一、概述 二、负载均衡算法 2.1 概述 2.2 轮询算法 2.3 随机算法 2.4 随机轮询算法 阅读全文
posted @ 2023-03-29 14:08 opensmarty 阅读(246) 评论(0) 推荐(1) 编辑
摘要: G711:8000HZ,8位,20ms一包数据 ,50包每秒 源代码: // g711.c // #include <stdio.h> #include <stdlib.h> #include <string.h> #include <memory.h> #include <netdb.h> #in 阅读全文
posted @ 2023-03-29 10:48 opensmarty 阅读(261) 评论(0) 推荐(0) 编辑
摘要: 1$s // String%1$d // int //R.string.old:<string name="old">我今年%1$d岁了</string> String sAgeFormat = getResources().getString(R.string.old);String sFinal 阅读全文
posted @ 2023-03-28 09:53 opensmarty 阅读(68) 评论(0) 推荐(0) 编辑
摘要: 计算码率(bit rate) 音频: CD音质,一般2通道,原始音频数据1秒钟的数据量是44.1k(采样率)*16(位深度)*2(声道数)=1411.2kbits,可求得整个音频文件的大小=时长(300s)*码率(1411.2)/1024/8=51.67M。压缩成128kbps的MP3,1秒钟数据就 阅读全文
posted @ 2023-03-24 17:48 opensmarty 阅读(760) 评论(0) 推荐(0) 编辑
摘要: package main import ( "fmt" "github.com/chilts/sid" "github.com/kjk/betterguid" "github.com/oklog/ulid" "github.com/rs/xid" "github.com/satori/go.uuid 阅读全文
posted @ 2023-03-24 15:18 opensmarty 阅读(151) 评论(0) 推荐(0) 编辑
上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 61 下一页