2016-04-28 9 views
0

IndoorAtlas用のバインディングライブラリを作成しました。フロアプランの読み込みを除いてアプリの作成に成功しました。私は、抽象メソッドfetchFloorPlanWithIdを使って、特に生成されたC#クラスに問題があります。 SDKのドキュメントには、次のように記述されています。abstract IATask<IAFloorPlan> fetchFloorPlanWithId(String floorPlanId)Xamarinバインディングライブラリの消去タイプ

ただし、生成されるC#メソッドは public abstract IATask FetchFloorPlanWithId(string p0)です。

は私が (IATask<IAFloorPlan>) mResourceManager.FetchFloorPlanWithId(id)としてそれをキャストしてみましたが、私は、無効なキャストエラー

私はこの問題を解決するには、正しい方向に私を指して助けを必要とする取得しています。以下

を解決IAResourceManager

[Register("com/indooratlas/android/sdk/resources/IAResourceManager", DoNotGenerateAcw = true)] 
public abstract class IAResourceManager : Java.Lang.Object 
{ 
    [Register(".ctor", "()V", "")] 
    public IAResourceManager(); 
    protected IAResourceManager(IntPtr javaReference, JniHandleOwnership transfer); 

    protected override IntPtr ThresholdClass { get; } 
    protected override Type ThresholdType { get; } 

    [Register("create", "(Landroid/content/Context;)Lcom/indooratlas/android/sdk/resources/IAResourceManager;", "")] 
    public static IAResourceManager Create(Context p0); 
    [Register("create", "(Landroid/content/Context;Landroid/os/Bundle;)Lcom/indooratlas/android/sdk/resources/IAResourceManager;", "")] 
    public static IAResourceManager Create(Context p0, Bundle p1); 
    [Register("fetchFloorPlanWithId", "(Ljava/lang/String;)Lcom/indooratlas/android/sdk/resources/IATask;", "GetFetchFloorPlanWithId_Ljava_lang_String_Handler")] 
    public abstract IATask FetchFloorPlanWithId(string p0); 
} 

答えて

0

ための生成されたC#クラスです。私はバインディングライブラリプロジェクトで生成されたC#クラスとインターフェイスを直接編集して解決しました

関連する問題