1 package org.apache.archiva.scheduler.repository;
5 import org.codehaus.plexus.taskqueue.Task;
8 * Licensed to the Apache Software Foundation (ASF) under one
9 * or more contributor license agreements. See the NOTICE file
10 * distributed with this work for additional information
11 * regarding copyright ownership. The ASF licenses this file
12 * to you under the Apache License, Version 2.0 (the
13 * "License"); you may not use this file except in compliance
14 * with the License. You may obtain a copy of the License at
16 * http://www.apache.org/licenses/LICENSE-2.0
18 * Unless required by applicable law or agreed to in writing,
19 * software distributed under the License is distributed on an
20 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
21 * KIND, either express or implied. See the License for the
22 * specific language governing permissions and limitations
27 * DataRefreshTask - task for discovering changes in the repository
28 * and updating all associated data.
30 * @version $Id: DataRefreshTask.java 525176 2007-04-03 15:21:33Z joakime $
32 public class RepositoryTask
40 result = prime * result + ( ( repositoryId == null ) ? 0 : repositoryId.hashCode() );
41 result = prime * result + ( ( resourceFile == null ) ? 0 : resourceFile.hashCode() );
46 public boolean equals( Object obj )
52 if ( getClass() != obj.getClass() )
54 RepositoryTask other = (RepositoryTask) obj;
55 if ( repositoryId == null )
57 if ( other.repositoryId != null )
60 else if ( !repositoryId.equals( other.repositoryId ) )
62 if ( resourceFile == null )
64 if ( other.resourceFile != null )
67 else if ( !resourceFile.equals( other.resourceFile ) )
72 private String repositoryId;
74 private File resourceFile;
76 private boolean updateRelatedArtifacts;
78 private boolean scanAll;
80 public boolean isScanAll()
85 public void setScanAll( boolean scanAll )
87 this.scanAll = scanAll;
90 public String getRepositoryId()
95 public void setRepositoryId( String repositoryId )
97 this.repositoryId = repositoryId;
100 public long getMaxExecutionTime()
105 public File getResourceFile()
110 public void setResourceFile( File resourceFile )
112 this.resourceFile = resourceFile;
115 public boolean isUpdateRelatedArtifacts()
117 return updateRelatedArtifacts;
120 public void setUpdateRelatedArtifacts( boolean updateRelatedArtifacts )
122 this.updateRelatedArtifacts = updateRelatedArtifacts;
126 public String toString()
128 return "RepositoryTask [repositoryId=" + repositoryId + ", resourceFile=" + resourceFile + ", scanAll="
129 + scanAll + ", updateRelatedArtifacts=" + updateRelatedArtifacts + "]";