2016-11-29 127 views
0

我试图将我的应用程序的部分分解为可重用模块。在模块中导入android.bluetooth.BluetoothDevice

现在,我的模组中的一个类正试图导入android.bluetooth.BluetoothDevice无法解析该符号。

这里是我的模块gradle这个脚本:

apply plugin: 'java' 

dependencies { 

    compile 'com.android.support:appcompat-v7:22.2.0' 
    compile files('libs/Android_Platform_Adapter.jar') 

    compile files('libs/wisepadapi-android-2.7.0.jar') 
    compile files('libs/emvswipeapi-android-2.12.3.jar') 
} 

这是第一个模块我工作的。我确定这很容易。谢谢!

回答

0

这里是不匹配。您正试图在java模块(apply plugin: 'java')内严格导入import android.bluetooth.BluetoothDevice

您应该创建android库模块。创建一个新的电话&平板电脑模块描述here

+0

那仍​​然是一个罐子? – prelag