1
2
3
4
5
6
7 package org.mule.util;
8
9 import org.mule.api.MuleContext;
10 import org.mule.config.i18n.CoreMessages;
11
12 import java.util.Date;
13
14 public class ApplicationShutdownSplashScreen extends SplashScreen
15 {
16 protected void doHeader(MuleContext context)
17 {
18 long currentTime = System.currentTimeMillis();
19 header.add(CoreMessages.applicationShutdownNormally(context.getConfiguration().getId(), new Date()).getMessage());
20 long duration = 10;
21 if (context.getStartDate() > 0)
22 {
23 duration = currentTime - context.getStartDate();
24 }
25 header.add(CoreMessages.applicationWasUpForDuration(duration).getMessage());
26 }
27 }
28
29