public GAV( ProjectVersionRef pvr ) { groupId = pvr.getGroupId(); artifactId = pvr.getArtifactId(); version = pvr.getVersionString(); } }
private static void comparePlugins( Type type, boolean reportNonAligned, Set<ProjectVersionRef> originalPlugins, Set<ProjectVersionRef> newPlugins ) { Set<ProjectVersionRef> nonAligned = new HashSet<>( ); originalPlugins.forEach( originalPVR -> newPlugins.stream().filter( newPVR -> ( newPVR.getGroupId().equals( originalPVR.getGroupId() ) && newPVR.getArtifactId().equals( originalPVR.getArtifactId() ) ) ).forEach( newArtifact -> { if ( ! newArtifact.getVersionString().equals( originalPVR.getVersionString() ) ) { logger.info( "\t{} : {} --> {} ", type, originalPVR, newArtifact ); } else if ( reportNonAligned ) { nonAligned.add( originalPVR ); } } ) ); if ( nonAligned.size() > 0 ) { logger.info( "" ); nonAligned.forEach( pv -> logger.info( "\tNon-Aligned {} : {} ", type, pv ) ); } }
public PluginKey(ProjectVersionRef target, boolean managed) { this.groupId = target.getGroupId(); this.artifactId = target.getArtifactId(); this.version = target.getVersionString(); this.managed = managed; }
public static GAV generateGAV(ProjectVersionRef dep) { return new GAV(dep.getGroupId(), dep.getArtifactId(), dep.getVersionString()); }
private GAV generateGAV(ProjectVersionRef ref) { return new GAV(ref.getGroupId(), ref.getArtifactId(), ref.getVersionString()); }
public SimpleArtifactRef( final ProjectVersionRef ref, final String type, final String classifier ) { super( ref.getGroupId(), ref.getArtifactId(), ref.getVersionSpecRaw(), ref.getVersionStringRaw() ); this.tc = new SimpleTypeAndClassifier( type, classifier ); }
public SimpleArtifactRef( final ProjectVersionRef ref, final TypeAndClassifier tc ) { super( ref.getGroupId(), ref.getArtifactId(), ref.getVersionSpecRaw(), ref.getVersionStringRaw() ); this.tc = getSimpleTypeAndClassifier( tc ); }
public GAV getGAV() throws PomAnalysisException { if (ref == null) throw new PomAnalysisException("Failed to get gav from " + path); return new GAV(ref.getGroupId(), ref.getArtifactId(), ref.getVersionString()); }
public static void toNodeProperties( final ProjectVersionRef ref, final Node node, final boolean connected ) { Logger logger = LoggerFactory.getLogger( Conversions.class ); logger.debug( "Adding {} (type: {}) to node: {}", ref, ref.getClass().getSimpleName(), node ); if ( !( ref instanceof NeoProjectVersionRef ) || ( (NeoProjectVersionRef) ref ).isDirty() ) { final String g = ref.getGroupId(); final String a = ref.getArtifactId(); final String v = ref.getVersionString(); if ( empty( g ) || empty( a ) || empty( v ) ) { throw new IllegalArgumentException( String.format( "GAV cannot contain nulls: %s:%s:%s", g, a, v ) ); } node.setProperty( ARTIFACT_ID, a ); node.setProperty( GROUP_ID, g ); logger.debug( "Setting property: {} with value: {} for node: {}", VERSION, v, node.getId() ); node.setProperty( VERSION, v ); node.setProperty( GAV, ref.toString() ); } node.setProperty( NODE_TYPE, NodeType.PROJECT.name() ); if ( ref.isVariableVersion() ) { node.setProperty( VARIABLE, true ); } markConnected( node, connected ); // // logger.debug( "groupId of {} is:\nNeoIdentityUtils: {}\nConversions: {}\nDirect access: {}", node, // NeoIdentityUtils.getStringProperty( node, GROUP_ID, null, null ), // getStringProperty( GROUP_ID, node ), node.hasProperty( GROUP_ID ) ? node.getProperty( GROUP_ID ) : null ); }
.getId(), type.name(), target.getGroupId(), target.getArtifactId() );
projectVersionRef.getArtifactId(), projectVersionRef.getVersionString(), executionRootName,
model.setModelVersion( "4.0.0" ); model.setGroupId( pomCoord.getGroupId() ); model.setArtifactId( pomCoord.getArtifactId() ); model.setVersion( pomCoord.getVersionSpec().renderStandard() ); model.setPackaging( "pom" ); if ( recipe.isGraphToManagedDeps() ) model.setName( pomCoord.getArtifactId() + ":: Bill of Materials" ); dm = new DependencyManagement(); model.setDependencyManagement( dm ); model.setName( pomCoord.getArtifactId() ); dm = null;
model.setModelVersion( "4.0.0" ); model.setGroupId( pomCoord.getGroupId() ); model.setArtifactId( pomCoord.getArtifactId() ); model.setVersion( pomCoord.getVersionSpec().renderStandard() ); model.setPackaging( "pom" ); if ( recipe.isGraphToManagedDeps() ) model.setName( pomCoord.getArtifactId() + ":: Bill of Materials" ); dm = new DependencyManagement(); model.setDependencyManagement( dm ); model.setName( pomCoord.getArtifactId() ); dm = null;