A.P. Møller-Maersk joined its peers in shrugging off falling revenue and a sharp decline in second-quarter volume,…