code: public static SiblingCounter create( final ChildReferences childRefs ) {
          assert childRefs != null;
          return new SiblingCounter() {
              @Override
              public int countSiblingsNamed( Name childName ) {
                  return childRefs.getChildCount(childName);
              }
          };
      }
docs: Creates a sibling counter that uses the supplied {@link ChildReferences}.
  
  @param childRefs the child references; may not be null
  @return the sibling counter; never null