How can I clear the recyclerView list?
<p>(EDIT)</p>

<p>What's up. I've searched a lot about how to set clear the recyclerView, and I've found a bunch of solutions though. However none of them solve my problem.</p>

<p>Fragment class:</p>

<pre><code>public class Fase2Fragment extends Fragment{

    private List&lt;mAuxModel&gt; mAuxModel= new mAuxModel&lt;&gt;();
    private RecyclerView mRecyclerView;
    public static boolean isOpenFase2 = true;

    public void onCreate(Bundle savedInstanceState){...}

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        View fase2frag = inflater.inflate(R.layout.fragment_fase2, container, false);
        setHasOptionsMenu(false);

        mRecyclerView = (RecyclerView) fase2frag.findViewById(R.id.recyclerView);

        fab_open = AnimationUtils.loadAnimation(getActivity(), R.anim.fab_open);
        fab_close = AnimationUtils.loadAnimation(getActivity(), R.anim.fab_close);
        rotate_forward = AnimationUtils.loadAnimation(getActivity(), R.anim.rotate_forward);
        rotate_backward = AnimationUtils.loadAnimation(getActivity(), R.anim.rotate_backward);

        mRecyclerView.setHasFixedSize(true);

        final LinearLayoutManager linearLayoutManager = new LinearLayoutManager(getActivity());
        linearLayoutManager.setOrientation(LinearLayoutManager.VERTICAL);
        mRecyclerView.setLayoutManager(linearLayoutManager);

        mRecyclerView.addOnItemTouchListener(...);

        fab.setOnClickListener(...);

        return fase2frag;
    }
    public void removeItems() {
        mAuxModel.clear();
        mRecyclerView.getAdapter().notifyDataSetChanged();
    }
}
</code></pre>

<p>Adapter class:</p>

<p>public class AdpRecyclerView extends RecyclerView.Adapter{</p>

<pre><code>private dataBase DB;
private LayoutInflater mLayoutInflater;
private List&lt;mAuxModel&gt; mAuxModel;
private static final int ARRAY_A1 = 0;
private static final int ARRAY_A2 = 1;

public AdpRecyclerView (){}

public AdpRecyclerView (Context context, List&lt;mAuxModel&gt; mAuxModel) {
    DB = new dataBase(context);

    this.mAuxModel= mAuxModel;
    mLayoutInflater = (LayoutInflater) context.getSystemService(Context.
                                      LAYOUT_INFLATER_SERVICE);
}

@Override
public int getItemViewType(int position) {
    if (mAuxModel.get(position).getModel_tipoFase().
                                            equals("Att")) {
        return ARRAY_A1;
    } else {
        return ARRAY_A2;
    }
}

@Override
public RecyclerView.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
    LayoutInflater inflater = LayoutInflater.from(parent.getContext());

    MyViewHolderA2 mvhA2;
    MyViewHolderA1 mvhA1;

    switch (viewType) {
        case ARRAY_A1:
            View viewA1 = inflater.inflate(R.layout.
                                             item_a1, parent, false);
            mvhAt = new MyViewHolderA1(viewA1);
            return mvhA1;

        case ARRAY_A2:
            View viewA2 = inflater.inflate(R.layout.
                                             item_a2, parent, false);
            mvhAg = new MyViewHolderA2(viewA2);
            return mvhA2;
    }

    return null;
}

@Override
public void onBindViewHolder(RecyclerView.ViewHolder holder, int position) {

    switch (holder.getItemViewType()) {
        case ARRAY_A1:
            MyViewHolderA1 myViewHolderA1 = (MyViewHolderA1) holder;
            myViewHolderA1.bindA1(position);
            break;

        case ARRAY_A2:
            MyViewHolderA2 myViewHolderA2 = (MyViewHolderA2) holder;
            myViewHolderA2.bindA2(position);
            break;
    }

}

@Override
public int getItemCount() {
    return mAuxModel.size();
}

public class MyViewHolder() {...}
</code></pre>

<p>Log Error:</p>

<pre><code>E/AndroidRuntime: FATAL EXCEPTION: main
              Process: com.example.victorvicari.actionbarteste, PID: 2355
              java.lang.NullPointerException: Attempt to invoke virtual method 'android.support.v7.widget.RecyclerView$Adapter android.support.v7.widget.RecyclerView.getAdapter()' on a null object reference
</code></pre>