A police officer performing a function of the police service is performing a duty of a police officer even if the function could be performed by someone other than a police officer.
Example—An occupier of a place who may remove a trespasser from the place asks a police officer to remove the trespasser. The police officer, when removing the trespasser at the occupier’s request is performing a function of the police service.