Skip to content

Commit

Permalink
Add javadoc
Browse files Browse the repository at this point in the history
  • Loading branch information
Mykola Mokhnach committed Jan 20, 2018
1 parent 2af7733 commit 0d3dee5
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ public T withUploadOptions(ScreenRecordingUploadOptions uploadOptions) {
return (T) this;
}

/**
* Builds a map, which is ready to be passed to the subordinated
* Appium API.
*
* @return arguments mapping.
*/
public Map<String, Object> build() {
final ImmutableMap.Builder<String, Object> builder = ImmutableMap.builder();
//noinspection unchecked
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,11 @@ default <T extends BaseStartScreenRecordingOptions> String startRecordingScreen(
return CommandExecutionHelper.execute(this, startRecordingScreenCommand(options));
}

/**
* Start asynchronous screen recording process with default options.
*
* @return Base-64 encoded content of the recorded media file.
*/
default String startRecordingScreen() {
return this.execute(START_RECORDING_SCREEN).getValue().toString();
}
Expand All @@ -55,6 +60,12 @@ default <T extends BaseStopScreenRecordingOptions> String stopRecordingScreen(T
return CommandExecutionHelper.execute(this, stopRecordingScreenCommand(options));
}

/**
* Gather the output from the previously started screen recording to a media file
* with default options.
*
* @return Base-64 encoded content of the recorded media file.
*/
default String stopRecordingScreen() {
return this.execute(STOP_RECORDING_SCREEN).getValue().toString();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,12 @@ public ScreenRecordingUploadOptions withHttpMethod(RequestMethod method) {
return this;
}

/**
* Builds a map, which is ready to be passed to the subordinated
* Appium API.
*
* @return arguments mapping.
*/
public Map<String, Object> build() {
final ImmutableMap.Builder<String, Object> builder = ImmutableMap.builder();
ofNullable(remotePath).map(x -> builder.put("remotePath", x));
Expand Down

0 comments on commit 0d3dee5

Please sign in to comment.