Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
db27620c
Commit
db27620c
authored
Jul 23, 2013
by
Dave Syer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix interfaces in groovy configuration
parent
4ecfbf68
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
9 deletions
+12
-9
ui.groovy
spring-cli/samples/ui.groovy
+12
-7
SampleIntegrationTests.java
.../java/org/springframework/cli/SampleIntegrationTests.java
+0
-2
No files found.
spring-cli/samples/ui.groovy
View file @
db27620c
package
app
import
groovy.util.logging.Log
@Grab
(
"org.thymeleaf:thymeleaf-spring3:2.0.16"
)
@Controller
class
Example
{
...
...
@@ -12,23 +14,26 @@ class Example {
}
import
javax.servlet.http.HttpServletRequest
import
javax.servlet.http.HttpServletResponse
@Configuration
@Log
class
MvcConfiguration
extends
WebMvcConfigurerAdapter
{
@Override
void
addInterceptors
(
def
registry
)
{
log
.
info
(
"Registering
temporary file
interceptor"
)
registry
.
addInterceptor
(
temporaryFileI
nterceptor
())
void
addInterceptors
(
InterceptorRegistry
registry
)
{
log
.
info
(
"Registering interceptor"
)
registry
.
addInterceptor
(
i
nterceptor
())
}
@Bean
HandlerInterceptor
temporaryFileI
nterceptor
()
{
log
.
info
(
"Creating
temporary file
interceptor"
)
HandlerInterceptor
i
nterceptor
()
{
log
.
info
(
"Creating interceptor"
)
new
HandlerInterceptorAdapter
()
{
@Override
postHandle
(
def
request
,
def
response
,
def
handler
,
ModelAndView
mav
)
{
log
.
info
(
"Model: "
+
model
)
void
postHandle
(
HttpServletRequest
request
,
HttpServletResponse
response
,
Object
handler
,
ModelAndView
mav
)
{
log
.
info
(
"Model: "
+
m
av
.
m
odel
)
}
}
}
...
...
spring-cli/src/test/java/org/springframework/cli/SampleIntegrationTests.java
View file @
db27620c
...
...
@@ -28,7 +28,6 @@ import org.apache.ivy.util.FileUtil;
import
org.junit.After
;
import
org.junit.Before
;
import
org.junit.BeforeClass
;
import
org.junit.Ignore
;
import
org.junit.Test
;
import
org.springframework.cli.command.RunCommand
;
...
...
@@ -137,7 +136,6 @@ public class SampleIntegrationTests {
}
@Test
@Ignore
public
void
uiSample
()
throws
Exception
{
// FIXME Failing on OSX
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment