summaryrefslogtreecommitdiff
path: root/library/main/src/com/android/setupwizardlib/items/ItemInflater.java
diff options
context:
space:
mode:
authorXin Li <delphij@google.com>2019-07-01 20:59:51 +0000
committerXin Li <delphij@google.com>2019-07-01 20:59:51 +0000
commitaa06a98b9387bf7cda7948de3f3949e82c151856 (patch)
treed4d0f1ccfa3d6b82ef0a0be0a353328a3001714d /library/main/src/com/android/setupwizardlib/items/ItemInflater.java
parentf26a9e8e2e422b20c721e199961f11bc82dd250a (diff)
parent93dacd74efc365bc889773a7cca03adad1ded25d (diff)
downloadsetupwizard-aa06a98b9387bf7cda7948de3f3949e82c151856.tar.gz
DO NOT MERGE - Merge qt-dev-plus-aosp-without-vendor (5699924) into stage-aosp-mastertemp_140451723
Bug: 134405016 Change-Id: I5e74b54945db4e896b45312ec51d2a4facc01c55
Diffstat (limited to 'library/main/src/com/android/setupwizardlib/items/ItemInflater.java')
-rw-r--r--library/main/src/com/android/setupwizardlib/items/ItemInflater.java32
1 files changed, 15 insertions, 17 deletions
diff --git a/library/main/src/com/android/setupwizardlib/items/ItemInflater.java b/library/main/src/com/android/setupwizardlib/items/ItemInflater.java
index 618d785..26cdbbd 100644
--- a/library/main/src/com/android/setupwizardlib/items/ItemInflater.java
+++ b/library/main/src/com/android/setupwizardlib/items/ItemInflater.java
@@ -18,26 +18,24 @@ package com.android.setupwizardlib.items;
import android.content.Context;
-/**
- * Inflate {@link Item} hierarchies from XML files.
- */
+/** Inflate {@link Item} hierarchies from XML files. */
public class ItemInflater extends ReflectionInflater<ItemHierarchy> {
- public interface ItemParent {
- void addChild(ItemHierarchy child);
- }
+ public interface ItemParent {
+ void addChild(ItemHierarchy child);
+ }
- public ItemInflater(Context context) {
- super(context);
- setDefaultPackage(Item.class.getPackage().getName() + ".");
- }
+ public ItemInflater(Context context) {
+ super(context);
+ setDefaultPackage(Item.class.getPackage().getName() + ".");
+ }
- @Override
- protected void onAddChildItem(ItemHierarchy parent, ItemHierarchy child) {
- if (parent instanceof ItemParent) {
- ((ItemParent) parent).addChild(child);
- } else {
- throw new IllegalArgumentException("Cannot add child item to " + parent);
- }
+ @Override
+ protected void onAddChildItem(ItemHierarchy parent, ItemHierarchy child) {
+ if (parent instanceof ItemParent) {
+ ((ItemParent) parent).addChild(child);
+ } else {
+ throw new IllegalArgumentException("Cannot add child item to " + parent);
}
+ }
}