It does not prevent them from charging you, since the standard of proof or evidence for to initially charge someone is low. It may well prevent a conviction IF the testimony of the arresting officer is necessary to prove you committed the crime and they don't know who that is, unless there is sufficient other evidence (e.g. forensic evidence; testimony of other witnesses) available as to prove guilt beyond a reasonable doubt without the officer's testimony.