Snowflake (Delphi version) is a distributed self-increasing ID algorithm that generates 5 million IDs in one second

Summary In distributed systems, there are scenarios where a globally unique ID is required. In order to prevent ID conflicts, a 36-bit UUID can be used, but it has some drawbacks. First, it is relatively long, and UUIDs are generally out of order. Sometimes we want to be able to use a simpler ID, and we want IDs to be generated in time order. ...

Posted by ezekiel on Mon, 06 Jan 2020 22:49:46 -0800

File migration to FileTable

Before reading this document, please refer to the document https://blog.csdn.net/download/article/details/24374609 Environment: alicloud ECS SQL Server 2017 + Delphi7 It seems that xcopy, robocopy and other commands can not be used to migrate files. If you have any interested friends, let me know. You can use T-SQL, but you need files on the se ...

Posted by Roman Totale on Tue, 17 Dec 2019 06:40:22 -0800

Restrict multiple logins of the same account and choose forced kicking

Software type: CS Development tool: Delphi Function: restrict multiple logins of the same account and choose to kick others forcibly. 1. Use the temporary table to determine whether the current account has been logged in. Here is a brief introduction to the temporary table method. When the software is successfully logged in for the first time, ...

Posted by phlow on Fri, 15 Nov 2019 11:43:50 -0800

Delphi parses and modifies the Json file based on superobject.pas (ISuperObject)

After a series of twists and turns, it is still convenient for delphi to read and modify json files; Find a delphi tripartite library ISuperObject on the network, add it to the project and reference it directly; Download address Several commonly used functions in ISuperObject: Function SO(const s: SOString = '{}'): ISuperObject; overload; ...

Posted by SmokyBarnable on Fri, 15 Nov 2019 09:09:41 -0800

App wechat payment

I. Basic Process of wechat payment Main interaction between merchant system and wechat payment system: Step 1: the user selects the goods in the merchant APP, submits the order and selects wechat payment. Step 2: the merchant receives the user payment form at the background and calls the unified order interface of wechat payment. See also ...

Posted by bfinucan on Mon, 04 Nov 2019 08:05:21 -0800

8-sentence code to realize message boxa of Delphi 10.3 inline hook under win10

First of all, I'd like to thank myy of Delphi's learning and communication group for debugging for 6 hours yesterday, which was finally completed. Let's record it so as not to let some fans detour. I can't understand the information of a certain degree. I think it's better to dig a hole and fill it up by myself.Two problems should be paid atten ...

Posted by jfs0479 on Fri, 01 Nov 2019 21:26:36 -0700

From Delphi to Go - List

The most basic list in Delphi is TList class and TList < T > generic class, as well as thread safe TThreadList class and TThreadList < T > generic class. The underlying implementation is array. Go uses the container/list package, and the internal implementation is a two-way linked list. Delphi TList In TList, there is a pointer. Whe ...

Posted by fredi_bieging on Wed, 30 Oct 2019 11:27:29 -0700

Java basic tutorial - Object class

Class Object Object class is the parent class of all Java class types (or ancestor class is more suitable) The first chapter of Thinking in Java is called "everything is Object". Everything is an object. toString() method: Self Description Any class inherits Object by default, so there are toString() methods: public class Test { ...

Posted by kmaid on Mon, 28 Oct 2019 12:06:21 -0700

Java basic tutorial - System class

Class System The java.lang.System class represents the running platform of the current Java program. |-It can do input and output, garbage collection. |-Time available; |-Environment variables can be obtained; |-Access to system information; |-You can get the original hashcode of the object. (for example, the String class rewrites the hashcode ...

Posted by Chrisww on Mon, 28 Oct 2019 09:35:05 -0700

Delphi - Developing Serial Debugging Assistant Using Third Party Control TMS and SPComm

Download and Installation of Third Party Control TMS and SPComm The box can be downloaded with search keywords. The TMS is a. dpk file and the SPComm.pas file. Installation method itself, not to repeat.   Interface Layout by Using TMS Controls Interface Preview:   Delphi connects serial port, sends and receives instructions through SPC ...

Posted by PHPist on Wed, 09 Oct 2019 22:17:40 -0700