code: public static List<CSNodeWrapper> getAllNodes(final ContentSpecWrapper contentSpec) {
          final List<CSNodeWrapper> nodes = new LinkedList<CSNodeWrapper>();
          if (contentSpec.getChildren() != null) {
              final List<CSNodeWrapper> childrenNodes = contentSpec.getChildren().getItems();
              for (final CSNodeWrapper childNode : childrenNodes) {
                  nodes.add(childNode);
                  nodes.addAll(getAllChildrenNodes(childNode));
              }
          }
  
          return nodes;
      }
docs: Recursively find all of a Content Specs child nodes.
  
  @param contentSpec The content spec to get all the children nodes from.
  @return A list of children nodes that exist for the content spec.