自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

sonne,web开发工程师

我的github地址:https://github.com/SonnAdolf

  • 博客(13)
  • 资源 (1)
  • 收藏
  • 关注

原创 将图片(二进制文件)存储于数据库,论文件字节流与二进制字符串相互转换

开发中遇到存储图片文件于数据库这样的需求。我们知道文件本身就是一份二进制数据,不同类型的文件只是编码形式不同,对应的解读形式不同,无论txt文件、jpg文件亦或是mp4文件,本质上都是0和1组成的。而在C++中我们可以通过字节流来读写文件,也就是说我们可以把文件读入char数组中,也可以将char数组中的数据写入为文件。开发中需要将图片存在数据库中,每个文件几KB,想将之存在数据库表的varcha...

2018-05-16 16:37:00 1585

原创 mysql多对一、多对多查询实践

最近做的功能涉及这方面,算是练了一下。 首先多对一部分较简单。多的那一方表,多设置一个字段是少的那一方的id(主键)。具体查询时候关联查询即可。可设置外键进行级联操作。具体以后做到这个功能再更新。 多对多: 设备和用户多对多,一个用户可有多台设备,一个设备可供多个用户使用。 首先设备表 dev: 用户表 user: 然后创建中间表user_dev      其中user_id 对应user表id ...

2018-05-16 16:36:09 12033

原创 LoadLibrary方法加载运行DLL库

最近和另一家公司对接,要求用对方提供的测试程序测试我们做的DLL。接到对方的测试程序,发现和我们以前调用DLL的方式不太一样。但我稍微看了一会代码也看懂其意思了,一天搞定了。但其中也遇到些小困惑,记录一下。 下面是我实验写的小Demo:my_dll.h:#ifdef MY_DLL_EXPORTS#define MY_DLL_API __declspec(dllexport)#else#def...

2018-05-16 16:34:50 11688

原创 博客项目实现文章摘要

前提:       1.博客首先系统自然是基于文本编辑器的,例如本博客是采用fckeditor。而文本编辑器提交时的文本是HTML格式的,将这个HTML格式文本直接以页面一部分显示,便可以实现文章的格式。       2.文章摘要是,截取文章中前面一小部分,用于显示在首页文章列表。点击文章链接,才可以看到文章全部。       3.博客系统,数据库里存储的是文章路径,而文章内容是存储在

2016-11-11 21:46:02 1661

原创 solve the problem of 'java web project cannot display verification code'

my java code of the function:package com.util;import java.awt.Color;import java.awt.Font;import java.awt.Graphics2D;import java.awt.image.BufferedImage;import java.io.IOException;import j

2016-10-31 23:24:14 537

原创 install mysql on ubuntu

u just need to run three commands:  sudo apt-get install mysql-server  sudo apt-get install mysql-client       sudo apt-get install libmysqlclient-dev

2016-10-14 21:32:14 558

原创 My first makefile to compile multiple C files

I have three files to compile: main.c, func.c,  func.hThe steps:           1   main.c   to   main.o           2   func.c    to   func.o           3    link main.o func.o to main(file that can

2016-10-14 21:30:43 391

原创 How to use the function of assembly.

Here are some simple conceptions that I summarized:              1, %rsp    -----  top of the stack    2, %rbp    -----  base address              3, The stack of function is upside down      

2016-10-14 21:23:00 381

原创 Socket programing(make a chat software) summary 1:How to accsess LAN from WAN

First we should know some basic conceptions about network:         1.Every PC is supposed to have its own IP,So we can connent other's PC by WAN.That's just like a ID of netwrok world.    2.But if

2016-10-07 11:34:13 621

原创 Using assembly writing algorithm programs

This's my first version.The logic is simple, just the selection sort.I spent much time learning how to write AT&T assembly on 64-bit Linux.almost all books just talk about 32-bit assembly.Such as

2016-10-04 18:17:09 428

原创 Assembly Note

jeif equal then jmpjgif the second gt the first, then jmpjgeif the second ge the first, then jmpjlif the second lt the first, then jmpjleif the second le the first, then jmp

2016-09-25 15:18:28 344

原创 linux shell program summary

from:Sep 23 2016 mathematical operation:floating number,bc calculator:we can also use bc in shell scripts: if - then - elsenumber comparison:              n1 -eq n2        

2016-09-25 15:17:17 425

原创 python:how does subclass call baseclass's __init__()

First, use baseclass's name to call __init__()I wrote code like this:  and we can use 'super' too.

2016-09-17 21:48:17 484

C#调用C++的dll的demo

展现带有char*、enum、unsigned long、unsigned long*类型参数的函数的调用

2021-03-29

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除