Duplicate code, cuboid have getVolume() method.