📅  最后修改于: 2022-03-11 14:52:28.686000             🧑  作者: Mango
//In java generics are implemented by using "Type erasure" for backward compatibility. All generic types are converted to Object at runtime. for example,
public class Container {
private T data;
public T getData() {
return data;
}
}
//will be seen at runtime as,
public class Container {
private Object data;
public Object getData() {
return data;
}
}
//Compile ensures cast conversion safety