本文整理汇总了Java中com.smartdevicelink.proxy.LockScreenManager.getLockObj方法的典型用法代码示例。如果您正苦于以下问题:Java LockScreenManager.getLockObj方法的具体用法?Java LockScreenManager.getLockObj怎么用?Java LockScreenManager.getLockObj使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.smartdevicelink.proxy.LockScreenManager
的用法示例。
在下文中一共展示了LockScreenManager.getLockObj方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: testLockScreenStatusDriverDistNull
import com.smartdevicelink.proxy.LockScreenManager; //导入方法依赖的package包/类
/**
* Test the invalid settings of lock screen status.
*/
public void testLockScreenStatusDriverDistNull(){
LockScreenManager lockMan = new LockScreenManager();
OnLockScreenStatus result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_NONE);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_BACKGROUND);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_FULL);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.REQUIRED, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_LIMITED);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.REQUIRED, result.getShowLockScreen());
}
示例2: testLockScreenStatusDriverDistEnabled
import com.smartdevicelink.proxy.LockScreenManager; //导入方法依赖的package包/类
/**
* Test the enabled settings of lock screen status.
*/
public void testLockScreenStatusDriverDistEnabled(){
LockScreenManager lockMan = new LockScreenManager();
lockMan.setDriverDistStatus(true);
// HMI level is null
OnLockScreenStatus result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_NONE);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_BACKGROUND);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_FULL);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.REQUIRED, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_LIMITED);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.REQUIRED, result.getShowLockScreen());
}
示例3: testLockScreenStatusDriverDistDisabled
import com.smartdevicelink.proxy.LockScreenManager; //导入方法依赖的package包/类
/**
* Test the disabled settings of lock screen status.
*/
public void testLockScreenStatusDriverDistDisabled(){
LockScreenManager lockMan = new LockScreenManager();
lockMan.setDriverDistStatus(false);
OnLockScreenStatus result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_NONE);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_BACKGROUND);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_FULL);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OPTIONAL, result.getShowLockScreen());
lockMan.setHMILevel(HMILevel.HMI_LIMITED);
result = lockMan.getLockObj();
assertEquals(Test.MATCH, LockScreenStatus.OPTIONAL, result.getShowLockScreen());
}
示例4: testLockScreenStatusNull
import com.smartdevicelink.proxy.LockScreenManager; //导入方法依赖的package包/类
/**
* Test the lock screen status when no setter methods are called.
*/
public void testLockScreenStatusNull(){
LockScreenManager lockMan = new LockScreenManager();
OnLockScreenStatus result = lockMan.getLockObj();
assertNotNull(Test.NOT_NULL, result);
assertEquals(Test.MATCH, LockScreenStatus.OFF, result.getShowLockScreen());
}