Production of identified and unidentified charged hadrons in Pb--Pb collisions at \sqrts_\rm NN~5.02~TeV