@Generated(value="software.amazon.awssdk:codegen") public interface MediaLiveAsyncClient extends SdkClient, SdkAutoCloseable
builder()
method.
API for AWS Elemental MediaLiveModifier and Type | Field and Description |
---|---|
static String |
SERVICE_NAME |
Modifier and Type | Method and Description |
---|---|
static MediaLiveAsyncClientBuilder |
builder()
Create a builder that can be used to configure and create a
MediaLiveAsyncClient . |
static MediaLiveAsyncClient |
create()
Create a
MediaLiveAsyncClient with the region loaded from the
DefaultAwsRegionProviderChain and credentials loaded from
the DefaultCredentialsProvider . |
default CompletableFuture<CreateChannelResponse> |
createChannel(Consumer<CreateChannelRequest.Builder> createChannelRequest)
Creates a new channel
This is a convenience which creates an instance of the CreateChannelRequest.Builder avoiding the need to
create one manually via CreateChannelRequest.builder() |
default CompletableFuture<CreateChannelResponse> |
createChannel(CreateChannelRequest createChannelRequest)
Creates a new channel
|
default CompletableFuture<CreateInputResponse> |
createInput(Consumer<CreateInputRequest.Builder> createInputRequest)
Create an input
This is a convenience which creates an instance of the CreateInputRequest.Builder avoiding the need to
create one manually via CreateInputRequest.builder() |
default CompletableFuture<CreateInputResponse> |
createInput(CreateInputRequest createInputRequest)
Create an input
|
default CompletableFuture<CreateInputSecurityGroupResponse> |
createInputSecurityGroup(Consumer<CreateInputSecurityGroupRequest.Builder> createInputSecurityGroupRequest)
Creates a Input Security Group
This is a convenience which creates an instance of the CreateInputSecurityGroupRequest.Builder avoiding
the need to create one manually via CreateInputSecurityGroupRequest.builder() |
default CompletableFuture<CreateInputSecurityGroupResponse> |
createInputSecurityGroup(CreateInputSecurityGroupRequest createInputSecurityGroupRequest)
Creates a Input Security Group
|
default CompletableFuture<DeleteChannelResponse> |
deleteChannel(Consumer<DeleteChannelRequest.Builder> deleteChannelRequest)
Starts deletion of channel.
|
default CompletableFuture<DeleteChannelResponse> |
deleteChannel(DeleteChannelRequest deleteChannelRequest)
Starts deletion of channel.
|
default CompletableFuture<DeleteInputResponse> |
deleteInput(Consumer<DeleteInputRequest.Builder> deleteInputRequest)
Deletes the input end point
This is a convenience which creates an instance of the DeleteInputRequest.Builder avoiding the need to
create one manually via DeleteInputRequest.builder() |
default CompletableFuture<DeleteInputResponse> |
deleteInput(DeleteInputRequest deleteInputRequest)
Deletes the input end point
|
default CompletableFuture<DeleteInputSecurityGroupResponse> |
deleteInputSecurityGroup(Consumer<DeleteInputSecurityGroupRequest.Builder> deleteInputSecurityGroupRequest)
Deletes an Input Security Group
This is a convenience which creates an instance of the DeleteInputSecurityGroupRequest.Builder avoiding
the need to create one manually via DeleteInputSecurityGroupRequest.builder() |
default CompletableFuture<DeleteInputSecurityGroupResponse> |
deleteInputSecurityGroup(DeleteInputSecurityGroupRequest deleteInputSecurityGroupRequest)
Deletes an Input Security Group
|
default CompletableFuture<DescribeChannelResponse> |
describeChannel(Consumer<DescribeChannelRequest.Builder> describeChannelRequest)
Gets details about a channel
This is a convenience which creates an instance of the DescribeChannelRequest.Builder avoiding the need
to create one manually via DescribeChannelRequest.builder() |
default CompletableFuture<DescribeChannelResponse> |
describeChannel(DescribeChannelRequest describeChannelRequest)
Gets details about a channel
|
default CompletableFuture<DescribeInputResponse> |
describeInput(Consumer<DescribeInputRequest.Builder> describeInputRequest)
Produces details about an input
This is a convenience which creates an instance of the DescribeInputRequest.Builder avoiding the need to
create one manually via DescribeInputRequest.builder() |
default CompletableFuture<DescribeInputResponse> |
describeInput(DescribeInputRequest describeInputRequest)
Produces details about an input
|
default CompletableFuture<DescribeInputSecurityGroupResponse> |
describeInputSecurityGroup(Consumer<DescribeInputSecurityGroupRequest.Builder> describeInputSecurityGroupRequest)
Produces a summary of an Input Security Group
This is a convenience which creates an instance of the DescribeInputSecurityGroupRequest.Builder avoiding
the need to create one manually via DescribeInputSecurityGroupRequest.builder() |
default CompletableFuture<DescribeInputSecurityGroupResponse> |
describeInputSecurityGroup(DescribeInputSecurityGroupRequest describeInputSecurityGroupRequest)
Produces a summary of an Input Security Group
|
default CompletableFuture<ListChannelsResponse> |
listChannels()
Produces list of channels that have been created
|
default CompletableFuture<ListChannelsResponse> |
listChannels(Consumer<ListChannelsRequest.Builder> listChannelsRequest)
Produces list of channels that have been created
This is a convenience which creates an instance of the ListChannelsRequest.Builder avoiding the need to
create one manually via ListChannelsRequest.builder() |
default CompletableFuture<ListChannelsResponse> |
listChannels(ListChannelsRequest listChannelsRequest)
Produces list of channels that have been created
|
default ListChannelsPublisher |
listChannelsPaginator()
Produces list of channels that have been created
|
default ListChannelsPublisher |
listChannelsPaginator(ListChannelsRequest listChannelsRequest)
Produces list of channels that have been created
|
default CompletableFuture<ListInputsResponse> |
listInputs()
Produces list of inputs that have been created
|
default CompletableFuture<ListInputsResponse> |
listInputs(Consumer<ListInputsRequest.Builder> listInputsRequest)
Produces list of inputs that have been created
This is a convenience which creates an instance of the ListInputsRequest.Builder avoiding the need to
create one manually via ListInputsRequest.builder() |
default CompletableFuture<ListInputsResponse> |
listInputs(ListInputsRequest listInputsRequest)
Produces list of inputs that have been created
|
default CompletableFuture<ListInputSecurityGroupsResponse> |
listInputSecurityGroups()
Produces a list of Input Security Groups for an account
|
default CompletableFuture<ListInputSecurityGroupsResponse> |
listInputSecurityGroups(Consumer<ListInputSecurityGroupsRequest.Builder> listInputSecurityGroupsRequest)
Produces a list of Input Security Groups for an account
This is a convenience which creates an instance of the ListInputSecurityGroupsRequest.Builder avoiding
the need to create one manually via ListInputSecurityGroupsRequest.builder() |
default CompletableFuture<ListInputSecurityGroupsResponse> |
listInputSecurityGroups(ListInputSecurityGroupsRequest listInputSecurityGroupsRequest)
Produces a list of Input Security Groups for an account
|
default ListInputSecurityGroupsPublisher |
listInputSecurityGroupsPaginator()
Produces a list of Input Security Groups for an account
|
default ListInputSecurityGroupsPublisher |
listInputSecurityGroupsPaginator(ListInputSecurityGroupsRequest listInputSecurityGroupsRequest)
Produces a list of Input Security Groups for an account
|
default ListInputsPublisher |
listInputsPaginator()
Produces list of inputs that have been created
|
default ListInputsPublisher |
listInputsPaginator(ListInputsRequest listInputsRequest)
Produces list of inputs that have been created
|
default CompletableFuture<StartChannelResponse> |
startChannel(Consumer<StartChannelRequest.Builder> startChannelRequest)
Starts an existing channel
This is a convenience which creates an instance of the StartChannelRequest.Builder avoiding the need to
create one manually via StartChannelRequest.builder() |
default CompletableFuture<StartChannelResponse> |
startChannel(StartChannelRequest startChannelRequest)
Starts an existing channel
|
default CompletableFuture<StopChannelResponse> |
stopChannel(Consumer<StopChannelRequest.Builder> stopChannelRequest)
Stops a running channel
This is a convenience which creates an instance of the StopChannelRequest.Builder avoiding the need to
create one manually via StopChannelRequest.builder() |
default CompletableFuture<StopChannelResponse> |
stopChannel(StopChannelRequest stopChannelRequest)
Stops a running channel
|
serviceName
close
static final String SERVICE_NAME
static MediaLiveAsyncClient create()
MediaLiveAsyncClient
with the region loaded from the
DefaultAwsRegionProviderChain
and credentials loaded from
the DefaultCredentialsProvider
.static MediaLiveAsyncClientBuilder builder()
MediaLiveAsyncClient
.default CompletableFuture<CreateChannelResponse> createChannel(CreateChannelRequest createChannelRequest)
createChannelRequest
- A request to create a channeldefault CompletableFuture<CreateChannelResponse> createChannel(Consumer<CreateChannelRequest.Builder> createChannelRequest)
CreateChannelRequest.Builder
avoiding the need to
create one manually via CreateChannelRequest.builder()
createChannelRequest
- a Consumer
that will call methods on CreateChannelRequest.Builder
.default CompletableFuture<CreateInputResponse> createInput(CreateInputRequest createInputRequest)
createInputRequest
- The name of the inputdefault CompletableFuture<CreateInputResponse> createInput(Consumer<CreateInputRequest.Builder> createInputRequest)
CreateInputRequest.Builder
avoiding the need to
create one manually via CreateInputRequest.builder()
createInputRequest
- a Consumer
that will call methods on CreateInputRequest.Builder
.default CompletableFuture<CreateInputSecurityGroupResponse> createInputSecurityGroup(CreateInputSecurityGroupRequest createInputSecurityGroupRequest)
createInputSecurityGroupRequest
- The IPv4 CIDRs to whitelist for this Input Security Groupdefault CompletableFuture<CreateInputSecurityGroupResponse> createInputSecurityGroup(Consumer<CreateInputSecurityGroupRequest.Builder> createInputSecurityGroupRequest)
CreateInputSecurityGroupRequest.Builder
avoiding
the need to create one manually via CreateInputSecurityGroupRequest.builder()
createInputSecurityGroupRequest
- a Consumer
that will call methods on CreateInputSecurityGroupRequest.Builder
.default CompletableFuture<DeleteChannelResponse> deleteChannel(DeleteChannelRequest deleteChannelRequest)
deleteChannelRequest
- Placeholder documentation for DeleteChannelRequestdefault CompletableFuture<DeleteChannelResponse> deleteChannel(Consumer<DeleteChannelRequest.Builder> deleteChannelRequest)
DeleteChannelRequest.Builder
avoiding the need to
create one manually via DeleteChannelRequest.builder()
deleteChannelRequest
- a Consumer
that will call methods on DeleteChannelRequest.Builder
.default CompletableFuture<DeleteInputResponse> deleteInput(DeleteInputRequest deleteInputRequest)
deleteInputRequest
- Placeholder documentation for DeleteInputRequestdefault CompletableFuture<DeleteInputResponse> deleteInput(Consumer<DeleteInputRequest.Builder> deleteInputRequest)
DeleteInputRequest.Builder
avoiding the need to
create one manually via DeleteInputRequest.builder()
deleteInputRequest
- a Consumer
that will call methods on DeleteInputRequest.Builder
.default CompletableFuture<DeleteInputSecurityGroupResponse> deleteInputSecurityGroup(DeleteInputSecurityGroupRequest deleteInputSecurityGroupRequest)
deleteInputSecurityGroupRequest
- Placeholder documentation for DeleteInputSecurityGroupRequestdefault CompletableFuture<DeleteInputSecurityGroupResponse> deleteInputSecurityGroup(Consumer<DeleteInputSecurityGroupRequest.Builder> deleteInputSecurityGroupRequest)
DeleteInputSecurityGroupRequest.Builder
avoiding
the need to create one manually via DeleteInputSecurityGroupRequest.builder()
deleteInputSecurityGroupRequest
- a Consumer
that will call methods on DeleteInputSecurityGroupRequest.Builder
.default CompletableFuture<DescribeChannelResponse> describeChannel(DescribeChannelRequest describeChannelRequest)
describeChannelRequest
- Placeholder documentation for DescribeChannelRequestdefault CompletableFuture<DescribeChannelResponse> describeChannel(Consumer<DescribeChannelRequest.Builder> describeChannelRequest)
DescribeChannelRequest.Builder
avoiding the need
to create one manually via DescribeChannelRequest.builder()
describeChannelRequest
- a Consumer
that will call methods on DescribeChannelRequest.Builder
.default CompletableFuture<DescribeInputResponse> describeInput(DescribeInputRequest describeInputRequest)
describeInputRequest
- Placeholder documentation for DescribeInputRequestdefault CompletableFuture<DescribeInputResponse> describeInput(Consumer<DescribeInputRequest.Builder> describeInputRequest)
DescribeInputRequest.Builder
avoiding the need to
create one manually via DescribeInputRequest.builder()
describeInputRequest
- a Consumer
that will call methods on DescribeInputRequest.Builder
.default CompletableFuture<DescribeInputSecurityGroupResponse> describeInputSecurityGroup(DescribeInputSecurityGroupRequest describeInputSecurityGroupRequest)
describeInputSecurityGroupRequest
- Placeholder documentation for DescribeInputSecurityGroupRequestdefault CompletableFuture<DescribeInputSecurityGroupResponse> describeInputSecurityGroup(Consumer<DescribeInputSecurityGroupRequest.Builder> describeInputSecurityGroupRequest)
DescribeInputSecurityGroupRequest.Builder
avoiding
the need to create one manually via DescribeInputSecurityGroupRequest.builder()
describeInputSecurityGroupRequest
- a Consumer
that will call methods on DescribeInputSecurityGroupRequest.Builder
.default CompletableFuture<ListChannelsResponse> listChannels(ListChannelsRequest listChannelsRequest)
listChannelsRequest
- Placeholder documentation for ListChannelsRequestdefault CompletableFuture<ListChannelsResponse> listChannels()
default CompletableFuture<ListChannelsResponse> listChannels(Consumer<ListChannelsRequest.Builder> listChannelsRequest)
ListChannelsRequest.Builder
avoiding the need to
create one manually via ListChannelsRequest.builder()
listChannelsRequest
- a Consumer
that will call methods on ListChannelsRequest.Builder
.default ListChannelsPublisher listChannelsPaginator(ListChannelsRequest listChannelsRequest)
This is a variant of listChannels(software.amazon.awssdk.services.medialive.model.ListChannelsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe
method will result in a new Subscription
i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the forEach helper method
software.amazon.awssdk.services.medialive.paginators.ListChannelsPublisher publisher = client.listChannelsPaginator(request);
CompletableFuture<Void> future = publisher.forEach(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.medialive.paginators.ListChannelsPublisher publisher = client.listChannelsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.medialive.model.ListChannelsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.medialive.model.ListChannelsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Note: If you prefer to have control on service calls, use the
listChannels(software.amazon.awssdk.services.medialive.model.ListChannelsRequest)
operation.
listChannelsRequest
- Placeholder documentation for ListChannelsRequestdefault ListChannelsPublisher listChannelsPaginator()
This is a variant of listChannels(software.amazon.awssdk.services.medialive.model.ListChannelsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe
method will result in a new Subscription
i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the forEach helper method
software.amazon.awssdk.services.medialive.paginators.ListChannelsPublisher publisher = client.listChannelsPaginator(request);
CompletableFuture<Void> future = publisher.forEach(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.medialive.paginators.ListChannelsPublisher publisher = client.listChannelsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.medialive.model.ListChannelsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.medialive.model.ListChannelsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Note: If you prefer to have control on service calls, use the
listChannels(software.amazon.awssdk.services.medialive.model.ListChannelsRequest)
operation.
default CompletableFuture<ListInputSecurityGroupsResponse> listInputSecurityGroups(ListInputSecurityGroupsRequest listInputSecurityGroupsRequest)
listInputSecurityGroupsRequest
- Placeholder documentation for ListInputSecurityGroupsRequestdefault CompletableFuture<ListInputSecurityGroupsResponse> listInputSecurityGroups()
default CompletableFuture<ListInputSecurityGroupsResponse> listInputSecurityGroups(Consumer<ListInputSecurityGroupsRequest.Builder> listInputSecurityGroupsRequest)
ListInputSecurityGroupsRequest.Builder
avoiding
the need to create one manually via ListInputSecurityGroupsRequest.builder()
listInputSecurityGroupsRequest
- a Consumer
that will call methods on ListInputSecurityGroupsRequest.Builder
.default ListInputSecurityGroupsPublisher listInputSecurityGroupsPaginator(ListInputSecurityGroupsRequest listInputSecurityGroupsRequest)
This is a variant of
listInputSecurityGroups(software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe
method will result in a new Subscription
i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the forEach helper method
software.amazon.awssdk.services.medialive.paginators.ListInputSecurityGroupsPublisher publisher = client.listInputSecurityGroupsPaginator(request);
CompletableFuture<Void> future = publisher.forEach(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.medialive.paginators.ListInputSecurityGroupsPublisher publisher = client.listInputSecurityGroupsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Note: If you prefer to have control on service calls, use the
listInputSecurityGroups(software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsRequest)
operation.
listInputSecurityGroupsRequest
- Placeholder documentation for ListInputSecurityGroupsRequestdefault ListInputSecurityGroupsPublisher listInputSecurityGroupsPaginator()
This is a variant of
listInputSecurityGroups(software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe
method will result in a new Subscription
i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the forEach helper method
software.amazon.awssdk.services.medialive.paginators.ListInputSecurityGroupsPublisher publisher = client.listInputSecurityGroupsPaginator(request);
CompletableFuture<Void> future = publisher.forEach(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.medialive.paginators.ListInputSecurityGroupsPublisher publisher = client.listInputSecurityGroupsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Note: If you prefer to have control on service calls, use the
listInputSecurityGroups(software.amazon.awssdk.services.medialive.model.ListInputSecurityGroupsRequest)
operation.
default CompletableFuture<ListInputsResponse> listInputs(ListInputsRequest listInputsRequest)
listInputsRequest
- Placeholder documentation for ListInputsRequestdefault CompletableFuture<ListInputsResponse> listInputs()
default CompletableFuture<ListInputsResponse> listInputs(Consumer<ListInputsRequest.Builder> listInputsRequest)
ListInputsRequest.Builder
avoiding the need to
create one manually via ListInputsRequest.builder()
listInputsRequest
- a Consumer
that will call methods on ListInputsRequest.Builder
.default ListInputsPublisher listInputsPaginator(ListInputsRequest listInputsRequest)
This is a variant of listInputs(software.amazon.awssdk.services.medialive.model.ListInputsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe
method will result in a new Subscription
i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the forEach helper method
software.amazon.awssdk.services.medialive.paginators.ListInputsPublisher publisher = client.listInputsPaginator(request);
CompletableFuture<Void> future = publisher.forEach(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.medialive.paginators.ListInputsPublisher publisher = client.listInputsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.medialive.model.ListInputsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.medialive.model.ListInputsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Note: If you prefer to have control on service calls, use the
listInputs(software.amazon.awssdk.services.medialive.model.ListInputsRequest)
operation.
listInputsRequest
- Placeholder documentation for ListInputsRequestdefault ListInputsPublisher listInputsPaginator()
This is a variant of listInputs(software.amazon.awssdk.services.medialive.model.ListInputsRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages.
SDK will internally handle making service calls for you.
When the operation is called, an instance of this class is returned. At this point, no service calls are made yet
and so there is no guarantee that the request is valid. If there are errors in your request, you will see the
failures only after you start streaming the data. The subscribe method should be called as a request to start
streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe
method will result in a new Subscription
i.e., a new contract to stream data from the
starting request.
The following are few ways to use the response class:
1) Using the forEach helper method
software.amazon.awssdk.services.medialive.paginators.ListInputsPublisher publisher = client.listInputsPaginator(request);
CompletableFuture<Void> future = publisher.forEach(res -> { // Do something with the response });
future.get();
2) Using a custom subscriber
software.amazon.awssdk.services.medialive.paginators.ListInputsPublisher publisher = client.listInputsPaginator(request);
publisher.subscribe(new Subscriber<software.amazon.awssdk.services.medialive.model.ListInputsResponse>() {
public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... };
public void onNext(software.amazon.awssdk.services.medialive.model.ListInputsResponse response) { //... };
});
As the response is a publisher, it can work well with third party reactive streams implementations like RxJava2.
Note: If you prefer to have control on service calls, use the
listInputs(software.amazon.awssdk.services.medialive.model.ListInputsRequest)
operation.
default CompletableFuture<StartChannelResponse> startChannel(StartChannelRequest startChannelRequest)
startChannelRequest
- Placeholder documentation for StartChannelRequestdefault CompletableFuture<StartChannelResponse> startChannel(Consumer<StartChannelRequest.Builder> startChannelRequest)
StartChannelRequest.Builder
avoiding the need to
create one manually via StartChannelRequest.builder()
startChannelRequest
- a Consumer
that will call methods on StartChannelRequest.Builder
.default CompletableFuture<StopChannelResponse> stopChannel(StopChannelRequest stopChannelRequest)
stopChannelRequest
- Placeholder documentation for StopChannelRequestdefault CompletableFuture<StopChannelResponse> stopChannel(Consumer<StopChannelRequest.Builder> stopChannelRequest)
StopChannelRequest.Builder
avoiding the need to
create one manually via StopChannelRequest.builder()
stopChannelRequest
- a Consumer
that will call methods on StopChannelRequest.Builder
.Copyright © 2017 Amazon Web Services, Inc. All Rights Reserved.