Use reflection to support multiple versions