calculates the position of an drawerItem. searching by it's identifier

@param identifier
@return
176253
public static int getPositionByIdentifier(DrawerBuilder drawer, long identifier) {
        if (identifier != -1) {
            for (int i = 0; i < drawer.getAdapter().getItemCount(); i++) {
                if (drawer.getAdapter().getItem(i).getIdentifier() == identifier) {
                    return i;
                }
            }
        }

        return -1;
    }
1196687
public long getChildItemId(View child) {
        if (mAdapter == null || !mAdapter.hasStableIds()) {
            return NO_ID;
        }
        final ViewHolder holder = getChildViewHolderInt(child);
        return holder != null ? holder.getItemId() : NO_ID;
    }
1247497
protected ItemState getLastItemState(String identifer)
   {
      List<ItemState> allStates = changesLog.getAllStates();
      for (int i = allStates.size() - 1; i >= 0; i--)
      {
         ItemState state = allStates.get(i);
         if (state.getData().getIdentifier().equals(identifer))
            return state;
      }
      return null;
   }
61556
@Nullable
    private Object getItem(int position) {
        if (mMap != null) {
            return new ArrayList<>(mMap.entrySet()).get(position).getValue();
        } else if (mJsonArray != null) {
            return mJsonArray.opt(position);
        }
        return null;
    }
762383
public void updateItem(long identifier) {
        if (mDrawer != null && mAdapter != null && mItemAdapter.getAdapterItems() != null && identifier != -1) {
            IDrawerItem drawerItem = DrawerUtils.getDrawerItem(getDrawerItems(), identifier);
            for (int i = 0; i < mItemAdapter.getAdapterItems().size(); i++) {
                if (mItemAdapter.getAdapterItems().get(i).getIdentifier() == drawerItem.getIdentifier()) {
                    IDrawerItem miniDrawerItem = generateMiniDrawerItem(drawerItem);
                    if (miniDrawerItem != null) {
                        mItemAdapter.set(i, miniDrawerItem);
                    }
                }
            }
        }
    }
156458
public DrawerView removeFixedItemById(long id) {
        for (DrawerItem item : mAdapterFixed.getItems()) {
            if (item.getId() == id) {
                mAdapterFixed.remove(item);
                updateFixedList();
                return this;
            }
        }
        return this;
    }
226463
public DrawerItem findFixedItemById(long id) {
        for (DrawerItem item : mAdapterFixed.getItems()) {
            if (item.getId() == id) {
                return item;
            }
        }
        return null;
    }
1014691
@Nullable
    public IAdapter<Item> getAdapter(int position) {
        //if we are out of range just return null
        if (position < 0 || position >= mGlobalSize) {
            return null;
        }
        if (mVerbose) Log.v(TAG, "getAdapter");
        //now get the adapter which is responsible for the given position
        return mAdapterSizes.valueAt(floorIndex(mAdapterSizes, position));
    }
82846
public long getCurrentSelection() {
        IDrawerItem drawerItem = mDrawerBuilder.getDrawerItem(getCurrentSelectedPosition());
        if (drawerItem != null) {
            return drawerItem.getIdentifier();
        }
        return -1;
    }
195374
public ItemImpl getItemByIdentifier(String identifier, boolean pool) throws RepositoryException
   {
      return getItemByIdentifier(identifier, pool, true);
   }
357862
protected long getItemId(final int index) {
        long id = -1;
        if (index < getDataCount() && index >= 0 && mAdapter != null) {
            id =  mAdapter.getItemId(index);
        }
        return id;
    }
43402
public static void fillStickyDrawerItemFooter(DrawerBuilder drawer, ViewGroup container, View.OnClickListener onClickListener) {
        //add all drawer items
        for (IDrawerItem drawerItem : drawer.mStickyDrawerItems) {
            View view = drawerItem.generateView(container.getContext(), container);
            view.setTag(drawerItem);

            if (drawerItem.isEnabled()) {
                //UIUtils.setBackground(view, UIUtils.getSelectableBackground(container.getContext(), selected_color, drawerItem.isSelectedBackgroundAnimated()));
                view.setOnClickListener(onClickListener);
            }

            container.addView(view);

            //for android API 17 --> Padding not applied via xml
            DrawerUIUtils.setDrawerVerticalPadding(view);
        }
        //and really. don't ask about this. it won't set the padding if i don't set the padding for the container
        container.setPadding(0, 0, 0, 0);
    }
851753
public final int parentItemPosition(int adapterPosition) {
        int itemCount = 0;
        for (int i = 0; i < parentItemCount(); i++) {
            itemCount += 1;

            if (isExpanded(i)) {
                int childCount = childItemCount(i);
                itemCount += childCount;
            }
            if (adapterPosition < itemCount) {
                return i;
            }
        }

        throw new IllegalStateException("The adapter position is not a parent type: " + adapterPosition);
    }
6811
public void addDrawer(JFXDrawer drawer) {
        if (drawer == null) {
            return;
        }

        if (drawer.getCachePolicy().equals(CachePolicy.IMAGE)) {
            throw new RuntimeException("Drawer is using unsupported cache strategy inside JFXDrawerStack");
        }

        if (drawers.isEmpty()) {
            if (content != null) {
                drawer.setContent(content);
            }
        } else {
            drawer.setContent(drawers.get(drawers.size() - 1));
        }

        drawers.add(drawer);
        getChildren().setAll(drawer);
        drawer.setPickOnBounds(false);

        // add listener to bring drawer to front on hold
        JFXNodeUtils.addPressAndHoldHandler(drawer.sidePane, Duration.millis(300), event -> {
            if (drawers.indexOf(drawer) < drawers.size() - 1) {
                drawer.bringToFront((param) -> {
                    updateDrawerPosition(drawer);
                    return param;
                });
            }
313838
public Cursor getItem(int position) {
        if (mDataValid && mCursor != null) {
            mCursor.moveToPosition(position);
            return mCursor;
        } else {
            return null;
        }
    }
641083
public static IccProfileCreator getIccProfile(int identifier) {
    IccProfileCreator icc = null;
    try {
      if (instance == null)
        getIccProfileCreators();
      if (creatorsMap.containsKey(identifier))
        icc = creatorsMap.get(identifier);
    } catch (ReadIccConfigIOException e) {

    }
    return icc;
  }
459040
public final int childItemPosition(int childAdapterPosition) {
        int itemCount = 0;

        int parentCount = parentItemCount();
        for (int i = 0; i < parentCount; i++) {
            itemCount += 1;

            if (isExpanded(i)) {
                int childCount = childItemCount(i);
                itemCount += childCount;

                if (childAdapterPosition < itemCount) {
                    return childCount - (itemCount - childAdapterPosition);
                }
            } else {
                // itemCount += 1;
            }
        }

        throw new IllegalStateException("The adapter position is invalid: " + childAdapterPosition);
    }