Home
last modified time | relevance | path

Searched refs:model (Results 1 – 25 of 208) sorted by relevance

123456789

/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/controls/management/
DFavoritesModelTest.kt63 private lateinit var model: FavoritesModel in <lambda>() variable in com.android.systemui.controls.management.FavoritesModelTest
70 model = FavoritesModel(customIconCache, TEST_COMPONENT, INITIAL_FAVORITES, callback) in <lambda>()
71 model.attachAdapter(adapter) in <lambda>()
72 dividerWrapper = model.elements.first { it is DividerWrapper } as DividerWrapper in <lambda>()
77 assertEquals(INITIAL_FAVORITES.size + 1, model.elements.toSet().size) in <lambda>()
79 model.elements.forEachIndexed { index, element -> in <lambda>()
87 assertEquals(model.favorites, model.elements.take(dividerIndex).map { in <lambda>()
97 assertEquals(expected, model.elements) in <lambda>()
102 assertEquals(INITIAL_FAVORITES, model.favorites) in <lambda>()
110 model.changeFavoriteStatus(id, false) in <lambda>()
[all …]
DAllModelTest.kt56 lateinit var model: AllModel in <lambda>() variable in com.android.systemui.controls.management.AllModelTest
91 model = AllModel(controls, favoritesList, EMPTY_STRING, controlsModelCallback) in <lambda>()
116 expected.zip(model.elements).forEachIndexed { index, it -> in <lambda>()
146 model.favorites.zip(expectedFavorites).forEach { in <lambda>()
154 model.changeFavoriteStatus("$idPrefix$indexToAdd", true) in <lambda>()
159 model.favorites.zip(expectedFavorites).forEach { in <lambda>()
170 model.changeFavoriteStatus(id, true) in <lambda>()
172 (model.elements.first { in <lambda>()
184 model.changeFavoriteStatus("$idPrefix$indexToAdd", true) in <lambda>()
188 assertEquals(expectedFavorites.size, model.favorites.size) in <lambda>()
[all …]
/frameworks/av/media/libaaudio/tests/
Dtest_clock_model.cpp41 model.setSampleRate(SAMPLE_RATE); in SetUp()
42 model.setFramesPerBurst(HW_FRAMES_PER_BURST); in SetUp()
56 model.start(startTimeNanos); in checkDriftingClock()
64 model.processTimestamp(startPositionFrames, markerTime); in checkDriftingClock()
65 ASSERT_EQ(startPositionFrames, model.convertTimeToPosition(markerTime)); in checkDriftingClock()
81 model.processTimestamp(alignedPosition, currentTimeNanos); in checkDriftingClock()
83 ASSERT_EQ(alignedPosition, model.convertTimeToPosition(currentTimeNanos)); in checkDriftingClock()
87 IsochronousClockModel model; member in ClockModelTestFixture
92 ASSERT_EQ(SAMPLE_RATE, model.getSampleRate()); in TEST_F()
93 ASSERT_EQ(HW_FRAMES_PER_BURST, model.getFramesPerBurst()); in TEST_F()
[all …]
/frameworks/base/tests/SoundTriggerTests/src/android/hardware/soundtrigger/stubhal/
DGenericSoundModelTest.java94 GenericSoundModel model = new_sound_model(); in testUpdateGenericSoundModel() local
97 soundTriggerService.updateSoundModel(model); in testUpdateGenericSoundModel()
98 loadedModelUuids.add(model.getUuid()); in testUpdateGenericSoundModel()
102 soundTriggerService.getSoundModel(new ParcelUuid(model.getUuid())); in testUpdateGenericSoundModel()
103 assertEquals(model, returnedModel); in testUpdateGenericSoundModel()
108 GenericSoundModel model = new_sound_model(); in testDeleteGenericSoundModel() local
111 soundTriggerService.updateSoundModel(model); in testDeleteGenericSoundModel()
112 loadedModelUuids.add(model.getUuid()); in testDeleteGenericSoundModel()
115 soundTriggerService.deleteSoundModel(new ParcelUuid(model.getUuid())); in testDeleteGenericSoundModel()
116 loadedModelUuids.remove(model.getUuid()); in testDeleteGenericSoundModel()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/keyguard/
DKeyguardListenQueue.kt40 fun add(model: KeyguardListenModel) { in <lambda>()
41 val queue = when (model) { in <lambda>()
42 is KeyguardFaceListenModel -> faceQueue.apply { add(model) } in <lambda>()
43 is KeyguardFingerprintListenModel -> fingerprintQueue.apply { add(model) } in <lambda>()
54 val stringify: (KeyguardListenModel) -> String = { model -> in <lambda>() method
55 " ${dateFormat.format(Date(model.timeMillis))} $model" in <lambda>()
59 for (model in faceQueue) { in <lambda>() method
60 writer.println(stringify(model)) in <lambda>()
63 for (model in fingerprintQueue) { in <lambda>() method
64 writer.println(stringify(model)) in <lambda>()
/frameworks/base/services/core/java/com/android/server/soundtrigger_middleware/
DValidationUtil.java54 static void validateGenericModel(@Nullable SoundModel model) { in validateGenericModel() argument
55 validateModel(model, SoundModelType.GENERIC); in validateGenericModel()
58 static void validateModel(@Nullable SoundModel model, int expectedType) { in validateModel() argument
59 Objects.requireNonNull(model); in validateModel()
60 if (model.type != expectedType) { in validateModel()
63 validateUuid(model.uuid); in validateModel()
64 validateUuid(model.vendorUuid); in validateModel()
65 if (model.dataSize > 0) { in validateModel()
66 Objects.requireNonNull(model.data); in validateModel()
70 static void validatePhraseModel(@Nullable PhraseSoundModel model) { in validatePhraseModel() argument
[all …]
DSoundTriggerHw2Enforcer.java224 int model = event.header.model; in recognitionCallback() local
226 if (!mModelStates.getOrDefault(model, false)) { in recognitionCallback()
227 Log.wtfStack(TAG, "Unexpected recognition event for model: " + model); in recognitionCallback()
233 mModelStates.replace(model, false); in recognitionCallback()
242 int model = event.common.header.model; in phraseRecognitionCallback() local
244 if (!mModelStates.getOrDefault(model, false)) { in phraseRecognitionCallback()
245 Log.wtfStack(TAG, "Unexpected recognition event for model: " + model); in phraseRecognitionCallback()
251 mModelStates.replace(model, false); in phraseRecognitionCallback()
DSoundTriggerModule.java276 public int loadModel(@NonNull SoundModel model) { in loadModel() argument
290 int result = loadedModel.load(model, audioSession); in loadModel()
307 public int loadPhraseModel(@NonNull PhraseSoundModel model) { in loadPhraseModel() argument
321 int result = loadedModel.load(model, audioSession); in loadPhraseModel()
415 for (Model model : mLoadedModels.values()) { in abortActiveRecognitions()
416 model.abortActiveRecognition(callbacks); in abortActiveRecognitions()
474 private int load(@NonNull SoundModel model, in load() argument
476 mModelType = model.type; in load()
478 ISoundTriggerHw.SoundModel hidlModel = ConversionUtil.aidl2hidlSoundModel(model); in load()
486 private int load(@NonNull PhraseSoundModel model, in load() argument
[all …]
/frameworks/base/core/java/android/view/
DDisplayAddress.java51 public static Physical fromPortAndModel(int port, Long model) { in fromPortAndModel() argument
52 return new Physical(port, model); in fromPortAndModel()
108 final long model = mPhysicalDisplayId >>> MODEL_SHIFT; in getModel() local
109 return model == UNKNOWN_MODEL ? null : model; in getModel()
123 final Long model = getModel(); in toString() local
124 if (model != null) { in toString()
125 builder.append(", model=0x").append(Long.toHexString(model)); in toString()
145 private Physical(int port, Long model) { in Physical() argument
150 | (model == null ? UNKNOWN_MODEL : (model << MODEL_SHIFT)); in Physical()
/frameworks/base/services/core/java/com/android/server/integrity/parser/
DRuleBinaryParser.java19 import static com.android.server.integrity.model.ComponentBitSize.ATOMIC_FORMULA_START;
20 import static com.android.server.integrity.model.ComponentBitSize.BYTE_BITS;
21 import static com.android.server.integrity.model.ComponentBitSize.COMPOUND_FORMULA_END;
22 import static com.android.server.integrity.model.ComponentBitSize.COMPOUND_FORMULA_START;
23 import static com.android.server.integrity.model.ComponentBitSize.CONNECTOR_BITS;
24 import static com.android.server.integrity.model.ComponentBitSize.EFFECT_BITS;
25 import static com.android.server.integrity.model.ComponentBitSize.FORMAT_VERSION_BITS;
26 import static com.android.server.integrity.model.ComponentBitSize.INSTALLER_ALLOWED_BY_MANIFEST_STA…
27 import static com.android.server.integrity.model.ComponentBitSize.IS_HASHED_BITS;
28 import static com.android.server.integrity.model.ComponentBitSize.KEY_BITS;
[all …]
DBinaryFileOperations.java19 import static com.android.server.integrity.model.ComponentBitSize.IS_HASHED_BITS;
20 import static com.android.server.integrity.model.ComponentBitSize.VALUE_SIZE_BITS;
24 import com.android.server.integrity.model.BitInputStream;
/frameworks/base/tools/processors/view_inspector/src/java/android/processor/view/inspector/
DPlatformInspectableProcessor.java34 import javax.lang.model.SourceVersion;
35 import javax.lang.model.element.Element;
36 import javax.lang.model.element.ElementKind;
37 import javax.lang.model.element.Modifier;
38 import javax.lang.model.element.TypeElement;
39 import javax.lang.model.util.ElementFilter;
77 for (InspectableClassModel model : modelMap.values()) { in process()
79 generator.generate(model); in process()
83 model.getClassName().toString(), in process()
117 final InspectableClassModel model = modelMap.computeIfAbsent( in processProperties() local
[all …]
DInspectionCompanionGenerator.java45 import javax.lang.model.element.Modifier;
115 public void generate(@NonNull InspectableClassModel model) throws IOException { in generate() argument
116 generateFile(model).writeTo(mFiler); in generate()
128 JavaFile generateFile(@NonNull InspectableClassModel model) { in generateFile() argument
130 .builder(model.getClassName().packageName(), generateTypeSpec(model)) in generateFile()
143 private TypeSpec generateTypeSpec(@NonNull InspectableClassModel model) { in generateTypeSpec() argument
144 final List<Property> properties = new ArrayList<>(model.getAllProperties()); in generateTypeSpec()
150 .classBuilder(generateClassName(model)) in generateTypeSpec()
153 INSPECTION_COMPANION, model.getClassName())) in generateTypeSpec()
154 .addJavadoc("Inspection companion for {@link $T}.\n\n", model.getClassName()) in generateTypeSpec()
[all …]
DAnnotationUtils.java29 import javax.lang.model.element.AnnotationMirror;
30 import javax.lang.model.element.AnnotationValue;
31 import javax.lang.model.element.Element;
32 import javax.lang.model.element.ExecutableElement;
33 import javax.lang.model.element.TypeElement;
34 import javax.lang.model.type.TypeMirror;
35 import javax.lang.model.util.Elements;
36 import javax.lang.model.util.Types;
DInspectablePropertyProcessor.java33 import javax.lang.model.element.AnnotationMirror;
34 import javax.lang.model.element.AnnotationValue;
35 import javax.lang.model.element.Element;
36 import javax.lang.model.element.ElementKind;
37 import javax.lang.model.element.ExecutableElement;
38 import javax.lang.model.element.Modifier;
39 import javax.lang.model.element.TypeElement;
40 import javax.lang.model.type.NoType;
41 import javax.lang.model.type.TypeKind;
42 import javax.lang.model.type.TypeMirror;
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/people/
DPeopleHubViewController.kt90 for ((adapter, model) in viewBoundary.personViewAdapters.zip(padded)) { in bindView() constant
91 adapter.onDataChanged(model) in bindView()
109 var model: PeopleHubModel? = null in registerListener() variable
113 model?.let { model -> in registerListener() method
114 val factory = PeopleHubViewModelFactoryImpl(model, activityStarter) in registerListener()
120 model = data in registerListener()
139 private val model: PeopleHubModel, constant in com.android.systemui.statusbar.notification.people.PeopleHubViewModelFactoryImpl
144 val personViewModels = model.people.asSequence().map { personModel -> in createWithAssociatedClickView()
150 return PeopleHubViewModel(personViewModels, model.people.isNotEmpty()) in createWithAssociatedClickView()
/frameworks/base/services/core/java/com/android/server/integrity/serializer/
DRuleBinarySerializer.java19 import static com.android.server.integrity.model.ComponentBitSize.ATOMIC_FORMULA_START;
20 import static com.android.server.integrity.model.ComponentBitSize.COMPOUND_FORMULA_END;
21 import static com.android.server.integrity.model.ComponentBitSize.COMPOUND_FORMULA_START;
22 import static com.android.server.integrity.model.ComponentBitSize.CONNECTOR_BITS;
23 import static com.android.server.integrity.model.ComponentBitSize.DEFAULT_FORMAT_VERSION;
24 import static com.android.server.integrity.model.ComponentBitSize.EFFECT_BITS;
25 import static com.android.server.integrity.model.ComponentBitSize.FORMAT_VERSION_BITS;
26 import static com.android.server.integrity.model.ComponentBitSize.INSTALLER_ALLOWED_BY_MANIFEST_STA…
27 import static com.android.server.integrity.model.ComponentBitSize.KEY_BITS;
28 import static com.android.server.integrity.model.ComponentBitSize.OPERATOR_BITS;
[all …]
/frameworks/native/services/surfaceflinger/tests/unittests/
DVSyncPredictorTest.cpp63 auto model = tracker.getVSyncPredictionModel(); in TEST_F() local
65 EXPECT_THAT(model.slope, Eq(mPeriod)); in TEST_F()
66 EXPECT_THAT(model.intercept, Eq(0)); in TEST_F()
70 model = tracker.getVSyncPredictionModel(); in TEST_F()
71 EXPECT_THAT(model.slope, Eq(changedPeriod)); in TEST_F()
72 EXPECT_THAT(model.intercept, Eq(0)); in TEST_F()
268 auto model = tracker.getVSyncPredictionModel(); in TEST_F() local
269 EXPECT_THAT(model.slope, IsCloseTo(fastPeriod, mMaxRoundingError)); in TEST_F()
270 EXPECT_THAT(model.intercept, IsCloseTo(0, mMaxRoundingError)); in TEST_F()
276 model = tracker.getVSyncPredictionModel(); in TEST_F()
[all …]
/frameworks/base/tests/SoundTriggerTestApp/src/com/android/test/soundtrigger/
DSoundTriggerUtil.java73 SoundTriggerManager.Model model = null; in getSoundModel() local
74 model = mSoundTriggerManager.getModel(modelId); in getSoundModel()
76 if (model == null) { in getSoundModel()
80 return model; in getSoundModel()
/frameworks/base/services/voiceinteraction/java/com/android/server/soundtrigger/
DSoundTriggerHelper.java256 ModelData model = getKeyphraseModelDataLocked(keyphraseId); in startKeyphraseRecognition() local
257 if (model != null && !model.isKeyphraseModel()) { in startKeyphraseRecognition()
263 if (model != null && !model.getModelId().equals(soundModel.getUuid())) { in startKeyphraseRecognition()
265 int status = cleanUpExistingKeyphraseModelLocked(model); in startKeyphraseRecognition()
270 model = null; in startKeyphraseRecognition()
275 if (model == null) { in startKeyphraseRecognition()
276 model = createKeyphraseModelDataLocked(soundModel.getUuid(), keyphraseId); in startKeyphraseRecognition()
279 return startRecognition(soundModel, model, callback, recognitionConfig, in startKeyphraseRecognition()
823 ModelData model = getModelDataForLocked(event.soundModelHandle); in onGenericRecognitionSuccessLocked() local
824 if (model == null || !model.isGenericModel()) { in onGenericRecognitionSuccessLocked()
[all …]
/frameworks/base/core/java/android/hardware/usb/
DUsbAccessory.java81 public UsbAccessory(@NonNull String manufacturer, @NonNull String model, in UsbAccessory() argument
85 mModel = Objects.requireNonNull(model); in UsbAccessory()
106 public UsbAccessory(@NonNull String manufacturer, @NonNull String model, in UsbAccessory() argument
109 this(manufacturer, model, description, version, uri, new IUsbSerialReader.Stub() { in UsbAccessory()
224 String model = in.readString();
231 return new UsbAccessory(manufacturer, model, description, version, uri,
DAccessoryFilter.java48 public AccessoryFilter(String manufacturer, String model, String version) { in AccessoryFilter() argument
50 mModel = model; in AccessoryFilter()
69 String model = null; in read() local
80 model = value; in read()
85 return new AccessoryFilter(manufacturer, model, version); in read()
/frameworks/base/packages/SystemUI/src/com/android/systemui/controls/management/
DControlAdapter.kt67 private var model: ControlsModel? = null in <lambda>() variable in com.android.systemui.controls.management.ControlAdapter
87 model?.moveHelper // Indicates that position information is needed in <lambda>()
89 model?.changeFavoriteStatus(id, favorite) in <lambda>()
103 fun changeModel(model: ControlsModel) { in <lambda>()
104 this.model = model in <lambda>()
108 override fun getItemCount() = model?.elements?.size ?: 0 in <lambda>()
111 model?.let { in <lambda>()
120 model?.let { in <lambda>()
130 model?.let { in <lambda>()
DControlsEditingActivity.kt61 private lateinit var model: FavoritesModel variable in com.android.systemui.controls.management.ControlsEditingActivity
160 StructureInfo(component, structure, model.favorites)) in saveFavorites()
179 model = FavoritesModel(customIconCache, component, controls, favoritesModelCallback) in setUpList()
217 adapter.changeModel(model) in setUpList()
218 model.attachAdapter(adapter) in setUpList()
219 ItemTouchHelper(model.itemTouchHelperCallback).attachToRecyclerView(recyclerView) in setUpList()
/frameworks/base/tests/VoiceEnrollment/src/com/android/test/voiceenrollment/
DEnrollmentUtil.java121 KeyphraseSoundModel model = null; in getSoundModel() local
123 model = mModelManagementService.getKeyphraseSoundModel(keyphraseId, bcp47Locale); in getSoundModel()
128 if (model == null) { in getSoundModel()
132 return model; in getSoundModel()

123456789