use of org.gradle.internal.component.local.model.PublishArtifactLocalArtifactMetadata in project gradle by gradle.
the class EclipsePlugin method createArtifact.
private static LocalComponentArtifactMetadata createArtifact(String extension, ProjectComponentIdentifier projectId, String projectName, Project project) {
File projectFile = new File(project.getProjectDir(), "." + extension);
Task byName = project.getTasks().getByName("eclipseProject");
String type = "eclipse." + extension;
PublishArtifact publishArtifact = new DefaultPublishArtifact(projectName, extension, type, null, null, projectFile, byName);
return new PublishArtifactLocalArtifactMetadata(projectId, publishArtifact);
}
use of org.gradle.internal.component.local.model.PublishArtifactLocalArtifactMetadata in project gradle by gradle.
the class IdeaPlugin method createImlArtifact.
private static LocalComponentArtifactMetadata createImlArtifact(ProjectComponentIdentifier projectId, Project project) {
String moduleName = project.getExtensions().getByType(IdeaModel.class).getModule().getName();
File imlFile = new File(project.getProjectDir(), moduleName + ".iml");
Task byName = project.getTasks().getByName("ideaModule");
PublishArtifact publishArtifact = new DefaultPublishArtifact(moduleName, "iml", "iml", null, null, imlFile, byName);
return new PublishArtifactLocalArtifactMetadata(projectId, publishArtifact);
}
use of org.gradle.internal.component.local.model.PublishArtifactLocalArtifactMetadata in project gradle by gradle.
the class CompositeProjectComponentArtifactMetadataSerializer method read.
@Override
public CompositeProjectComponentArtifactMetadata read(Decoder decoder) throws Exception {
ProjectComponentIdentifier componentIdentifier = (ProjectComponentIdentifier) componentIdentifierSerializer.read(decoder);
PublishArtifactLocalArtifactMetadata delegate = publishArtifactLocalArtifactMetadataSerializer.read(decoder);
File file = new File(decoder.readString());
return new CompositeProjectComponentArtifactMetadata(componentIdentifier, delegate, file);
}
use of org.gradle.internal.component.local.model.PublishArtifactLocalArtifactMetadata in project gradle by gradle.
the class PublishArtifactLocalArtifactMetadataSerializer method read.
@Override
public PublishArtifactLocalArtifactMetadata read(Decoder decoder) throws Exception {
ComponentIdentifier identifier = componentIdentifierSerializer.read(decoder);
String artifactName = decoder.readString();
String artifactExtension = decoder.readString();
String artifactType = decoder.readString();
String artifactClassifier = decoder.readNullableString();
File artifactFile = new File(decoder.readString());
return new PublishArtifactLocalArtifactMetadata(identifier, new ImmutablePublishArtifact(artifactName, artifactExtension, artifactType, artifactClassifier, artifactFile));
}
Aggregations