package finiteClosure;

import de.dhbwstuttgart.core.JavaTXCompiler;
import de.dhbwstuttgart.parser.SyntaxTreeGenerator.FCGenerator;
import de.dhbwstuttgart.syntaxtree.ClassOrInterface;
import de.dhbwstuttgart.syntaxtree.factory.ASTFactory;
import org.junit.jupiter.api.Test;

import java.util.ArrayList;
import java.util.Collection;

public class SuperInterfacesTest {
    @Test
    public void test() throws ClassNotFoundException {
        Collection<ClassOrInterface> classes = new ArrayList<>();
        classes.add(ASTFactory.createClass(TestClass.class));
        System.out.println(FCGenerator.toFC(classes, ClassLoader.getSystemClassLoader(), JavaTXCompiler.defaultClientPlaceholderRegistry));
    }

    @Test
    public void testGeneric() throws ClassNotFoundException {
        Collection<ClassOrInterface> classes = new ArrayList<>();
        classes.add(ASTFactory.createClass(TestClassGeneric.class));
        System.out.println(FCGenerator.toFC(classes, ClassLoader.getSystemClassLoader(), JavaTXCompiler.defaultClientPlaceholderRegistry));
    }
}

class TestClass implements Test2, Test3{

}

class TestClassGeneric<A,B> implements Test4<A>{

}

interface Test2 {

}

interface Test3{

}

interface Test4<A>{

}