void (JpsArtifact artifact, final Consumer<? super JpsArtifact> consumer) { JpsArtifactUtil.processPackagingElements(artifact.getRootElement(), element -> { if (element instanceof JpsArtifactOutputPackagingElement) { JpsArtifact included = ((JpsArtifactOutputPackagingElement)element).getArtifactReference().resolve(); if (included != null) { consumer.consume(included); } return false; } return true; }); }