Implemented generic class with Rectange case