Add an internal function to get the native XPC type and returns a Swift class that matches the type.
This helps with checking the types using the `as?` or `is` syntax.