Skip to content

Commit 80d7a5c

Browse files
author
Caitlin Bales (MSFT)
authored
Merge pull request #57 from microsoftgraph/javadoc-cleanup
Javadoc cleanup
2 parents eea3103 + ee8f316 commit 80d7a5c

File tree

5,192 files changed

+34638
-27501
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

5,192 files changed

+34638
-27501
lines changed

src/main/java/com/microsoft/graph/authentication/IAuthenticationProvider.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,14 @@
2525
import com.microsoft.graph.http.IHttpRequest;
2626

2727
/**
28-
* Provides authentication for a requests before it is sent by an HTTP provider.
28+
* Provides authentication for a requests before it is sent by an HTTP provider
2929
*/
3030
public interface IAuthenticationProvider {
3131

3232
/**
33-
* Authenticates the request.
34-
* @param request The request to authenticate.
33+
* Authenticates the request
34+
*
35+
* @param request the request to authenticate
3536
*/
3637
void authenticateRequest(final IHttpRequest request);
3738
}

src/main/java/com/microsoft/graph/concurrency/ChunkedUploadProvider.java

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@
3737
import java.util.List;
3838

3939
/**
40-
* ChunkedUpload service provider.
40+
* ChunkedUpload service provider
4141
*
42-
* @param <UploadType> The upload item type.
42+
* @param <UploadType> the upload item type
4343
*/
4444
public class ChunkedUploadProvider<UploadType> {
4545

@@ -49,7 +49,7 @@ public class ChunkedUploadProvider<UploadType> {
4949
private static final int DEFAULT_CHUNK_SIZE = 5 * 1024 * 1024;
5050

5151
/**
52-
* The required chunk size increment by OneDrive service, which is 320 KiB.
52+
* The required chunk size increment by OneDrive service, which is 320 KiB
5353
*/
5454
private static final int REQUIRED_CHUNK_SIZE_INCREMENT = 320 * 1024;
5555

@@ -60,48 +60,48 @@ public class ChunkedUploadProvider<UploadType> {
6060
private static final int MAXIMUM_CHUNK_SIZE = 60 * 1024 * 1024;
6161

6262
/**
63-
* The default retry times for a simple chunk upload if failure happened.
63+
* The default retry times for a simple chunk upload if failure happened
6464
*/
6565
private static final int MAXIMUM_RETRY_TIMES = 3;
6666

6767
/**
68-
* The client.
68+
* The client
6969
*/
7070
private final IGraphServiceClient client;
7171

7272
/**
73-
* The input stream.
73+
* The input stream
7474
*/
7575
private final InputStream inputStream;
7676

7777
/**
78-
* The upload session URL.
78+
* The upload session URL
7979
*/
8080
private final String uploadUrl;
8181

8282
/**
83-
* The stream size.
83+
* The stream size
8484
*/
8585
private final int streamSize;
8686

8787
/**
88-
* The upload response handler.
88+
* The upload response handler
8989
*/
9090
private final ChunkedUploadResponseHandler<UploadType> responseHandler;
9191

9292
/**
93-
* The counter for how many bytes have been read from input stream.
93+
* The counter for how many bytes have been read from input stream
9494
*/
9595
private int readSoFar;
9696

9797
/**
98-
* Create the ChunkedUploadProvider
98+
* Creates the ChunkedUploadProvider
9999
*
100-
* @param uploadSession The initial upload session.
101-
* @param client The OneDrive client.
102-
* @param inputStream The input stream.
103-
* @param streamSize The stream size.
104-
* @param uploadTypeClass The upload type class.
100+
* @param uploadSession the initial upload session
101+
* @param client the Graph client
102+
* @param inputStream the input stream
103+
* @param streamSize the stream size
104+
* @param uploadTypeClass the upload type class
105105
*/
106106
public ChunkedUploadProvider(final UploadSession uploadSession,
107107
final IGraphServiceClient client,
@@ -133,13 +133,13 @@ public ChunkedUploadProvider(final UploadSession uploadSession,
133133
}
134134

135135
/**
136-
* Upload content to remote upload session based on the input stream.
136+
* Uploads content to remote upload session based on the input stream
137137
*
138-
* @param options The upload options.
139-
* @param callback The progress callback invoked during uploading.
140-
* @param configs The optional configurations for the upload options, [0] should be the customized chunk
141-
* size and the [1] should be the maxRetry for upload retry.
142-
* @throws IOException The IO exception happened during upload.
138+
* @param options the upload options
139+
* @param callback the progress callback invoked during uploading
140+
* @param configs the optional configurations for the upload options. [0] should be the customized chunk
141+
* size and [1] should be the maxRetry for upload retry.
142+
* @throws IOException the IO exception that occurred during upload
143143
*/
144144
public void upload(final List<Option> options,
145145
final IProgressCallback<UploadType> callback,

src/main/java/com/microsoft/graph/concurrency/ChunkedUploadResponseHandler.java

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -37,45 +37,45 @@
3737
import java.io.InputStream;
3838

3939
/**
40-
* The class handles the stateful response from OneDrive upload session.
40+
* Handles the stateful response from the OneDrive upload session
4141
*
42-
* @param <UploadType> The expected uploaded item.
42+
* @param <UploadType> the expected uploaded item
4343
*/
4444
public class ChunkedUploadResponseHandler<UploadType>
4545
implements IStatefulResponseHandler<ChunkedUploadResult, UploadType> {
4646
/**
47-
* The expected deserialize type for upload type.
47+
* The expected deserialized upload type
4848
*/
4949
private final Class<UploadType> deserializeTypeClass;
5050

5151
/**
52-
* Create a chunked upload response handler.
52+
* Creates a chunked upload response handler
5353
*
54-
* @param uploadType The expected upload item type.
54+
* @param uploadType the expected upload item type
5555
*/
5656
public ChunkedUploadResponseHandler(final Class<UploadType> uploadType) {
5757
this.deserializeTypeClass = uploadType;
5858
}
5959

6060
/**
61-
* Do nothing before get response.
61+
* Do nothing before getting the response
6262
*
63-
* @param connection The connection.
63+
* @param connection the connection
6464
*/
6565
@Override
6666
public void configConnection(final IConnection connection) {
6767
return;
6868
}
6969

7070
/**
71-
* Generate the chunked upload response result.
71+
* Generate the chunked upload response result
7272
*
73-
* @param request The HTTP request.
74-
* @param connection The HTTP connection.
75-
* @param serializer The serializer.
76-
* @param logger The system logger.
77-
* @return The chunked upload result which could be upload session/uploaded item or error.
78-
* @throws Exception An exception occurs if the request was unable to complete for any reason.
73+
* @param request the HTTP request
74+
* @param connection the HTTP connection
75+
* @param serializer the serializer
76+
* @param logger the system logger
77+
* @return the chunked upload result, which could be either an uploaded item or error
78+
* @throws Exception an exception occurs if the request was unable to complete for any reason
7979
*/
8080
@Override
8181
public ChunkedUploadResult<UploadType> generateResult(

src/main/java/com/microsoft/graph/concurrency/DefaultExecutors.java

Lines changed: 26 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -29,28 +29,29 @@
2929
import java.util.concurrent.ThreadPoolExecutor;
3030

3131
/**
32-
* The default executors implementation for the SDK.
32+
* The default executors implementation for the SDK
3333
*/
3434
public class DefaultExecutors implements IExecutors {
3535

3636
/**
37-
* The executor for handling background actions.
37+
* The executor for handling background actions
3838
*/
3939
private final ThreadPoolExecutor backgroundExecutor;
4040

4141
/**
42-
* The executor for handling foreground actions.
42+
* The executor for handling foreground actions
4343
*/
4444
private final SynchronousExecutor foregroundExecutor;
4545

4646
/**
47-
* The logger.
47+
* The logger
4848
*/
4949
private final ILogger logger;
5050

5151
/**
52-
* Creates a new instance of the DefaultExecutors.
53-
* @param logger The logger.
52+
* Creates a new instance of the DefaultExecutors
53+
*
54+
* @param logger the logger
5455
*/
5556
public DefaultExecutors(final ILogger logger) {
5657
this.logger = logger;
@@ -59,8 +60,9 @@ public DefaultExecutors(final ILogger logger) {
5960
}
6061

6162
/**
62-
* Runs the given Runnable on the background thread.
63-
* @param runnable The Runnable to execute.
63+
* Runs the given Runnable on the background thread
64+
*
65+
* @param runnable the Runnable to execute
6466
*/
6567
@Override
6668
public void performOnBackground(final Runnable runnable) {
@@ -70,10 +72,11 @@ public void performOnBackground(final Runnable runnable) {
7072
}
7173

7274
/**
73-
* Performs the given callback with the result object.
74-
* @param result The result value.
75-
* @param callback The callback to call on the foreground with this result.
76-
* @param <Result> The result type.
75+
* Performs the given callback with the result object
76+
*
77+
* @param result the result value
78+
* @param callback the callback to call on the foreground with this result
79+
* @param <Result> the result type
7780
*/
7881
@Override
7982
public <Result> void performOnForeground(final Result result,
@@ -91,11 +94,12 @@ public void run() {
9194
}
9295

9396
/**
94-
* Performs the given callback with the result object.
95-
* @param progress The progress value.
96-
* @param progressMax The progress value.
97-
* @param callback The callback to call on the foreground with this result.
98-
* @param <Result> The result type.
97+
* Performs the given callback with the result object
98+
*
99+
* @param progress the progress value
100+
* @param progressMax the progress value
101+
* @param callback the callback to call on the foreground with this result
102+
* @param <Result> the result type
99103
*/
100104
public <Result> void performOnForeground(final int progress,
101105
final int progressMax,
@@ -114,10 +118,11 @@ public void run() {
114118
});
115119
}
116120
/**
117-
* Performs the given callback with the exception object.
118-
* @param exception The exception value.
119-
* @param callback The callback to call on the foreground with this exception.
120-
* @param <Result> The result type.
121+
* Performs the given callback with the exception object
122+
*
123+
* @param exception the exception value
124+
* @param callback the callback to call on the foreground with this exception
125+
* @param <Result> the result type
121126
*/
122127
@Override
123128
public <Result> void performOnForeground(final ClientException exception,

src/main/java/com/microsoft/graph/concurrency/ICallback.java

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,19 +25,22 @@
2525
import com.microsoft.graph.core.ClientException;
2626

2727
/**
28-
* A callback that describes how to deal with success and failure.
29-
* @param <Result> The result type of the successful action.
28+
* A callback that describes how to deal with success and failure
29+
*
30+
* @param <Result> the result type of the successful action
3031
*/
3132
public interface ICallback<Result> {
3233
/**
33-
* How successful results are handled.
34-
* @param result The result.
34+
* How successful results are handled
35+
*
36+
* @param result the result
3537
*/
3638
void success(final Result result);
3739

3840
/**
39-
* How failures are handled.
40-
* @param ex The exception.
41+
* How failures are handled
42+
*
43+
* @param ex the exception
4144
*/
4245
void failure(final ClientException ex);
4346
}

src/main/java/com/microsoft/graph/concurrency/IExecutors.java

Lines changed: 20 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -25,41 +25,45 @@
2525
import com.microsoft.graph.core.ClientException;
2626

2727
/**
28-
* A way to manage scheduled actions that are run in the foreground or background threading environments.
28+
* A way to manage scheduled actions that are run in the foreground or background threading environments
2929
*/
3030
public interface IExecutors {
3131

3232
/**
33-
* Runs the given Runnable on the background thread.
34-
* @param runnable The Runnable to execute.
33+
* Runs the given Runnable on the background thread
34+
*
35+
* @param runnable the Runnable to execute
3536
*/
3637
void performOnBackground(final Runnable runnable);
3738

3839
/**
39-
* Performs the given callback with the result object.
40-
* @param result The result value.
41-
* @param callback The callback to call on the foreground with this result.
42-
* @param <Result> The result type.
40+
* Performs the given callback with the result object
41+
*
42+
* @param result the result value
43+
* @param callback the callback to call on the foreground with this result
44+
* @param <Result> the result type
4345
*/
4446
<Result> void performOnForeground(final Result result,
4547
final ICallback<Result> callback);
4648

4749
/**
48-
* Performs the given callback with the result object.
49-
* @param progress The progress value.
50-
* @param progressMax The progress value.
51-
* @param callback The callback to call on the foreground with this result.
52-
* @param <Result> The result type.
50+
* Performs the given callback with the result object
51+
*
52+
* @param progress the progress value
53+
* @param progressMax the max progress value
54+
* @param callback the callback to call on the foreground with this result
55+
* @param <Result> the result type
5356
*/
5457
<Result> void performOnForeground(final int progress,
5558
final int progressMax,
5659
final IProgressCallback<Result> callback);
5760

5861
/**
59-
* Performs the given callback with the exception object.
60-
* @param exception The exception value.
61-
* @param callback The callback to call on the foreground with this exception.
62-
* @param <Result> The result type.
62+
* Performs the given callback with the exception object
63+
*
64+
* @param exception the exception value
65+
* @param callback the callback to call on the foreground with this exception
66+
* @param <Result> the result type
6367
*/
6468
<Result> void performOnForeground(final ClientException exception,
6569
final ICallback<Result> callback);

src/main/java/com/microsoft/graph/concurrency/IProgressCallback.java

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,17 @@
2323
package com.microsoft.graph.concurrency;
2424

2525
/**
26-
* A callback that describes how to deal with success, failure, and progress.
27-
* @param <Result> The result type of the successful action.
26+
* A callback that describes how to deal with success, failure, and progress
27+
*
28+
* @param <Result> the result type of the successful action
2829
*/
2930
public interface IProgressCallback<Result> extends ICallback<Result> {
3031

3132
/**
32-
* How progress updates are handled for this callback.
33-
* @param current The current amount of progress.
34-
* @param max The max amount of progress.
33+
* How progress updates are handled for this callback
34+
*
35+
* @param current the current amount of progress
36+
* @param max the max amount of progress
3537
*/
3638
void progress(final long current, final long max);
3739
}

0 commit comments

Comments
 (0)