Example usage for org.apache.commons.jrcs.rcs Node getChild

List of usage examples for org.apache.commons.jrcs.rcs Node getChild

Introduction

In this page you can find the example usage for org.apache.commons.jrcs.rcs Node getChild.

Prototype

public final Node getChild() 

Source Link

Usage

From source file:org.opensolaris.opengrok.history.RCSHistoryParser.java

private void traverse(Node n, List<HistoryEntry> history) {
    if (n == null) {
        return;//from   w  ww.  j av  a 2 s  . c o m
    }
    traverse(n.getChild(), history);
    TreeMap<?, ?> brt = n.getBranches();
    if (brt != null) {
        for (Iterator<?> i = brt.values().iterator(); i.hasNext();) {
            Node b = (Node) i.next();
            traverse(b, history);
        }
    }
    if (!n.isGhost()) {
        HistoryEntry entry = new HistoryEntry();
        entry.setRevision(n.getVersion().toString());
        entry.setDate(n.getDate());
        entry.setAuthor(n.getAuthor());
        entry.setMessage(n.getLog());
        entry.setActive(true);
        history.add(entry);
    }
}