protected File getMarkerFile()

in src/main/java/org/apache/maven/plugins/dependency/utils/markers/UnpackFileMarkerHandler.java [51:78]


    protected File getMarkerFile() {
        /*
         * Build a hash of all include/exclude strings, to determine if an artifactItem has been unpacked using the
         * include/exclude parameters. This allows an artifact to be included multiple times with different
         * include/exclude parameters.
         */
        File markerFile;
        if (this.artifactItem == null
                || this.artifactItem.getIncludes().isEmpty()
                        && this.artifactItem.getExcludes().isEmpty()) {
            markerFile = super.getMarkerFile();
        } else {
            int includeExcludeHash = 0;

            if (!this.artifactItem.getIncludes().isEmpty()) {
                includeExcludeHash += this.artifactItem.getIncludes().hashCode();
            }

            if (!this.artifactItem.getExcludes().isEmpty()) {
                includeExcludeHash += this.artifactItem.getExcludes().hashCode();
            }

            markerFile =
                    new File(this.markerFilesDirectory, this.artifact.getId().replace(':', '-') + includeExcludeHash);
        }

        return markerFile;
    }