« first day (1150 days earlier)      last day (1789 days later) » 

1:47 PM
Hi. I have this piece of code:

`
interface AnonymousFunctionPlaceholder {
void doSomething();
}

public void withUser(User user, AnonymousFunctionPlaceholder anonymousFunctionPlaceholder) {
try {
storeUser(user);
anonymousFunctionPlaceholder.doSomething();
} finally {
SecurityContextHolder.clearContext();
}
}
`

Is it possible to pass in annonymous function like this without declaring a confusing "AnonymousFunctionPlaceholder" ?
 
1 message moved from Java
 

« first day (1150 days earlier)      last day (1789 days later) »