@Override
    public void notifyStateChangedToLoaded(final Section.State previousState) {
        final Section.State state = section.getState();

        if (state == previousState) {
            throw new IllegalStateException("No state changed");
        }

        if (state != Section.State.LOADED) {
            if (previousState == Section.State.LOADED) {
                throw new IllegalStateException("Use notifyStateChangedFromLoaded");
            } else {
                throw new IllegalStateException("Use notifyNotLoadedStateChanged");
            }
        }

        final int contentItemsTotal = section.getContentItemsTotal();

        if (contentItemsTotal == 0) {
            notifyItemRemoved(0);
        } else {
            notifyItemChanged(0);

            if (contentItemsTotal > 1) {
                notifyItemRangeInserted(1, contentItemsTotal - 1);
            }
        }
    }
This class represents a {@link Section Section} in the {@link SectionedRecyclerViewAdapter SectionedRecyclerViewAdapter}.
<p>
It provides helper methods for:
<ul>
<li>identifying position of this {@link Section Section}'s items in the {@link SectionedRecyclerViewAdapter SectionedRecyclerViewAdapter}</li>
<li>identifying position of the {@link SectionedRecyclerViewAdapter SectionedRecyclerViewAdapter} in this {@link Section Section}</li>
<li>notifying {@link SectionedRecyclerViewAdapter SectionedRecyclerViewAdapter} of item changes in this Section</li>
</ul>
library/src/main/java/io/github/luizgrp/sectionedrecyclerviewadapter/SectionAdapter.java