Skip to content

Instantly share code, notes, and snippets.

@ohjongsung
Last active March 27, 2018 12:30
Show Gist options
  • Save ohjongsung/481f65a9cf7b13d4a07e4bf7fe6b4ac6 to your computer and use it in GitHub Desktop.
Save ohjongsung/481f65a9cf7b13d4a07e4bf7fe6b4ac6 to your computer and use it in GitHub Desktop.
// Comparable 인터페이스를 구현해 봤다면 알 것이다.
// public interface Comparable<T> {
// public int compareTo(T o);
// }
class GenericInterfaceImpl implements Generic<String, Integer> {
@Override
public String doSomething(Integer t) {
return t.toString();
}
@Override
public Integer doSomething2(String t) {
return Integer.parseInt(t);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment