package com.gs.apidemo;

import android.app.Application;

import com.gs.account.api.BaseAccountApi;
import com.gs.common.client.ApiClient;
import com.gs.device.api.DeviceApi;
import com.gs.phone.api.audio.AudioRouteApi;
import com.gs.phone.api.audio.CallToneApi;
import com.gs.phone.api.call.BaseCallApi;
import com.gs.phone.api.line.BaseLineApi;
import com.gs.phone.api.setting.CallSettingApi;
import com.gs.sms.api.SmsManagerApi;

public class DemoApplication extends Application {
    @Override
    public void onCreate() {
        super.onCreate();

        // init for ApiClient
        ApiClient.builder.setContext(getApplicationContext())
                .addApi(BaseAccountApi.API)
                .addApi(BaseCallApi.API)
                .addApi(BaseLineApi.API)
                .addApi(SmsManagerApi.API)
                .addApi(AudioRouteApi.API)
                .addApi(CallSettingApi.API)
                .addApi(DeviceApi.API)
                .addApi(CallToneApi.API)
                .build();
    }

    private int mSavedLineId = -1;
    public void setCurLineId(int lineId) {
        mSavedLineId = lineId;
    }
    public int getCurLineId() {
        return mSavedLineId;
    }
}
