private ArchivaProjectModel createDefaultModel( ArtifactReference reference ) { ArchivaProjectModel model = new ArchivaProjectModel(); // Create default (dummy) model model = new ArchivaProjectModel(); model.setGroupId( reference.getGroupId() ); model.setArtifactId( reference.getArtifactId() ); model.setVersion( reference.getVersion() ); model.setPackaging( reference.getType() ); return model; } }
public static String toKey( ArtifactReference ref ) { return toKey( ref.getGroupId(), ref.getArtifactId(), ref.getVersion(), ref.getClassifier(), ref.getType() ); }
public static String toKey( VersionedReference ref ) { return toKey( ref.getGroupId(), ref.getArtifactId(), ref.getVersion() ); } }
private VersionedReference toVersionedReference( DependencyGraphNode node ) { VersionedReference ref = new VersionedReference(); ref.setGroupId( node.getArtifact().getGroupId() ); ref.setArtifactId( node.getArtifact().getArtifactId() ); ref.setVersion( node.getArtifact().getVersion() ); return ref; }
public static VersionedReference clone( VersionedReference versionedReference ) { if ( versionedReference == null ) { return null; } VersionedReference cloned = new VersionedReference(); cloned.setGroupId( versionedReference.getGroupId() ); cloned.setArtifactId( versionedReference.getArtifactId() ); cloned.setVersion( versionedReference.getVersion() ); return cloned; }
public static String toKey( ArchivaProjectModel model ) { return toKey( model.getGroupId(), model.getArtifactId(), model.getVersion() ); }
public RepositoryProblemReport( RepositoryProblem repositoryProblem ) { setGroupId( repositoryProblem.getGroupId() ); setArtifactId( repositoryProblem.getArtifactId() ); setVersion( repositoryProblem.getVersion() ); setMessage( repositoryProblem.getMessage() ); setOrigin( repositoryProblem.getOrigin() ); setPath( repositoryProblem.getPath() ); setType( repositoryProblem.getType() ); }
public static Organization clone( Organization organization ) { if ( organization == null ) { return null; } Organization cloned = new Organization(); cloned.setFavicon( organization.getFavicon() ); cloned.setName( organization.getName() ); cloned.setUrl( organization.getUrl() ); return cloned; }
public boolean evaluate( Object object ) { boolean satisfies = false; if ( object instanceof ArchivaArtifact ) { ArchivaArtifact artifact = (ArchivaArtifact) object; satisfies = !artifact.getModel().isProcessed(); } else if ( object instanceof ArchivaArtifactModel ) { ArchivaArtifactModel model = (ArchivaArtifactModel) object; satisfies = !model.isProcessed(); } return satisfies; } }
public static SnapshotVersion clone( SnapshotVersion snapshotVersion ) { if ( snapshotVersion == null ) { return null; } SnapshotVersion cloned = new SnapshotVersion(); cloned.setTimestamp( snapshotVersion.getTimestamp() ); cloned.setBuildNumber( snapshotVersion.getBuildNumber() ); return cloned; }
public static CiManagement clone( CiManagement ciManagement ) { if ( ciManagement == null ) { return null; } CiManagement cloned = new CiManagement(); cloned.setSystem( ciManagement.getSystem() ); cloned.setUrl( ciManagement.getUrl() ); return cloned; }
public Dependency asDependency() { Dependency dep = new Dependency(); dep.setGroupId( groupId ); dep.setArtifactId( artifactId ); dep.setVersion( version ); dep.setType( packaging ); return dep; }
public static ArchivaArtifactJavaDetails getJavaDetails( ArchivaArtifact artifact ) { ArchivaArtifactJavaDetails javaDetails = (ArchivaArtifactJavaDetails) artifact.getPlatformDetails(); if ( javaDetails == null ) { javaDetails = new ArchivaArtifactJavaDetails(); artifact.setPlatformDetails( javaDetails ); } return javaDetails; } }
public int hashCode() { final int PRIME = 31; int result = 1; result = PRIME * result + ( ( artifact == null ) ? 0 : artifact.hashCode() ); return result; }
public boolean evaluate( Object object ) { boolean satisfies = false; if ( object instanceof NodeLocation ) { NodeLocation nodeloc = (NodeLocation) object; satisfies = nodeloc.artifact.equals( artifact ); } return satisfies; }
public String toString() { return Dependency.toKey( this ); }
public static List cloneAvailableVersions( List availableVersions ) { return cloneSimpleStringList( availableVersions ); } }
public int hashCode() { final int PRIME = 31; int result = 1; result = PRIME * result + ( ( artifact == null ) ? 0 : artifact.hashCode() ); return result; }
public int hashCode() { final int PRIME = 31; int result = 1; result = PRIME * result + ( ( artifact == null ) ? 0 : artifact.hashCode() ); return result; }