public void addTrigger ( final File script , final String prog , final Map < String , IntString > depends , final int flag ) throws IOException { triggerscripts . add ( readScript ( script ) ) ; if ( null == prog ) { triggerscriptprogs . add ( DEFAULTSCRIPTPROG ) ; } else if ( 0 == prog . length ( ) ) { triggerscriptprogs . add ( DEFAULTSCRIPTPROG ) ; } else { triggerscriptprogs . add ( prog ) ; } for ( Map . Entry < String , IntString > depend : depends . entrySet ( ) ) { triggernames . add ( depend . getKey ( ) ) ; triggerflags . add ( depend . getValue ( ) . getInt ( ) | flag ) ; triggerversions . add ( depend . getValue ( ) . getString ( ) ) ; triggerindexes . add ( triggerCounter ) ; } triggerCounter ++ ; }
Adds a trigger to the RPM package .