Question: 1
To build a debug APK, you can open a command line and navigate to the root of your project directory. To initiate a debug build, invoke the assembleDebug task:
gradlew assembleDebug
This creates an APK named [module_name]-debug.apk in [project_name]/[module_name]/build/outputs/apk/
Select correct statements about generated file. (Choose all that apply.)
Question: 2
When using an EditTexts or editable TextViews, or other editable View. What attribute to use to provide a content label for that View?
Question: 3
In application theme style, flag windowDrawsSystemBarBackgrounds (- ) indicates:
Question: 4
Working with Custom View. To define custom attributes, we can add resources to our project. It is customary to put these resources into a file:
Question: 5
An example. In our ViewModelFactory (that implements ViewModelProvider.Factory) we have an instance of our Repository, named mRepository. Our ViewModel has such constructor:
public MyViewModel(MyRepository myRepository)...
Next, in our ViewModelFactory create ViewModel method (overriden) looks like this:
@NonNull
@Override
public T create(@NonNull Class modelClass) { try {
//MISSED RETURN VALUE HERE
} catch (InstantiationException | IllegalAccessException | NoSuchMethodException | InvocationTargetException e) {
throw new RuntimeException("Cannot create an instance of " + modelClass, e);
}
}
What should we write instead of ''//MISSED RETURN VALUE HERE''?