Client-Library uses a state machine to enforce a logical order of operations. It stores information about the last call that an application made and limits the calls that can follow to those that are legal. For example, an application must call ct_connect to connect to a server before it can call ct_send to send commands.