The charging process mentioned above describes the so-called 'dumb batteries'. You have to save your data before the empty battery shuts off your notebook. Today's state-of-the-art notebook with its battery pack can give you a very precise status of the battery charge status. This is being achieved with the so-called 'smart batteries'. Notebook battery packs contain much more then just accumulators and a thermal sensor to detect the end of charging process.
Those batteries use a two-wire interface called System Management Bus (SMBus) that is based on the principle operations of I2C.
Using the I2C/SMBus the attached devices can provide vendor information, save its state, report errors, accept control parameter and return its status.
When AC power is supplied, the Smart Battery charger must charge the Smart Battery regardless if the notebook is running or not. The charge voltage and current as well as the temperature have to be controlled too. The Smart Battery charger gets a good portion of its information from the gas gauge board that is inside the battery pack. It contains a LMD (main counter and capacity reference / last measured discharge), a DCR (discharge count register) and a NAC (nominal available charge register). The discharge current is measured while compensating the temperature. All of this makes sure that the available battery charge can be used efficiently. That is to avoid that battery pack is under or overcharged. Before you get such a battery pack, it will run a learning cycle to be conditioned to its size and provide the maximum available power to the notebook.
This certainly explains why you should check for the notebook model before you go get a new battery pack.