Merge "Change Font.Builder#build return type from @Nullable to @NonNull"
This commit is contained in:
committed by
Android (Google) Code Review
commit
7c8b154141
@@ -15802,7 +15802,7 @@ package android.graphics.fonts {
|
||||
ctor public Font.Builder(@NonNull android.os.ParcelFileDescriptor, @IntRange(from=0) long, @IntRange(from=0xffffffff) long);
|
||||
ctor public Font.Builder(@NonNull android.content.res.AssetManager, @NonNull String);
|
||||
ctor public Font.Builder(@NonNull android.content.res.Resources, int);
|
||||
method @Nullable public android.graphics.fonts.Font build() throws java.io.IOException;
|
||||
method @NonNull public android.graphics.fonts.Font build() throws java.io.IOException;
|
||||
method @NonNull public android.graphics.fonts.Font.Builder setFontVariationSettings(@Nullable String);
|
||||
method @NonNull public android.graphics.fonts.Font.Builder setFontVariationSettings(@Nullable android.graphics.fonts.FontVariationAxis[]);
|
||||
method @NonNull public android.graphics.fonts.Font.Builder setSlant(int);
|
||||
|
||||
@@ -360,7 +360,7 @@ public final class Font {
|
||||
*
|
||||
* @return the Font object
|
||||
*/
|
||||
public @Nullable Font build() throws IOException {
|
||||
public @NonNull Font build() throws IOException {
|
||||
if (mException != null) {
|
||||
throw new IOException("Failed to read font contents", mException);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user