Extensions of Herglotz' Theorem