爲Repository添加自定義方法

文章目錄 1、爲某個Repository添加自定義方法 一、定義一個接口PersonDao,聲明要添加的方法。 二、提供該接口的實現類PersonRepositoryImpl。類名需在要與聲明的 Repository 後添加 Impl,並實現PersonDao中聲明的方法。 三、使用Repository 接口, 並繼承PersonDao接口。 四、這時SpringData會自動加載PersonRe
相關文章
相關標籤/搜索