library/src/main/java/com/gunner/sectionrecyclerview/BaseSectionRecyclerViewAdapter.java
private void generatePositionMetaInfo() {
        List<PositionMeta> positionMetaList = new ArrayList<>();
        int groupCount = getGroupCount();
        for (int groupPos = 0; groupPos < groupCount; groupPos++) {
            // Group PositionMeta
            PositionMeta groupPositionMeta = new PositionMeta();
            groupPositionMeta.type = PositionMeta.GROUP;
            groupPositionMeta.groupPos = groupPos;
            groupPositionMeta.childPos = 0;
            positionMetaList.add(groupPositionMeta);

            int childCountInGroup = getChildrenCount(groupPos);
            for (int childPos = 0; childPos < childCountInGroup; childPos++) {
                // Child PositionMeta
                PositionMeta childPositionMeta = new PositionMeta();
                childPositionMeta.type = PositionMeta.CHILD;
                childPositionMeta.groupPos = groupPos;
                childPositionMeta.childPos = childPos;
                positionMetaList.add(childPositionMeta);
            }
        }
        this.positionMetaList = positionMetaList;
    }
/**
     * Generate the {@link PositionMeta} info of the {@link SectionRecyclerView}, should be called after each data set changed
     */
Generate the  PositionMeta info of the  SectionRecyclerView, should be called after each data set changed
Generate the PositionMeta info of the SectionRecyclerView should be called after each data set changed
private void generatePositionMetaInfo() {
        List<PositionMeta> positionMetaList = new ArrayList<>();
        int groupCount = getGroupCount();
        for (int groupPos = 0; groupPos < groupCount; groupPos++) {
            PositionMeta groupPositionMeta = new PositionMeta();
            groupPositionMeta.type = PositionMeta.GROUP;
            groupPositionMeta.groupPos = groupPos;
            groupPositionMeta.childPos = 0;
            positionMetaList.add(groupPositionMeta);
            int childCountInGroup = getChildrenCount(groupPos);
            for (int childPos = 0; childPos < childCountInGroup; childPos++) {
                PositionMeta childPositionMeta = new PositionMeta();
                childPositionMeta.type = PositionMeta.CHILD;
                childPositionMeta.groupPos = groupPos;
                childPositionMeta.childPos = childPos;
                positionMetaList.add(childPositionMeta);
            }
        }
        this.positionMetaList = positionMetaList;
    }
private void generatePositionMetaInfo ( ) { List < PositionMeta > positionMetaList = new ArrayList < > ( ) ; int groupCount = getGroupCount ( ) ; for ( int groupPos = 0 ; groupPos < groupCount ; groupPos ++ ) { PositionMeta groupPositionMeta = new PositionMeta ( ) ; groupPositionMeta . type = PositionMeta . GROUP ; groupPositionMeta . groupPos = groupPos ; groupPositionMeta . childPos = 0 ; positionMetaList . add ( groupPositionMeta ) ; int childCountInGroup = getChildrenCount ( groupPos ) ; for ( int childPos = 0 ; childPos < childCountInGroup ; childPos ++ ) { PositionMeta childPositionMeta = new PositionMeta ( ) ; childPositionMeta . type = PositionMeta . CHILD ; childPositionMeta . groupPos = groupPos ; childPositionMeta . childPos = childPos ; positionMetaList . add ( childPositionMeta ) ; } } this . positionMetaList = positionMetaList ; }
Generate the {@link PositionMeta} info of the {@link SectionRecyclerView}, should be called after each data set changed
Generate the { @link PositionMeta } info of the { @link SectionRecyclerView } should be called after each data set changed
// Group PositionMeta // Child PositionMeta