Newyorkcity
V2EX  ›  问与答

请问有办法把 spring validation 中的校验器提取出来使用吗?

  •  
  •   Newyorkcity · Jul 4, 2023 · 749 views
    This topic created in 1069 days ago, the information mentioned may be changed or developed.
    如意,spring validation 使得 controller 层校验进入的请求体的内容变得很方便。但现在我想手动校验一个 POJO 实例,不知道有没有办法那那个校验器取出来让它对这个实例做校验?
    谢谢
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2861 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 30ms · UTC 08:20 · PVG 16:20 · LAX 01:20 · JFK 04:20
    ♥ Do have faith in what you're doing.