各位请问一下does not take parameters是什么意思,我该怎么做呀

scala> val pagetypeCodeList=pagetypeRDD.map(x=>(userZipCode01Map(x._1),keywordZipCode01(x._2),x._3,x._4)).sortBy(x=>x._4)
:29: error: org.apache.spark.rdd.RDD[(String, Int)] does not take parameters

要初始化无参数方法,您需要使用带def关键字的名称,但不带“()”括号。 在调用该方法时,我们也将避免使用“()”括号。