-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
208 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
package org.codejive.jpm.util; | ||
|
||
import java.util.Collections; | ||
import java.util.List; | ||
import org.eclipse.aether.artifact.Artifact; | ||
|
||
/** Hold the result of a search while also functioning as a kind of bookmark for paging purposes. */ | ||
public class SearchResult { | ||
/** The artifacts that matched the search query. */ | ||
public final List<? extends Artifact> artifacts; | ||
|
||
/** The search query that produced this result. */ | ||
public final String query; | ||
|
||
/** The index of the first artifact in this result relative to the total result set. */ | ||
public final int start; | ||
|
||
/** The maximum number of results to return */ | ||
public final int count; | ||
|
||
/** The total number of artifacts that matched the search query. */ | ||
public final int total; | ||
|
||
/** | ||
* Create a new search result. | ||
* | ||
* @param artifacts The artifacts that matched the search query. | ||
* @param query The search query that produced this result. | ||
* @param start The index of the first artifact in this result relative to the total result set. | ||
* @param count The maximum number of results to return. | ||
* @param total The total number of artifacts that matched the search query. | ||
*/ | ||
public SearchResult( | ||
List<? extends Artifact> artifacts, String query, int start, int count, int total) { | ||
this.artifacts = Collections.unmodifiableList(artifacts); | ||
this.query = query; | ||
this.start = start; | ||
this.count = count; | ||
this.total = total; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,13 @@ | ||
package org.codejive.jpm.util; | ||
|
||
/** Utility class for keeping track of synchronization statistics. */ | ||
public class SyncStats { | ||
/** The number of new artifacts that were copied. */ | ||
public int copied; | ||
|
||
/** The number of existing artifacts that were updated. */ | ||
public int updated; | ||
|
||
/** The number of existing artifacts that were deleted. */ | ||
public int deleted; | ||
} |
Oops, something went wrong.