| 
									
										
										
										
											2013-07-08 13:35:34 -04:00
										 |  |  | package Hydra::Helper::PluginHooks; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | use strict; | 
					
						
							|  |  |  | use Exporter; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | our @ISA = qw(Exporter); | 
					
						
							|  |  |  | our @EXPORT = qw(
 | 
					
						
							|  |  |  |     notifyBuildFinished); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | sub notifyBuildFinished { | 
					
						
							|  |  |  |     my ($plugins, $build, $dependents) = @_; | 
					
						
							|  |  |  |     foreach my $plugin (@{$plugins}) { | 
					
						
							|  |  |  |         eval { | 
					
						
							|  |  |  |             $plugin->buildFinished($build, $dependents); | 
					
						
							|  |  |  |         }; | 
					
						
							|  |  |  |         if ($@) { | 
					
						
							| 
									
										
										
										
											2013-07-08 14:30:46 -04:00
										 |  |  |             print STDERR "$plugin->buildFinished: $@\n"; | 
					
						
							| 
									
										
										
										
											2013-07-08 13:35:34 -04:00
										 |  |  |         } | 
					
						
							|  |  |  |     } | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 1; |