Articles

  • MySQL Primer

    Introduction

    MySQL is an open-source relational database management system (RDBMS).

  • C++ Exception

    Table of Contents

    异常保证

    异常安全函数必须提供以下三个保证之一

    1. 基本承诺

      如果异常被抛出,程序内的任何事物仍然保持在有效状态下,即所有对象处于一种内部前后一致的状态。 然而程序的现实状态不可预料。 如:我们可以使得changeBackground一旦有异常被抛出,PrettyMenu对象可以继续拥有原背景图像,或是令它拥有某个缺省背景图像,但客户无法预期哪一种情况(除非调用某个成员函数)。 如果调用一个只提供基本承诺的函数,而真的出现异常,程序有可能处于任何状态——只要那个状态合法。

    2. 强烈保证

      如果异常被抛出,程序状态不改变。调用这样的函数需要有这样的认知:如果函数成功,就完全成功,如果函数失败,程序会回复到“调用函数之前”的状态。

    3. 不抛掷 (nothrow) 保证

      承诺不抛出异常,因为它们总是能够完成它们原先承诺的功能。作用于内置类型身上的所有操作都提供该保证。

    异常安全必须提供上述三个保证之一。如果他不这样做,它就不具备异常安全性。

    一般而言你应该会想提供可实施之最强保证。但是nothrow在实际中往往做不到,所以对大部分函数而言,抉择往往落在基本保证和强烈保证之间。

  • Libevent

    Introduction

    libevent is a software library that provides asynchronous event notification. The libevent API provides a mechanism to execute a callback function when a specific event occurs on a file descriptor or after a timeout has been reached. Furthermore, libevent also support callbacks due to signals or regular timeouts.

  • Moxile Support

    Help

    Moxile Help

    FAQ

    1. What are the supported math format?

      Moxile use MathJax for built-in math renderer, so all the math expression supported by MathJax should work with Moxile.

    2. How to custom specific element in the document?

      Markdown support embedded HTML element, so you could use style attribute of the HTML element to do that.

    For questions those not listed below, you may send mail to errpro@icloud.com for help.

    What’s New in Version 3.0.0

    New Features

    1. Redesign info panel to statistics panel
    2. Add optional statusbar support (View->show/hide statusbar)
    3. New designed QR Code generator
      1. and add some important functions like configure size and adjusting colors
      2. multiple correction levels select
      3. support save to local disk
      4. builtin share support
    4. New Designed Preferences UI
    5. Add theme compatible ability
      1. add import theme option
      2. import source support XCode themes now
    6. Add support link in the about panel and help menu

    Improvements

    1. editor syntax highlight performance improved by 46%
    2. render performance improved by 79%

    Bug Fixes

    1. cursor jump around sometimes
    2. some other bug fixes
  • Moxile Help

    Moxile, the missing Markdown editor designed for productivity. It comes with Live Preview. It offers full support for regular Markdown Syntax as well as Github flavored markdown extension.

  • CRC算法与实现

    摘要: 本文首先讨论了CRC的代数学算法,然后以常见的CRC-ITU为例,通过硬件电路的实现,引出了比特型算法,最后重点介绍了字节型快速查表算法,给出了相应的C语言实现。

  • C++ STL

    作为 C++ 标准不可缺少的一部分,STL 应该是渗透在 C++ 程序的角角落落里的。

    Table of Contents

  • Apache httpd

    Table of Contents

    Configuration

    配置文件目录

    [a2di@F8SG:~/Public]$ ls /etc/apache2/
    apache2.conf  envvars     magic           mods-enabled  sites-available
    conf.d        httpd.conf  mods-available  ports.conf    sites-enabled
    

    缺省的主目录

    /var/www/

  • C\C++ faux pas

    class Widget {...};	// 假设Widget有默认构造函数
    Widget w();		// 函数声明,而非变量定义
    

    这并没有声明一个叫做 w 的Widget,它声明了一个叫作 w 的没有参数且返回Widget的函数。学会识别这个失言 (faux pas) 是成为C++程序员的一个真正的通过仪式。

  • C++11

    This article describes the new features in the C++11 standards.