码迷,mamicode.com
首页 >  
搜索关键字:void    ( 62627个结果
java8新特性CompletableFuture
public class Main { public static void main(String[] args) throws Exception { // 两个CompletableFuture执行异步查询: CompletableFuture<String> cfQueryFromSina ...
分类:编程语言   时间:2021-04-21 12:05:09    阅读次数:0
UDP消息发送
UDP 发短信 : 不需要连接但是需要知道对方的地址 发送消息 //不需要连接服务器 public static void main(String[] args) throws Exception { //1.建立一个socket DatagramSocket datagramSocket = ne ...
分类:其他好文   时间:2021-04-21 11:50:41    阅读次数:0
c语言4-6 输出小于输入值的所有正偶数
输出小于输入值的所有正偶数。 1、while语句 #include <stdio.h> int main(void) { int i = 2, j; puts("please input an integer."); printf("j = "); scanf("%d", &j); while ( ...
分类:编程语言   时间:2021-04-20 15:40:50    阅读次数:0
[转][C#]自定义提示控件
实现了提示控件(picture1)随着鼠标而移动,但点击时仍会显示(是一个BUG) 需要绑定事件到 form、panel1、picture1、等控件 private void panel1_MouseMove(object sender, MouseEventArgs e) { //timer1.S ...
分类:Windows程序   时间:2021-04-20 15:36:30    阅读次数:0
SSH框架-DAO层搭建
SSH框架-DAO层搭建 1、工具类 1.1例如几个方法都会有相同功能的时候,需要定义一个公共接口类,也就是工具类。 package com.caicai.elec.dao; public interface ICommonDao<T> { public void save(T t); } 1.2 ...
分类:其他好文   时间:2021-04-20 15:34:56    阅读次数:0
位运算之bit_xor、bit_not、bit_and、bit_or
一、bit_xor 1、头文件 #include <functional> 2、模板 template <class T> struct bit_xor; template <class T = void> struct bit_xor; 3、返回两个参数按位XOR的结果(公共成员函数) 4、使用 ...
分类:其他好文   时间:2021-04-20 15:10:43    阅读次数:0
读者-写者问题
1 typedef int semaphore; 2 semaphore count_mutex = 1; 3 semaphore data_mutex = 1; 4 int count = 0; 5 6 void reader(){ 7 while(TRUE){ 8 down(&count_mut ...
分类:其他好文   时间:2021-04-20 15:08:36    阅读次数:0
CountDownLatch 和 CyclicBarrier
CountDownLatch 每次当线程调用countDownLatch.countDown()方法时,会对计数器减1,减到0,countDownLatch.await()放行 public class CountDownLatchTest { public static void main(Str ...
分类:其他好文   时间:2021-04-20 15:06:35    阅读次数:0
设计模式之代理模式
代理模式 代理模式分为静态代理和动态代理.下图为静态代理结构图: 静态代理示例代码: // 抽象主题接口 public interface Subject { void request(); } // 具体主题角色 public class RealSubject implements Subjec ...
分类:其他好文   时间:2021-04-20 15:00:18    阅读次数:0
(第二课)c++语句
#include <iostream> //预处理器编译指令#include int main(void) //函数头 { //函数体开始{ using namespace std; //编译指令 int apple; //声明整数变量 apple = 25; //赋值变量 cout << "我有" ...
分类:编程语言   时间:2021-04-20 14:29:02    阅读次数:0
62627条   上一页 1 ... 43 44 45 46 47 ... 6263 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!