Commit a9805e6366b10f3a84c238d293d51123a887cf25
1 parent
22125b4a
Exists in
master
Ajustes no código para evitar o erro de compilação do Maven
Showing
2 changed files
with
12 additions
and
8 deletions
Show diff stats
impl/core/src/main/java/br/gov/frameworkdemoiselle/internal/bootstrap/ShutdownBootstrap.java
@@ -68,8 +68,9 @@ public class ShutdownBootstrap extends AbstractBootstrap { | @@ -68,8 +68,9 @@ public class ShutdownBootstrap extends AbstractBootstrap { | ||
68 | 68 | ||
69 | private static final List<CustomContext> tempContexts = new ArrayList<CustomContext>(); | 69 | private static final List<CustomContext> tempContexts = new ArrayList<CustomContext>(); |
70 | 70 | ||
71 | - private static final List<ShutdownProcessor<?>> processors = Collections | ||
72 | - .synchronizedList(new ArrayList<ShutdownProcessor<?>>()); | 71 | + @SuppressWarnings("rawtypes") |
72 | + private static final List<ShutdownProcessor> processors = Collections | ||
73 | + .synchronizedList(new ArrayList<ShutdownProcessor>()); | ||
73 | 74 | ||
74 | /** | 75 | /** |
75 | * Observes all methods annotated with @Shutdown and create an instance of ShutdownProcessor for them | 76 | * Observes all methods annotated with @Shutdown and create an instance of ShutdownProcessor for them |
@@ -105,6 +106,7 @@ public class ShutdownBootstrap extends AbstractBootstrap { | @@ -105,6 +106,7 @@ public class ShutdownBootstrap extends AbstractBootstrap { | ||
105 | /** | 106 | /** |
106 | * Before Shutdown it execute the methods annotateds with @Shutdown considering the priority order; | 107 | * Before Shutdown it execute the methods annotateds with @Shutdown considering the priority order; |
107 | */ | 108 | */ |
109 | + @SuppressWarnings({ "unchecked", "rawtypes" }) | ||
108 | public synchronized static void shutdown() { | 110 | public synchronized static void shutdown() { |
109 | getLogger().debug( | 111 | getLogger().debug( |
110 | getBundle("demoiselle-core-bundle").getString("executing-all", annotationClass.getSimpleName())); | 112 | getBundle("demoiselle-core-bundle").getString("executing-all", annotationClass.getSimpleName())); |
@@ -112,8 +114,8 @@ public class ShutdownBootstrap extends AbstractBootstrap { | @@ -112,8 +114,8 @@ public class ShutdownBootstrap extends AbstractBootstrap { | ||
112 | Collections.sort(processors); | 114 | Collections.sort(processors); |
113 | Throwable failure = null; | 115 | Throwable failure = null; |
114 | 116 | ||
115 | - for (Iterator<ShutdownProcessor<?>> iter = processors.iterator(); iter.hasNext();) { | ||
116 | - ShutdownProcessor<?> processor = iter.next(); | 117 | + for (Iterator<ShutdownProcessor> iter = processors.iterator(); iter.hasNext();) { |
118 | + ShutdownProcessor processor = iter.next(); | ||
117 | 119 | ||
118 | try { | 120 | try { |
119 | processor.process(); | 121 | processor.process(); |
impl/core/src/main/java/br/gov/frameworkdemoiselle/internal/bootstrap/StartupBootstrap.java
@@ -67,8 +67,9 @@ public class StartupBootstrap extends AbstractBootstrap { | @@ -67,8 +67,9 @@ public class StartupBootstrap extends AbstractBootstrap { | ||
67 | 67 | ||
68 | private static final List<ThreadLocalContext> tempContexts = new ArrayList<ThreadLocalContext>(); | 68 | private static final List<ThreadLocalContext> tempContexts = new ArrayList<ThreadLocalContext>(); |
69 | 69 | ||
70 | - private static final List<StartupProcessor<?>> processors = Collections | ||
71 | - .synchronizedList(new ArrayList<StartupProcessor<?>>()); | 70 | + @SuppressWarnings("rawtypes") |
71 | + private static final List<StartupProcessor> processors = Collections | ||
72 | + .synchronizedList(new ArrayList<StartupProcessor>()); | ||
72 | 73 | ||
73 | /** | 74 | /** |
74 | * Observes all methods annotated with @Startup and create an instance of StartupAction for them | 75 | * Observes all methods annotated with @Startup and create an instance of StartupAction for them |
@@ -103,6 +104,7 @@ public class StartupBootstrap extends AbstractBootstrap { | @@ -103,6 +104,7 @@ public class StartupBootstrap extends AbstractBootstrap { | ||
103 | /** | 104 | /** |
104 | * After the deployment validation it execute the methods annotateds with @Startup considering the priority order; | 105 | * After the deployment validation it execute the methods annotateds with @Startup considering the priority order; |
105 | */ | 106 | */ |
107 | + @SuppressWarnings({ "unchecked", "rawtypes" }) | ||
106 | public synchronized static void startup() { | 108 | public synchronized static void startup() { |
107 | getLogger().debug( | 109 | getLogger().debug( |
108 | getBundle("demoiselle-core-bundle").getString("executing-all", annotationClass.getSimpleName())); | 110 | getBundle("demoiselle-core-bundle").getString("executing-all", annotationClass.getSimpleName())); |
@@ -110,8 +112,8 @@ public class StartupBootstrap extends AbstractBootstrap { | @@ -110,8 +112,8 @@ public class StartupBootstrap extends AbstractBootstrap { | ||
110 | Collections.sort(processors); | 112 | Collections.sort(processors); |
111 | Throwable failure = null; | 113 | Throwable failure = null; |
112 | 114 | ||
113 | - for (Iterator<StartupProcessor<?>> iter = processors.iterator(); iter.hasNext();) { | ||
114 | - StartupProcessor<?> processor = iter.next(); | 115 | + for (Iterator<StartupProcessor> iter = processors.iterator(); iter.hasNext();) { |
116 | + StartupProcessor processor = iter.next(); | ||
115 | 117 | ||
116 | try { | 118 | try { |
117 | processor.process(); | 119 | processor.process(); |