What does this block of code do?

后端 未结 6 989
鱼传尺愫
鱼传尺愫 2021-01-24 13:19

I\'m not quite sure what this means or whats it doing, Could some one elaborate?

Player player = (Player) sender;
6条回答
  •  太阳男子
    2021-01-24 13:28

    This is an assignment, with a cast operation.

    You can learn a lot about java cast operator with the answers to this question: How does the Java cast operator work?

提交回复
热议问题