Forum Xamarin Xamarin.iOS

How to call Internal class methods through Interface

randiDiasrandiDias Member ✭✭


In my Xamarin.iOS binding project's, I have following interface defined in my ApiDefinition.cs

    [Protocol, Model]
    interface LSMAHandlerRegister

It has generated LSMAHandlerRegister.g.cs in my project/obj/Debug/ios/project. Yhis file contains followings

  • public interface ILSMAHandlerRegister : INativeObject, IDisposable,SightCallBinding.ILSMAHandler
  • internal sealed class LSMAHandlerRegisterWrapper : BaseWrapper, ILSMAHandlerRegister
  • public unsafe abstract partial class LSMAHandlerRegister : LSMAHandler, ILSMAHandlerRegister

I have added the generated DLL to my xamarin.ios project. Now I want to call RegisterWithURL method in above class. But the implementation of that method only available in internal wrapper class. How can I call to this method within my Xamarin.iOS project?


  • ColeXColeX Member, Xamarin Team Xamurai

    g.cs is not a real class , it is auto generated by Visual Studio and contain the declarations and initialisation for elements in your user interface during building time .

    We can't access the Internal method inside it .

Sign In or Register to comment.