// Path: phial-overlay/src/main/java/com/mindcoders/phial/OverlayCallback.java
// public interface OverlayCallback {
// 
//     /**
//      * Called to close phial debug window
//      */
//     void finish();
// 
// 
//     /**
//      * Finds view in application view hierarchy
//      *
//      * @param id view id.
//      * @return view or null if view is missing
//      */
//     @Nullable
//     View findViewById(int id);
// }
// 
// Path: phial-overlay/src/main/java/com/mindcoders/phial/Page.java
// public final class Page {
// 
//     /**
//      * Factory that is used to create views when page is selected
//      *
//      * @param <T> view to display
//      */
//     public interface PageViewFactory<T extends View & PageView> {
// 
//         /**
//          * @param context         android application context
//          * @param overlayCallback interface for communication with Phial
//          * @return view to display
//          */
//         T createPageView(Context context, OverlayCallback overlayCallback);
// 
//     }
// 
//     private final String id;
//     private final int iconResourceId;
//     private final CharSequence title;
//     private final PageViewFactory pageViewFactory;
//     private final Set<TargetScreen> targetScreens;
// 
//     /**
//      * @param id              unique pageId
//      * @param iconResourceId  page icon
//      * @param title           page title
//      * @param pageViewFactory factory that will create view when page is selected
//      */
//     public Page(
//             String id,
//             int iconResourceId,
//             CharSequence title,
//             PageViewFactory pageViewFactory
//     ) {
//         this(id, iconResourceId, title, pageViewFactory, Collections.<TargetScreen>emptySet());
//     }
// 
//     /**
//      * @param id              unique pageId
//      * @param iconResourceId  page icon
//      * @param title           page title
//      * @param pageViewFactory factory that will create view when page is selected
//      * @param targetScreens   screens to present this page on. Page will be present on all screens if this is empty.
//      */
//     public Page(
//             String id,
//             int iconResourceId,
//             CharSequence title,
//             PageViewFactory pageViewFactory,
//             Set<TargetScreen> targetScreens
//     ) {
//         this.id = id;
//         this.iconResourceId = iconResourceId;
//         this.title = title;
//         this.pageViewFactory = pageViewFactory;
//         this.targetScreens = Collections.unmodifiableSet(targetScreens);
//     }
// 
//     public String getId() {
//         return id;
//     }
// 
//     public int getIconResourceId() {
//         return iconResourceId;
//     }
// 
//     public CharSequence getTitle() {
//         return title;
//     }
// 
//     public PageViewFactory getPageViewFactory() {
//         return pageViewFactory;
//     }
// 
//     public Set<TargetScreen> getTargetScreens() {
//         return targetScreens;
//     }
// 
// }


import android.content.Context;
import com.mindcoders.phial.OverlayCallback;
import com.mindcoders.phial.Page;
package com.mindcoders.phial.autofill;



/**
 * Created by rost on 11/4/17.
 */

class AutoFillPageFactory implements Page.PageViewFactory<FillView> {

    private final FillConfig config;

    AutoFillPageFactory(FillConfig config) {
        this.config = config;
    }

    @Override
// Path: phial-overlay/src/main/java/com/mindcoders/phial/OverlayCallback.java
// public interface OverlayCallback {
// 
//     /**
//      * Called to close phial debug window
//      */
//     void finish();
// 
// 
//     /**
//      * Finds view in application view hierarchy
//      *
//      * @param id view id.
//      * @return view or null if view is missing
//      */
//     @Nullable
//     View findViewById(int id);
// }
// 
// Path: phial-overlay/src/main/java/com/mindcoders/phial/Page.java
// public final class Page {
// 
//     /**
//      * Factory that is used to create views when page is selected
//      *
//      * @param <T> view to display
//      */
//     public interface PageViewFactory<T extends View & PageView> {
// 
//         /**
//          * @param context         android application context
//          * @param overlayCallback interface for communication with Phial
//          * @return view to display
//          */
//         T createPageView(Context context, OverlayCallback overlayCallback);
// 
//     }
// 
//     private final String id;
//     private final int iconResourceId;
//     private final CharSequence title;
//     private final PageViewFactory pageViewFactory;
//     private final Set<TargetScreen> targetScreens;
// 
//     /**
//      * @param id              unique pageId
//      * @param iconResourceId  page icon
//      * @param title           page title
//      * @param pageViewFactory factory that will create view when page is selected
//      */
//     public Page(
//             String id,
//             int iconResourceId,
//             CharSequence title,
//             PageViewFactory pageViewFactory
//     ) {
//         this(id, iconResourceId, title, pageViewFactory, Collections.<TargetScreen>emptySet());
//     }
// 
//     /**
//      * @param id              unique pageId
//      * @param iconResourceId  page icon
//      * @param title           page title
//      * @param pageViewFactory factory that will create view when page is selected
//      * @param targetScreens   screens to present this page on. Page will be present on all screens if this is empty.
//      */
//     public Page(
//             String id,
//             int iconResourceId,
//             CharSequence title,
//             PageViewFactory pageViewFactory,
//             Set<TargetScreen> targetScreens
//     ) {
//         this.id = id;
//         this.iconResourceId = iconResourceId;
//         this.title = title;
//         this.pageViewFactory = pageViewFactory;
//         this.targetScreens = Collections.unmodifiableSet(targetScreens);
//     }
// 
//     public String getId() {
//         return id;
//     }
// 
//     public int getIconResourceId() {
//         return iconResourceId;
//     }
// 
//     public CharSequence getTitle() {
//         return title;
//     }
// 
//     public PageViewFactory getPageViewFactory() {
//         return pageViewFactory;
//     }
// 
//     public Set<TargetScreen> getTargetScreens() {
//         return targetScreens;
//     }
// 
// }


// Path: phial-autofill/src/main/java/com/mindcoders/phial/autofill/AutoFillPageFactory.java
import android.content.Context;
import com.mindcoders.phial.OverlayCallback;
import com.mindcoders.phial.Page;

package com.mindcoders.phial.autofill;



/**
 * Created by rost on 11/4/17.
 */

class AutoFillPageFactory implements Page.PageViewFactory<FillView> {

    private final FillConfig config;

    AutoFillPageFactory(FillConfig config) {
        this.config = config;
    }

    @Override
    public FillView createPageView(Context context, OverlayCallback overlayCallback) {