title: Get data by position in custom adapter by onClickListener
body: <p>look to my custom adapter that extends BaseAdapter:</p>
  
  <pre><code>public class DrawerAdapter extends BaseAdapter{
  
      static class ViewHolder{
          TextView        cat_Title;
          TextView        cat_Count;
      }
  
      private Activity                            mActivity;
      private ArrayList&lt;HashMap&lt;String, String&gt;&gt;  mData;
      private static LayoutInflater               mInflater;
      private JsonArray Categories                = null;
      public JsonObject Cat_Items                 = null;
  
      private static String                       CATEGORY_NAME;
      private static String                       CATEGORY_CNT;
      private static String                       CATEGORY_ID;
  
      public DrawerAdapter(Activity a, ArrayList&lt;HashMap&lt;String, String&gt;&gt; d){
          mActivity   = a;
          mData       = d;
          mInflater   = (LayoutInflater) mActivity.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
      }
  
      @Override
      public int getCount() {
          return mData.size();
      }
  
      @Override
      public Object getItem(int position) {
          return position;
      }
  
      @Override
      public long getItemId(int position) {
          return position;
      }
  
      @Override
      public View getView(int position, View convertView, ViewGroup parent) {
  
          View dView              = convertView;
          ViewHolder holder       = null;
  
          HashMap&lt;String, String&gt; dCategorise = new HashMap&lt;String, String&gt;();
          dCategorise             = mData.get(position);
          CATEGORY_NAME           = dCategorise.get("CATEGORY_NAME");
          CATEGORY_CNT            = dCategorise.get("CATEGORY_CNT");
          CATEGORY_ID             = dCategorise.get("CATEGORY_ID");
  
  
          if (convertView == null){
              dView               = mInflater.inflate(R.layout.layout_drawer_list_row, null);
              holder              = new ViewHolder();
  
              holder.cat_Title    = (TextView) dView.findViewById(R.id.category_title);
              holder.cat_Count    = (TextView) dView.findViewById(R.id.category_counter);
  
              dView.setTag(holder);
  
          }else{
              holder = (ViewHolder) dView.getTag();
          }
  
  
          holder.cat_Title.setTag(position);
          holder.cat_Title.setTypeface(MyriadRegular);
          holder.cat_Title.setText(CATEGORY_NAME);
  
          holder.cat_Count.setTypeface(Yagut);
          holder.cat_Count.setText(CATEGORY_CNT);
  
  
          holder.cat_Title.setOnClickListener(new OnClickListener() {
  
              @Override
              public void onClick(View v) {
                  int pos         = (Integer) v.getTag();
                  String cat_ID   = mData.get(pos).get(CATEGORY_ID);
              }
          });
          return dView;
      }
  
  }
  </code></pre>
  
  <p>This is my custom adapter and I'm using of this in my navigation drawer. I want to get category id by clicking on category title and send that to the fragment and changes fragment data base on this.
  But it's return null for cat_ID</p>
  
  <p>Now my questions:
  1.Why it return null?
  2.Is it right way to getting category id for sending to fragment?</p>