Class GetLogEventsRequest
- java.lang.Object
-
- com.amazonaws.AmazonWebServiceRequest
-
- com.amazonaws.services.logs.model.GetLogEventsRequest
-
- All Implemented Interfaces:
ReadLimitInfo
,Serializable
,Cloneable
public class GetLogEventsRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.amazonaws.AmazonWebServiceRequest
NOOP
-
-
Constructor Summary
Constructors Constructor Description GetLogEventsRequest()
Default constructor for GetLogEventsRequest object.GetLogEventsRequest(String logGroupName, String logStreamName)
Constructs a new GetLogEventsRequest object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description GetLogEventsRequest
clone()
Creates a shallow clone of this request.boolean
equals(Object obj)
Long
getEndTime()
Integer
getLimit()
The maximum number of log events returned in the response.String
getLogGroupName()
The name of the log group to query.String
getLogStreamName()
The name of the log stream to query.String
getNextToken()
A string token used for pagination that points to the next page of results.Boolean
getStartFromHead()
If set to true, the earliest log events would be returned first.Long
getStartTime()
int
hashCode()
Boolean
isStartFromHead()
If set to true, the earliest log events would be returned first.void
setEndTime(Long endTime)
void
setLimit(Integer limit)
The maximum number of log events returned in the response.void
setLogGroupName(String logGroupName)
The name of the log group to query.void
setLogStreamName(String logStreamName)
The name of the log stream to query.void
setNextToken(String nextToken)
A string token used for pagination that points to the next page of results.void
setStartFromHead(Boolean startFromHead)
If set to true, the earliest log events would be returned first.void
setStartTime(Long startTime)
String
toString()
Returns a string representation of this object; useful for testing and debugging.GetLogEventsRequest
withEndTime(Long endTime)
GetLogEventsRequest
withLimit(Integer limit)
The maximum number of log events returned in the response.GetLogEventsRequest
withLogGroupName(String logGroupName)
The name of the log group to query.GetLogEventsRequest
withLogStreamName(String logStreamName)
The name of the log stream to query.GetLogEventsRequest
withNextToken(String nextToken)
A string token used for pagination that points to the next page of results.GetLogEventsRequest
withStartFromHead(Boolean startFromHead)
If set to true, the earliest log events would be returned first.GetLogEventsRequest
withStartTime(Long startTime)
-
Methods inherited from class com.amazonaws.AmazonWebServiceRequest
copyBaseTo, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
-
-
-
-
Constructor Detail
-
GetLogEventsRequest
public GetLogEventsRequest()
Default constructor for GetLogEventsRequest object. Callers should use the setter or fluent setter (with...) methods to initialize the object after creating it.
-
GetLogEventsRequest
public GetLogEventsRequest(String logGroupName, String logStreamName)
Constructs a new GetLogEventsRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.- Parameters:
logGroupName
- The name of the log group to query.logStreamName
- The name of the log stream to query.
-
-
Method Detail
-
setLogGroupName
public void setLogGroupName(String logGroupName)
The name of the log group to query.
- Parameters:
logGroupName
- The name of the log group to query.
-
getLogGroupName
public String getLogGroupName()
The name of the log group to query.
- Returns:
- The name of the log group to query.
-
withLogGroupName
public GetLogEventsRequest withLogGroupName(String logGroupName)
The name of the log group to query.
- Parameters:
logGroupName
- The name of the log group to query.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setLogStreamName
public void setLogStreamName(String logStreamName)
The name of the log stream to query.
- Parameters:
logStreamName
- The name of the log stream to query.
-
getLogStreamName
public String getLogStreamName()
The name of the log stream to query.
- Returns:
- The name of the log stream to query.
-
withLogStreamName
public GetLogEventsRequest withLogStreamName(String logStreamName)
The name of the log stream to query.
- Parameters:
logStreamName
- The name of the log stream to query.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setStartTime
public void setStartTime(Long startTime)
- Parameters:
startTime
-
-
getStartTime
public Long getStartTime()
- Returns:
-
withStartTime
public GetLogEventsRequest withStartTime(Long startTime)
- Parameters:
startTime
-- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setEndTime
public void setEndTime(Long endTime)
- Parameters:
endTime
-
-
getEndTime
public Long getEndTime()
- Returns:
-
withEndTime
public GetLogEventsRequest withEndTime(Long endTime)
- Parameters:
endTime
-- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setNextToken
public void setNextToken(String nextToken)
A string token used for pagination that points to the next page of results. It must be a value obtained from the
nextForwardToken
ornextBackwardToken
fields in the response of the previousGetLogEvents
request.- Parameters:
nextToken
- A string token used for pagination that points to the next page of results. It must be a value obtained from thenextForwardToken
ornextBackwardToken
fields in the response of the previousGetLogEvents
request.
-
getNextToken
public String getNextToken()
A string token used for pagination that points to the next page of results. It must be a value obtained from the
nextForwardToken
ornextBackwardToken
fields in the response of the previousGetLogEvents
request.- Returns:
- A string token used for pagination that points to the next page
of results. It must be a value obtained from the
nextForwardToken
ornextBackwardToken
fields in the response of the previousGetLogEvents
request.
-
withNextToken
public GetLogEventsRequest withNextToken(String nextToken)
A string token used for pagination that points to the next page of results. It must be a value obtained from the
nextForwardToken
ornextBackwardToken
fields in the response of the previousGetLogEvents
request.- Parameters:
nextToken
- A string token used for pagination that points to the next page of results. It must be a value obtained from thenextForwardToken
ornextBackwardToken
fields in the response of the previousGetLogEvents
request.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setLimit
public void setLimit(Integer limit)
The maximum number of log events returned in the response. If you don't specify a value, the request would return as many log events as can fit in a response size of 1MB, up to 10,000 log events.
- Parameters:
limit
- The maximum number of log events returned in the response. If you don't specify a value, the request would return as many log events as can fit in a response size of 1MB, up to 10,000 log events.
-
getLimit
public Integer getLimit()
The maximum number of log events returned in the response. If you don't specify a value, the request would return as many log events as can fit in a response size of 1MB, up to 10,000 log events.
- Returns:
- The maximum number of log events returned in the response. If you don't specify a value, the request would return as many log events as can fit in a response size of 1MB, up to 10,000 log events.
-
withLimit
public GetLogEventsRequest withLimit(Integer limit)
The maximum number of log events returned in the response. If you don't specify a value, the request would return as many log events as can fit in a response size of 1MB, up to 10,000 log events.
- Parameters:
limit
- The maximum number of log events returned in the response. If you don't specify a value, the request would return as many log events as can fit in a response size of 1MB, up to 10,000 log events.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setStartFromHead
public void setStartFromHead(Boolean startFromHead)
If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).
- Parameters:
startFromHead
- If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).
-
getStartFromHead
public Boolean getStartFromHead()
If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).
- Returns:
- If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).
-
withStartFromHead
public GetLogEventsRequest withStartFromHead(Boolean startFromHead)
If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).
- Parameters:
startFromHead
- If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isStartFromHead
public Boolean isStartFromHead()
If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).
- Returns:
- If set to true, the earliest log events would be returned first. The default is false (the latest log events are returned first).
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toString
in classObject
- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public GetLogEventsRequest clone()
Description copied from class:AmazonWebServiceRequest
Creates a shallow clone of this request. Explicitly does not clone the deep structure of the request object.- Overrides:
clone
in classAmazonWebServiceRequest
- See Also:
Object.clone()
-
-