Typescript Interface Function Multiple Representations