Scalaのキャスト - Qiita

型のキャストは、AnyのasInstanceOfメソッドで行います。val x: Any = 1val y: Int = x.asInstanceOf[Int]関連isInstanceOf