// Path: src/main/java/de/jfschaefer/layeredgraphlayout/util/Pair.java
// public class Pair<A, B> {
//     public final A first;
//     public final B second;
//     public Pair(A first, B second) {
//         this.first = first;
//         this.second = second;
//     }
// }


import de.jfschaefer.layeredgraphlayout.layout.*;
import de.jfschaefer.layeredgraphlayout.util.Pair;
import java.util.*;
package de.jfschaefer.layeredgraphlayout.latex;



/**
 * Created by jfschaefer on 8/10/15.
 */

public class LatexGenerator<V, E> {
    public static <V, E> String generateLatex(Layout<V, E> layout, Map<V, String> nodeMap, Map<E, String> edgeMap, boolean drawBox) {
        StringBuilder sb = new StringBuilder();
        sb.append("\\begin{tikzpicture}\n");
        de.jfschaefer.layeredgraphlayout.layout.Vector shift = layout.getShift();

        // Step 1: Draw nodes
        for (V node : layout.getNodeSet()) {
            sb.append("\\node (rect) at (");
// Path: src/main/java/de/jfschaefer/layeredgraphlayout/util/Pair.java
// public class Pair<A, B> {
//     public final A first;
//     public final B second;
//     public Pair(A first, B second) {
//         this.first = first;
//         this.second = second;
//     }
// }


// Path: src/main/java/de/jfschaefer/layeredgraphlayout/latex/LatexGenerator.java
import de.jfschaefer.layeredgraphlayout.layout.*;
import de.jfschaefer.layeredgraphlayout.util.Pair;
import java.util.*;

package de.jfschaefer.layeredgraphlayout.latex;



/**
 * Created by jfschaefer on 8/10/15.
 */

public class LatexGenerator<V, E> {
    public static <V, E> String generateLatex(Layout<V, E> layout, Map<V, String> nodeMap, Map<E, String> edgeMap, boolean drawBox) {
        StringBuilder sb = new StringBuilder();
        sb.append("\\begin{tikzpicture}\n");
        de.jfschaefer.layeredgraphlayout.layout.Vector shift = layout.getShift();

        // Step 1: Draw nodes
        for (V node : layout.getNodeSet()) {
            sb.append("\\node (rect) at (");
            Pair<Double, Double> size = layout.getNodeSize(node);