
/**
 * This file is automatically generated by wheat-build.
 * Do not modify this file -- YOUR CHANGES WILL BE ERASED!
 */

package x7c1.linen.res.layout;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import x7c1.linen.R;
import x7c1.linen.glue.res.layout.SettingScheduleLayout;
import x7c1.wheat.ancient.resource.ViewHolderProvider;
import x7c1.wheat.ancient.resource.ViewHolderProviderFactory;

public class SettingScheduleLayoutProvider implements ViewHolderProvider<SettingScheduleLayout> {

    private final LayoutInflater inflater;

    public SettingScheduleLayoutProvider(Context context){
        this.inflater = LayoutInflater.from(context);
    }

    public SettingScheduleLayoutProvider(LayoutInflater inflater){
        this.inflater = inflater;
    }

    @Override
    public int layoutId(){
        return R.layout.setting_schedule_layout;
    }

    @Override
    public SettingScheduleLayout inflateOn(ViewGroup parent){
        return inflate(parent, false);
    }

    @Override
    public SettingScheduleLayout inflate(ViewGroup parent, boolean attachToRoot){
        View view = inflater.inflate(R.layout.setting_schedule_layout, parent, attachToRoot);
        return factory().createViewHolder(view);
    }

    public static ViewHolderProviderFactory<SettingScheduleLayout> factory(){
        return new ViewHolderProviderFactory<SettingScheduleLayout>() {
            @Override
            public ViewHolderProvider<SettingScheduleLayout> create(LayoutInflater inflater){
                return new SettingScheduleLayoutProvider(inflater);
            }
            @Override
            public ViewHolderProvider<SettingScheduleLayout> create(Context context){
                return new SettingScheduleLayoutProvider(context);
            }
            @Override
            public SettingScheduleLayout createViewHolder(View view){
                return new SettingScheduleLayout(
                    view,
                    (android.support.v7.widget.Toolbar) view.findViewById(R.id.setting_schedule_layout__toolbar),
                    (android.support.v7.widget.RecyclerView) view.findViewById(R.id.setting_schedule_layout__schedules)
                );
            }
        };
    }
}


/**
 * This file is automatically generated by wheat-build.
 * Do not modify this file -- YOUR CHANGES WILL BE ERASED!
 */

package x7c1.linen.res.layout;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.ViewGroup;
import android.view.View;
import android.support.v7.widget.Toolbar;
import android.support.v7.widget.RecyclerView;
import x7c1.wheat.ancient.resource.ViewHolderProvider;
import x7c1.wheat.ancient.resource.ViewHolderProviderFactory;
import x7c1.linen.R;
import x7c1.linen.glue.res.layout.SettingScheduleLayout;

public class SettingScheduleLayoutProvider implements ViewHolderProvider<SettingScheduleLayout> {

    private final LayoutInflater inflater;

    public SettingScheduleLayoutProvider(Context context){
        this.inflater = LayoutInflater.from(context);
    }

    public SettingScheduleLayoutProvider(LayoutInflater inflater){
        this.inflater = inflater;
    }

    @Override
    public int layoutId(){
        return R.layout.setting_schedule_layout;
    }

    @Override
    public SettingScheduleLayout inflateOn(ViewGroup parent){
        return inflate(parent, false);
    }

    @Override
    public SettingScheduleLayout inflate(ViewGroup parent, boolean attachToRoot){
        View view = inflater.inflate(R.layout.setting_schedule_layout, parent, attachToRoot);
        return factory().createViewHolder(view);
    }

    @Override
    public SettingScheduleLayout inflate(){
        return inflate(null, false);
    }

    public static ViewHolderProviderFactory<SettingScheduleLayout> factory(){
        return new ViewHolderProviderFactory<SettingScheduleLayout>() {
            @Override
            public ViewHolderProvider<SettingScheduleLayout> create(LayoutInflater inflater){
                return new SettingScheduleLayoutProvider(inflater);
            }
            @Override
            public ViewHolderProvider<SettingScheduleLayout> create(Context context){
                return new SettingScheduleLayoutProvider(context);
            }
            @Override
            public SettingScheduleLayout createViewHolder(View view){
                return new SettingScheduleLayout(
                    view,
                    (android.support.v7.widget.Toolbar) view.findViewById(R.id.setting_schedule_layout__toolbar),
                    (android.support.v7.widget.RecyclerView) view.findViewById(R.id.setting_schedule_layout__schedules)
                );
            }
        };
    }
}

add inflate() to SettingScheduleLayoutProvider