Add missing @since tags to mark API added in 2.0 Change-Id: I0a86ce0e393dfde9bb27f0b29e036e76c856396e Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Signed-off-by: Chris Aniszczyk <zx@twitter.com>
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java index 86b8d85..8658b07 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyCommand.java
@@ -68,6 +68,7 @@ * * @see <a href="http://www.kernel.org/pub/software/scm/git/docs/git-apply.html" * >Git documentation about apply</a> + * @since 2.0 */ public class ApplyCommand extends GitCommand<ApplyResult> {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyResult.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyResult.java index 0c38f1b..558ef0f 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyResult.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/ApplyResult.java
@@ -48,6 +48,8 @@ /** * Encapsulates the result of a {@link ApplyCommand} + * + * @since 2.0 */ public class ApplyResult {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java index e03805b..e6d56c8 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java
@@ -253,6 +253,7 @@ public CheckoutCommand addPath(String path) { * @param all * true to checkout all paths, false otherwise * @return {@code this} + * @since 2.0 */ public CheckoutCommand setAllPaths(boolean all) { checkoutAllPaths = all;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/Git.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/Git.java index f523586..8a86af8 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/Git.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/Git.java
@@ -576,6 +576,7 @@ public StashListCommand stashList() { * Returns a command object used to create a stashed commit * * @return a {@link StashCreateCommand} + * @since 2.0 */ public StashCreateCommand stashCreate() { return new StashCreateCommand(repo); @@ -585,6 +586,7 @@ public StashCreateCommand stashCreate() { * Returns a command object used to apply a stashed commit * * @return a {@link StashApplyCommand} + * @since 2.0 */ public StashApplyCommand stashApply() { return new StashApplyCommand(repo); @@ -594,6 +596,7 @@ public StashApplyCommand stashApply() { * Returns a command object used to drop a stashed commit * * @return a {@link StashDropCommand} + * @since 2.0 */ public StashDropCommand stashDrop() { return new StashDropCommand(repo); @@ -608,6 +611,7 @@ public StashDropCommand stashDrop() { * * @return a {@link ApplyCommand} used to collect all optional parameters * and to finally execute the {@code apply} command + * @since 2.0 */ public ApplyCommand apply() { return new ApplyCommand(repo);
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseResult.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseResult.java index 4739f16..a09f8c2 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseResult.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseResult.java
@@ -113,6 +113,8 @@ public boolean isSuccessful() { /** * Continue with nothing left to commit (possibly want skip). + * + * @since 2.0 */ NOTHING_TO_COMMIT { @Override
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/StashCreateCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/StashCreateCommand.java index 104c22f..5ba6162 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/StashCreateCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/StashCreateCommand.java
@@ -85,6 +85,7 @@ * * @see <a href="http://www.kernel.org/pub/software/scm/git/docs/git-stash.html" * >Git documentation about Stash</a> + * @since 2.0 */ public class StashCreateCommand extends GitCommand<RevCommit> {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/StashDropCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/StashDropCommand.java index 85bb987..e718417 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/StashDropCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/StashDropCommand.java
@@ -69,6 +69,7 @@ * * @see <a href="http://www.kernel.org/pub/software/scm/git/docs/git-stash.html" * >Git documentation about Stash</a> + * @since 2.0 */ public class StashDropCommand extends GitCommand<ObjectId> {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/TagCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/TagCommand.java index 30d548c..c867b53 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/TagCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/TagCommand.java
@@ -105,6 +105,7 @@ protected TagCommand(Repository repo) { * exception can be retrieved by calling * {@link Exception#getCause()}. Expect only * {@code IOException's} to be wrapped. + * @since 2.0 */ public Ref call() throws JGitInternalException, ConcurrentRefUpdateException, InvalidTagNameException, NoHeadException {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/diff/DiffFormatter.java b/org.eclipse.jgit/src/org/eclipse/jgit/diff/DiffFormatter.java index e7d0213..ceb4cb0 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/diff/DiffFormatter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/diff/DiffFormatter.java
@@ -278,6 +278,7 @@ public void setOldPrefix(String prefix) { * Get the prefix applied in front of old file paths. * * @return the prefix + * @since 2.0 */ public String getOldPrefix() { return this.oldPrefix; @@ -298,8 +299,9 @@ public void setNewPrefix(String prefix) { /** * Get the prefix applied in front of new file paths. - * + * * @return the prefix + * @since 2.0 */ public String getNewPrefix() { return this.newPrefix;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/dircache/InvalidPathException.java b/org.eclipse.jgit/src/org/eclipse/jgit/dircache/InvalidPathException.java index 155519f..698636c 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/dircache/InvalidPathException.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/dircache/InvalidPathException.java
@@ -49,6 +49,8 @@ /** * Thrown when JGit detects and refuses to use an invalid path + * + * @since 2.0 */ public class InvalidPathException extends IllegalArgumentException {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/storage/dfs/InMemoryRepository.java b/org.eclipse.jgit/src/org/eclipse/jgit/storage/dfs/InMemoryRepository.java index f363fc2..fb62ace 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/storage/dfs/InMemoryRepository.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/storage/dfs/InMemoryRepository.java
@@ -34,7 +34,8 @@ public class InMemoryRepository extends DfsRepository { * Initialize a new in-memory repository. * * @param repoDesc - * description of the repository. + * description of the repository. + * @since 2.0 */ public InMemoryRepository(DfsRepositoryDescription repoDesc) { super(new DfsRepositoryBuilder<DfsRepositoryBuilder, InMemoryRepository>() {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/ReflogWriter.java b/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/ReflogWriter.java index 684e97d..d7788cd 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/ReflogWriter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/ReflogWriter.java
@@ -73,6 +73,8 @@ /** * Utility for writing reflog entries + * + * @since 2.0 */ public class ReflogWriter {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/AbstractAdvertiseRefsHook.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/AbstractAdvertiseRefsHook.java index d17e074..a13a4ff 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/AbstractAdvertiseRefsHook.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/AbstractAdvertiseRefsHook.java
@@ -53,6 +53,8 @@ /** * Implementation of {@link AdvertiseRefsHook} that advertises the same refs for * upload-pack and receive-pack. + * + * @since 2.0 */ public abstract class AbstractAdvertiseRefsHook implements AdvertiseRefsHook { public void advertiseRefs(UploadPack uploadPack)
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/AdvertiseRefsHook.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/AdvertiseRefsHook.java index f61c186..0f76f67 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/AdvertiseRefsHook.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/AdvertiseRefsHook.java
@@ -42,7 +42,11 @@ package org.eclipse.jgit.transport; -/** Hook to allow callers to take over advertising refs to the client. */ +/** + * Hook to allow callers to take over advertising refs to the client. + * + * @since 2.0 + */ public interface AdvertiseRefsHook { /** * A simple hook that advertises the default refs.
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java index 347fd93..582b75a 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackFetchConnection.java
@@ -120,34 +120,64 @@ public abstract class BasePackFetchConnection extends BasePackConnection */ protected static final int MIN_CLIENT_BUFFER = 2 * 32 * 46 + 8; - /** Include tags if we are also including the referenced objects. */ + /** + * Include tags if we are also including the referenced objects. + * @since 2.0 + */ public static final String OPTION_INCLUDE_TAG = "include-tag"; - /** Mutli-ACK support for improved negotiation. */ + /** + * Mutli-ACK support for improved negotiation. + * @since 2.0 + */ public static final String OPTION_MULTI_ACK = "multi_ack"; - /** Mutli-ACK detailed support for improved negotiation. */ + /** + * Mutli-ACK detailed support for improved negotiation. + * @since 2.0 + */ public static final String OPTION_MULTI_ACK_DETAILED = "multi_ack_detailed"; - /** The client supports packs with deltas but not their bases. */ + /** + * The client supports packs with deltas but not their bases. + * @since 2.0 + */ public static final String OPTION_THIN_PACK = "thin-pack"; - /** The client supports using the side-band for progress messages. */ + /** + * The client supports using the side-band for progress messages. + * @since 2.0 + */ public static final String OPTION_SIDE_BAND = "side-band"; - /** The client supports using the 64K side-band for progress messages. */ + /** + * The client supports using the 64K side-band for progress messages. + * @since 2.0 + */ public static final String OPTION_SIDE_BAND_64K = "side-band-64k"; - /** The client supports packs with OFS deltas. */ + /** + * The client supports packs with OFS deltas. + * @since 2.0 + */ public static final String OPTION_OFS_DELTA = "ofs-delta"; - /** The client supports shallow fetches. */ + /** + * The client supports shallow fetches. + * @since 2.0 + */ public static final String OPTION_SHALLOW = "shallow"; - /** The client does not want progress messages and will ignore them. */ + /** + * The client does not want progress messages and will ignore them. + * @since 2.0 + */ public static final String OPTION_NO_PROGRESS = "no-progress"; - /** The client supports receiving a pack before it has sent "done". */ + /** + * The client supports receiving a pack before it has sent "done". + * @since 2.0 + */ public static final String OPTION_NO_DONE = "no-done"; static enum MultiAck { @@ -695,6 +725,8 @@ private void receivePack(final ProgressMonitor monitor) throws IOException { * Notification event delivered just before the pack is received from the * network. This event can be used by RPC such as {@link TransportHttp} to * disable its request magic and ensure the pack stream is read correctly. + * + * @since 2.0 */ protected void onReceivePack() { // By default do nothing for TCP based protocols.
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackPushConnection.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackPushConnection.java index 8bf030bb..119b266 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackPushConnection.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackPushConnection.java
@@ -83,16 +83,28 @@ */ public abstract class BasePackPushConnection extends BasePackConnection implements PushConnection { - /** The client expects a status report after the server processes the pack. */ + /** + * The client expects a status report after the server processes the pack. + * @since 2.0 + */ public static final String CAPABILITY_REPORT_STATUS = "report-status"; - /** The server supports deleting refs. */ + /** + * The server supports deleting refs. + * @since 2.0 + */ public static final String CAPABILITY_DELETE_REFS = "delete-refs"; - /** The server supports packs with OFS deltas. */ + /** + * The server supports packs with OFS deltas. + * @since 2.0 + */ public static final String CAPABILITY_OFS_DELTA = "ofs-delta"; - /** The client supports using the 64K side-band for progress messages. */ + /** + * The client supports using the 64K side-band for progress messages. + * @since 2.0 + */ public static final String CAPABILITY_SIDE_BAND_64K = "side-band-64k"; private final boolean thinPack;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/ReceiveCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/ReceiveCommand.java index 0a0de5b..44cf829 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/ReceiveCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/ReceiveCommand.java
@@ -129,8 +129,9 @@ public static enum Result { * commands to filter. * @param want * desired status to filter by. - * @return a copy of the command list containing only those commands with the - * desired status. + * @return a copy of the command list containing only those commands with + * the desired status. + * @since 2.0 */ public static List<ReceiveCommand> filter(List<ReceiveCommand> commands, final Result want) { @@ -195,6 +196,7 @@ public ReceiveCommand(final ObjectId oldId, final ObjectId newId, * name of the ref being affected. * @param type * type of the command. + * @since 2.0 */ public ReceiveCommand(final ObjectId oldId, final ObjectId newId, final String name, final Type type) { @@ -269,6 +271,7 @@ public void setResult(final Result s, final String m) { * * @param rp * receive-pack session. + * @since 2.0 */ public void execute(final ReceivePack rp) { try {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/RequestNotYetReadException.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/RequestNotYetReadException.java index 4de6fa3..8b45174 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/RequestNotYetReadException.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/RequestNotYetReadException.java
@@ -43,7 +43,11 @@ package org.eclipse.jgit.transport; -/** Indicates that a client request has not yet been read from the wire. */ +/** + * Indicates that a client request has not yet been read from the wire. + * + * @since 2.0 + */ public class RequestNotYetReadException extends IllegalStateException { private static final long serialVersionUID = 1L;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/ServiceMayNotContinueException.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/ServiceMayNotContinueException.java index bf85068..86f6446 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/ServiceMayNotContinueException.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/ServiceMayNotContinueException.java
@@ -45,7 +45,11 @@ import java.io.IOException; -/** Indicates a transport service may not continue execution. */ +/** + * Indicates a transport service may not continue execution. + * + * @since 2.0 + */ public class ServiceMayNotContinueException extends IOException { private static final long serialVersionUID = 1L;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/SideBandOutputStream.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/SideBandOutputStream.java index 8fe78b6..770fcbe 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/SideBandOutputStream.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/SideBandOutputStream.java
@@ -54,6 +54,8 @@ * <p> * This stream is buffered at packet sizes, so the caller doesn't need to wrap * it in yet another buffered stream. + * + * @since 2.0 */ public class SideBandOutputStream extends OutputStream { /** Channel used for pack data. */
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/AbstractTreeIterator.java b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/AbstractTreeIterator.java index ca5fec2..752f20b 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/AbstractTreeIterator.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/AbstractTreeIterator.java
@@ -651,6 +651,7 @@ public int getNameLength() { * JGit internal API for use by {@link DirCacheCheckout} * * @return start of name component part within {@link #getEntryPathBuffer()} + * @since 2.0 */ public int getNameOffset() { return pathOffset;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/FileUtils.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/FileUtils.java index 6043638..11215c8 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/util/FileUtils.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/FileUtils.java
@@ -79,6 +79,7 @@ public class FileUtils { /** * Option not to throw exceptions when a deletion finally doesn't succeed. + * @since 2.0 */ public static final int IGNORE_ERRORS = 8;
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/IO.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/IO.java index 910d982..4abe4a8 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/util/IO.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/IO.java
@@ -339,6 +339,7 @@ public static void skipFully(final InputStream fd, long toSkip) * @param s * the string to read * @return the string divided into lines + * @since 2.0 */ public static List<String> readLines(final String s) { List<String> l = new ArrayList<String>();
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/StringUtils.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/StringUtils.java index f423f98..efb9abd 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/util/StringUtils.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/StringUtils.java
@@ -132,6 +132,7 @@ public static boolean equalsIgnoreCase(final String a, final String b) { * second string to compare. * @return negative, zero or positive if a sorts before, is equal to, or * sorts after b. + * @since 2.0 */ public static int compareIgnoreCase(String a, String b) { for (int i = 0; i < a.length() && i < b.length(); i++) { @@ -154,6 +155,7 @@ public static int compareIgnoreCase(String a, String b) { * second string to compare. * @return negative, zero or positive if a sorts before, is equal to, or * sorts after b. + * @since 2.0 */ public static int compareWithCase(String a, String b) { for (int i = 0; i < a.length() && i < b.length(); i++) {
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/io/EolCanonicalizingInputStream.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/io/EolCanonicalizingInputStream.java index 954c646..5921836 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/util/io/EolCanonicalizingInputStream.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/io/EolCanonicalizingInputStream.java
@@ -72,11 +72,12 @@ public class EolCanonicalizingInputStream extends InputStream { /** * Creates a new InputStream, wrapping the specified stream - * + * * @param in * raw input stream * @param detectBinary * whether binaries should be detected + * @since 2.0 */ public EolCanonicalizingInputStream(InputStream in, boolean detectBinary) { this.in = in;