private File computeDestinationFolder ( final ResourceType resourceType ) throws MojoExecutionException { File folder = destinationFolder ; if ( resourceType == ResourceType . JS ) { if ( jsDestinationFolder != null ) { folder = jsDestinationFolder ; } } if ( resourceType == ResourceType . CSS ) { if ( cssDestinationFolder != null ) { folder = cssDestinationFolder ; } } getLog ( ) . info ( "folder: " + folder ) ; if ( folder == null ) { throw new MojoExecutionException ( "Couldn't compute destination folder for resourceType: " + resourceType + ". That means that you didn't define one of the following parameters: " + "destinationFolder, cssDestinationFolder, jsDestinationFolder" ) ; } if ( ! folder . exists ( ) ) { folder . mkdirs ( ) ; } return folder ; }
Computes the destination folder based on resource type .