本文整理汇总了Java中com.microsoft.band.BandClient类的典型用法代码示例。如果您正苦于以下问题:Java BandClient类的具体用法?Java BandClient怎么用?Java BandClient使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
BandClient类属于com.microsoft.band包,在下文中一共展示了BandClient类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerCaloriesEventListener(mCaloriesEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:CaloryBurn.java
示例2: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerUVEventListener(mUltravioletEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:UltraVioletRadiation.java
示例3: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerContactEventListener(mBandContactEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:18,代码来源:BandContact.java
示例4: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerDistanceEventListener(mDistanceEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:Distance.java
示例5: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerDistanceEventListener(mPaceEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:Pace.java
示例6: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerPedometerEventListener(mPedometerEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:StepCount.java
示例7: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerSkinTemperatureEventListener(mSkinTemperatureEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:SkinTemperature.java
示例8: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
handler.removeCallbacks(runnableStart);
LocalBroadcastManager.getInstance(context).unregisterReceiver(mMessageReceiver);
isRegistered=false;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterHeartRateEventListeners();
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:HeartRate.java
示例9: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerDistanceEventListener(mSpeedEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:Speed.java
示例10: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
handler.removeCallbacks(runnableStart);
isRegistered=false;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterRRIntervalEventListener(mRRIntervalEventListener);
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
LocalBroadcastManager.getInstance(context).unregisterReceiver(mMessageReceiver);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:17,代码来源:RRInterval.java
示例11: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack){
registerDataSource(context, platform);
this.callBack=callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().registerDistanceEventListener(mMotionTypeEventListener);
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:18,代码来源:MotionType.java
示例12: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterGsrEventListeners();
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:14,代码来源:GalvanicSkinResponse.java
示例13: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
if (!enabled) return;
unregisterDataSource(context);
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterCaloriesEventListeners();
} catch (Exception e) {
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:15,代码来源:CaloryBurn.java
示例14: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack) {
registerDataSource(context, platform);
this.callBack = callBack;
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
switch (frequency) {
case "8":
bandClient.getSensorManager().registerGyroscopeEventListener(mGyroscopeEventListener, SampleRate.MS128);
break;
case "31":
bandClient.getSensorManager().registerGyroscopeEventListener(mGyroscopeEventListener, SampleRate.MS32);
break;
case "62":
bandClient.getSensorManager().registerGyroscopeEventListener(mGyroscopeEventListener, SampleRate.MS16);
break;
default:
break;
}
} catch (BandException e) {
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:30,代码来源:Gyroscope.java
示例15: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterGyroscopeEventListeners();
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:14,代码来源:Gyroscope.java
示例16: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterUVEventListeners();
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:14,代码来源:UltraVioletRadiation.java
示例17: register
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void register(Context context, final BandClient bandClient, Platform platform, CallBack callBack) {
if (!registerDataSource(context, platform)) return;
this.callBack = callBack;
Log.d(TAG, "register: ACCELEROMETER freq=" + frequency);
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
switch (frequency) {
case "8":
bandClient.getSensorManager().registerAccelerometerEventListener(mAccelerometerEventListener, SampleRate.MS128);
break;
case "31":
bandClient.getSensorManager().registerAccelerometerEventListener(mAccelerometerEventListener, SampleRate.MS32);
break;
case "62":
bandClient.getSensorManager().registerAccelerometerEventListener(mAccelerometerEventListener, SampleRate.MS16);
break;
default:
break;
}
} catch (BandException e) {
Log.d(TAG," exception...............");
e.printStackTrace();
}
}
});
background.start();
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:31,代码来源:Accelerometer.java
示例18: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterAccelerometerEventListeners();
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:14,代码来源:Accelerometer.java
示例19: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterContactEventListeners();
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:14,代码来源:BandContact.java
示例20: unregister
import com.microsoft.band.BandClient; //导入依赖的package包/类
public void unregister(Context context, final BandClient bandClient) {
final Thread background = new Thread(new Runnable() {
@Override
public void run() {
try {
bandClient.getSensorManager().unregisterAltimeterEventListener(mAltimeterListener);
} catch (Exception e) {
}
}
});
background.start();
unregisterDataSource(context);
}
开发者ID:MD2Korg,项目名称:mCerebrum-MicrosoftBand,代码行数:14,代码来源:Altimeter.java
注:本文中的com.microsoft.band.BandClient类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论