Iterates over all the ContentStreams of the Page.
540279
def each_content_stream
            contents = self.Contents

            return enum_for(__method__) do
                case contents
                when Array then contents.length
                when Stream then 1
                else
                    0
                end
            end unless block_given?

            case contents
            when Stream then yield(contents)
            when Array then contents.each { |stm| yield(stm.solve) }
            end
        end
162227
function readPages() {
        $params = $this->getObjectVal($this->xref['trailer'][1]['/Root']);
        $objref = null;
        foreach ($params[1][1] as $k=>$v) {
            if ($k == '/Pages') {
                $objref = $v;
                break;
            }
        }
        if ($objref == null || $objref[0] !== PDF_TYPE_OBJREF) {
            // Offset not found.
            return;
        }

        $dict = $this->getObjectVal($objref);
        if ($dict[0] == PDF_TYPE_OBJECT && $dict[1][0] == PDF_TYPE_DICTIONARY) {
            // Dict wrapped in an object
            $dict = $dict[1];
        }

        if ($dict[0] !== PDF_TYPE_DICTIONARY) {
            return;
        }

        $this->pages = array();
        if (isset($dict[1]['/Kids'])) {
            $v = $dict[1]['/Kids'];
            if ($v[0] == PDF_TYPE_ARRAY) {
                foreach ($v[1] as $ref) {
                    $page = $this->getObjectVal($ref);
                    $this->readPage($page);
                }
            }
        }

        $this->page_count = count($this->pages);
    }
822072
public InputStream getContents() {
        final byte[] copy;
        synchronized (this) {
            final int length = this.contents.length;
            copy = new byte[length];
            System.arraycopy(this.contents, 0, copy, 0, this.contents.length);
        }
        return new ByteArrayInputStream(copy);
    }
1012759
@Override
    public Set<Stream> getResultStreams() {
    	Set<Stream> streams = ImmutableSet.of(this.resultStream);
		return streams;
    }
282405
public I addPages(Collection<WebPage> webPages) {
        for (WebPage webPage : webPages) {
            addPage(webPage);
        }
        return getThis();
    }
444077
public List<Page> extractText(InputStream src) throws IOException {
        List<Page> pages = Lists.newArrayList();

        PdfReader reader = new PdfReader(src);
        RenderListener listener = new InternalListener();
        PdfContentStreamProcessor processor = new PdfContentStreamProcessor(listener);

        for (int i = 1; i <= reader.getNumberOfPages(); i++) {
            pages.add(currentPage = new Page());
            PdfDictionary pageDic = reader.getPageN(i);
            PdfDictionary resourcesDic = pageDic.getAsDict(PdfName.RESOURCES);
            processor.processContent(ContentByteUtils.getContentBytesForPage(reader, i), resourcesDic);
        }
        reader.close();

        return pages;
    }
1298973
@Override
  public Iterator<Reader> iterator() {
    Collection<Object> newCollection = new ArrayList<Object>();
    for (Object o : c) {
      if (o instanceof Reader) {
        String name = o.toString()+".tmp";
        File tmpFile;
        try {
          tmpFile = File.createTempFile(name,"");
        } catch (Exception e) {
          throw new RuntimeException(e.getMessage());
        }
        tmpFile.deleteOnExit();
        StringUtils.printToFile(tmpFile, IOUtils.slurpReader((Reader)o),
                                false, false, enc);
        newCollection.add(tmpFile);
      } else {
        newCollection.add(o);
      }
    }
    c = newCollection;
    return new ReaderIterator();
  }
805860
def iter_content(self, chunk_size=1024):
        """"""
        r = self._session.get(self.content, stream=True)
        return r.iter_content(chunk_size)
778136
def each_page_each_resource(args={})
      self.each_page(args) do |page|
        page.resources.each do |item|
          yield(item)
        end
      end
    end
642256
@XmlElementWrapper(name = "allpages")
  @XmlElement(name = "p", type = P.class)
  public List<P> getAllpages() {
    return allpages;
  }
362351
function() {
        var nodes = this.tree.content;
        for (var i = 0; i < nodes.length; i++) {
            if (nodes[i].type === "template") {
                this._processNodeContent(nodes[i].content,nodes[i]);
            }
        }
    }
487407
def all(self):
        

        if self._stream:
            return chain.from_iterable(self._get_streamed_response())

        return self._get_buffered_response()[0]
555894
public Iterator<Page> getSortedPages()
    {
        return new AbstractIterator<Page>()
        {
            private int currentPosition;
            private final PageBuilder pageBuilder = new PageBuilder(types);
            private final int[] outputChannels = new int[types.size()];

            {
                Arrays.setAll(outputChannels, IntUnaryOperator.identity());
            }

            @Override
            public Page computeNext()
            {
                currentPosition = buildPage(currentPosition, outputChannels, pageBuilder);
                if (pageBuilder.isEmpty()) {
                    return endOfData();
                }
                Page page = pageBuilder.build();
                pageBuilder.reset();
                return page;
            }
        };
    }
1195528
protected final JSONArray getPages(Iterator<Page> pages, int depth, PageFilter pageFilter) throws JSONException {
    JSONArray pagesArray = new JSONArray();

    while (pages.hasNext()) {
      Page page = pages.next();

      // map page attributes to JSON object
      JSONObject pageObject = getPage(page);
      if (pageObject != null) {

        // write children
        Iterator<Page> children = listChildren(page.adaptTo(Resource.class), pageFilter);
        if (!children.hasNext()) {
          pageObject.put("leaf", true);
        }
        else if (depth < getMaxDepth() - 1) {
          pageObject.put("children", getPages(children, depth + 1, pageFilter));
        }

        pagesArray.put(pageObject);
      }
    }

    return pagesArray;
  }
884829
def iterate_pages(self):
        
        try:
            while not self.is_last_page:
                self.current_page += 1
                yield self._query(ItemPage=self.current_page, **self.kwargs)
        except NoMorePages:
            pass
576944
def pages(self):
        
        cur = self
        pages = []
        while cur.previous:
            cur = cur.previous
        while cur:
            pages.append(cur)
            cur = cur.next
        return pages
1303292
def pages(self):
        
        # Each page is an iterator of rows. But also has num_items, remaining,
        # and to_dataframe.
        avro_schema, column_names = _avro_schema(self._read_session)
        for block in self._reader:
            self._status = block.status
            yield ReadRowsPage(avro_schema, column_names, block)