I have problem with templates in Java. I don't know what is wrong. I pasted the code from C# to Java and does not work.
class A<T1, T2>
class A<T1, T2, T3>
You cannot have two outer classes with the same name in the same package. Try renaming one of the classes or put it in a different package. Alternatively putting one class as a nested class of another class would also work, but the question is if they really need to have the same name.