Based on the Model-View-Controller (MVC) pattern, Spring MVC helps you build web-based applications that are flexible and decoupled from the underlying view technologies.

learn more… | top users | synonyms

1
vote
0answers
5 views

Formatting data in a UIViewController in a weight-training app

I'm writing a weight training app that calculates a one rep maximum and it has several options including recording your lifts in pounds or kilograms. I'm trying my best to follow the MVC pattern but I'...
1
vote
0answers
34 views

Spring MVC web app for simple ciphers

I'm working on a simple Spring MVC web app that allows users to encrypt and decrypt messages with classical ciphers such as the shift or Caesar cipher. It also allows users to auto-decrypt a message ...
1
vote
0answers
35 views

Spring MVC validation Multipart file in form

I need make validation of Multipart file in form class. I wrote custom annotation for form class which validate Multipart file. This code works great, but I don`t know if this is a good approach. ...
0
votes
1answer
60 views

Does this unit test cover all edge cases? [closed]

I want to test a simple controller and I want to know if this unit test covers all cases: Controller: ...
0
votes
0answers
26 views

ResponseEntity<Error> bad design

We have implemented this pojo to use in the org.springframework.http.ResponseEntity. ...
1
vote
1answer
69 views

Spring MVC controller

My code has a nasty smell that looks like this: ...
1
vote
0answers
29 views

Throw exception in Spring when loading a file

I have this following piece of code: ...
3
votes
1answer
69 views

Spring controller code to group information by date

I'm using the Spring Framework in my web application and I'm curious as to whether my controller implementations are good or not. I've used many Hashmaps to make a object that serves my purpose for ...
0
votes
0answers
37 views

Spring: Redirecting to a REST url on click

I have a page where a user can click on a link and send them to another url where the path variable is the user name. So example: user name is bmarkham. bmarkham is on www.website.com/welcome. ...
0
votes
1answer
169 views

Detect that a class is marked by a custom annotation in Spring

I would like to enable application behaviour based on the presence of a custom annotation that marks the configuration class (normally named something like ...
4
votes
0answers
295 views

Implement two level caching using spring's cache abstraction Cache and CacheManager

Details about spring's caching framework are here. When I was reading this link, I thought the composite cache mentioned there was one that used levels of caching based on the order given to the ...
0
votes
0answers
152 views

Exception-logging handler for the DAO layer

I'm a bit clueless on how to handle exceptions. What I've think so far is to use a custom error page for the users so they can't see the full exception for security reasons and log the exception in a <...
6
votes
1answer
2k views

Preventing XSS attacks in a Spring MVC application controller

One of the URL in my application is vulnerable to XSS attack, so I am handling it in the below way. I created a util class: ...