Android Implement AsymmetricGridView
<p>Hello i have some problem with implementation of AssymetricGridView it still crashing but i dont know what is wrong how to implement it correctly with my adapter there is error Link to AssymetricGridView library. Thank you</p>

<pre><code>Adapter must be an instance of AsymmetricGridViewAdapter
                                                                      at com.felipecsl.asymmetricgridview.library.widget.AsymmetricGridView.setAdapter(AsymmetricGridView.java:71)
                                                                      at com.gabriel.movies.fragment.MainFragment.render(MainFragment.java:140)
                                                                      at com.gabriel.movies.fragment.MainFragment$MyTask.onPostExecute(MainFragment.java:228)
                                                                      at com.gabriel.movies.fragment.MainFragment$MyTask.onPostExecute(MainFragment.java:161)
</code></pre>

<p>My code </p>

<pre><code>&lt;com.felipecsl.asymmetricgridview.library.widget.AsymmetricGridView xmlns:android="http://schemas.android.com/apk/res/android"
    android:id="@+id/gridView1"
    android:layout_width="match_parent"
    android:layout_height="match_parent" /&gt;

AsymmetricGridView gridview;
List&lt;ItemCategory&gt; list;
AdapterCategory adapter;

    gridview = (AsymmetricGridView) mRootView.findViewById(R.id.gridView1);
    gridview.setRequestedColumnWidth(Utils.dpToPx(getActivity(), 120));

    list = new ArrayList&lt;ItemCategory&gt;();

    adapter = new AdapterCategory(getActivity(), R.layout.fragment_worcipe_main_item, list);
    gridview.setAdapter(adapter);
</code></pre>

<p>and adapter code </p>

<pre><code>public class AdapterCategory extends ArrayAdapter&lt;ItemCategory&gt; {
    ItemCategory object;
    private Activity activity;
    private List&lt;ItemCategory&gt; item;
    private int row;



     public AdapterCategory(Activity act, int resource, List&lt;ItemCategory&gt; arrayList) {
            super(act, resource, arrayList);
            this.activity = act;
            this.row = resource;
            this.item = arrayList;
        }

        @Override
        public View getView(final int position, View convertView, ViewGroup parent) {
            View view = convertView;
            ViewHolder holder;

            if (view == null) {
                LayoutInflater inflater = (LayoutInflater) activity.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
                view = inflater.inflate(row, null);
                holder = new ViewHolder();
                view.setTag(holder);
            } else {
                holder = (ViewHolder) view.getTag();
            }

            if ((item == null) || ((position + 1) &gt; item.size()))
                return view;

            object = item.get(position);

            holder.title = (TextView) view.findViewById(R.id.category_title);
            holder.image = (ImageView) view.findViewById(R.id.category_image);

            holder.title.setText(object.getCategoryName());

            Picasso.with(getContext()).load(RecipeConfig.SERVER_URL + "/upload/" +
                    object.getCategoryImageurl()).placeholder(R.drawable.ic_thumbnail).into(holder.image);

            return view;
        }

        public class ViewHolder {
            public TextView title;
            public ImageView image;

        }
    }
</code></pre>