public class GetLogEventsRequest extends AmazonWebServiceRequest implements java.io.Serializable
Lists log events from the specified log stream. You can list all the log events or filter using a time range.
By default, this operation returns as many log events as can fit in a response size of 1MB (up to 10,000 log events). You can get additional log events by specifying one of the tokens in a subsequent call.
Constructor and Description |
---|
GetLogEventsRequest()
Default constructor for GetLogEventsRequest object.
|
GetLogEventsRequest(java.lang.String logGroupName,
java.lang.String logStreamName)
Constructs a new GetLogEventsRequest object.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.Long |
getEndTime()
The end of the time range, expressed as the number of milliseconds after
Jan 1, 1970 00:00:00 UTC.
|
java.lang.Integer |
getLimit()
The maximum number of log events returned.
|
java.lang.String |
getLogGroupName()
The name of the log group.
|
java.lang.String |
getLogStreamName()
The name of the log stream.
|
java.lang.String |
getNextToken()
The token for the next set of items to return.
|
java.lang.Boolean |
getStartFromHead()
If the value is true, the earliest log events are returned first.
|
java.lang.Long |
getStartTime()
The start of the time range, expressed as the number of milliseconds
after Jan 1, 1970 00:00:00 UTC.
|
int |
hashCode() |
java.lang.Boolean |
isStartFromHead()
If the value is true, the earliest log events are returned first.
|
void |
setEndTime(java.lang.Long endTime)
The end of the time range, expressed as the number of milliseconds after
Jan 1, 1970 00:00:00 UTC.
|
void |
setLimit(java.lang.Integer limit)
The maximum number of log events returned.
|
void |
setLogGroupName(java.lang.String logGroupName)
The name of the log group.
|
void |
setLogStreamName(java.lang.String logStreamName)
The name of the log stream.
|
void |
setNextToken(java.lang.String nextToken)
The token for the next set of items to return.
|
void |
setStartFromHead(java.lang.Boolean startFromHead)
If the value is true, the earliest log events are returned first.
|
void |
setStartTime(java.lang.Long startTime)
The start of the time range, expressed as the number of milliseconds
after Jan 1, 1970 00:00:00 UTC.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
GetLogEventsRequest |
withEndTime(java.lang.Long endTime)
The end of the time range, expressed as the number of milliseconds after
Jan 1, 1970 00:00:00 UTC.
|
GetLogEventsRequest |
withLimit(java.lang.Integer limit)
The maximum number of log events returned.
|
GetLogEventsRequest |
withLogGroupName(java.lang.String logGroupName)
The name of the log group.
|
GetLogEventsRequest |
withLogStreamName(java.lang.String logStreamName)
The name of the log stream.
|
GetLogEventsRequest |
withNextToken(java.lang.String nextToken)
The token for the next set of items to return.
|
GetLogEventsRequest |
withStartFromHead(java.lang.Boolean startFromHead)
If the value is true, the earliest log events are returned first.
|
GetLogEventsRequest |
withStartTime(java.lang.Long startTime)
The start of the time range, expressed as the number of milliseconds
after Jan 1, 1970 00:00:00 UTC.
|
clone, getCloneRoot, getCloneSource, getGeneralProgressListener, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, setGeneralProgressListener, setRequestCredentials, setRequestMetricCollector, withGeneralProgressListener, withRequestMetricCollector
public GetLogEventsRequest()
public GetLogEventsRequest(java.lang.String logGroupName, java.lang.String logStreamName)
logGroupName
- The name of the log group.
logStreamName
- The name of the log stream.
public java.lang.String getLogGroupName()
The name of the log group.
Constraints:
Length: 1 - 512
Pattern: [\.\-_/#A-Za-z0-9]+
The name of the log group.
public void setLogGroupName(java.lang.String logGroupName)
The name of the log group.
Constraints:
Length: 1 - 512
Pattern: [\.\-_/#A-Za-z0-9]+
logGroupName
- The name of the log group.
public GetLogEventsRequest withLogGroupName(java.lang.String logGroupName)
The name of the log group.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 512
Pattern: [\.\-_/#A-Za-z0-9]+
logGroupName
- The name of the log group.
public java.lang.String getLogStreamName()
The name of the log stream.
Constraints:
Length: 1 - 512
Pattern: [^:*]*
The name of the log stream.
public void setLogStreamName(java.lang.String logStreamName)
The name of the log stream.
Constraints:
Length: 1 - 512
Pattern: [^:*]*
logStreamName
- The name of the log stream.
public GetLogEventsRequest withLogStreamName(java.lang.String logStreamName)
The name of the log stream.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 512
Pattern: [^:*]*
logStreamName
- The name of the log stream.
public java.lang.Long getStartTime()
The start of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to this time or later than this time are included. Events with a time stamp earlier than this time are not included.
Constraints:
Range: 0 -
The start of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to this time or later than this time are included. Events with a time stamp earlier than this time are not included.
public void setStartTime(java.lang.Long startTime)
The start of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to this time or later than this time are included. Events with a time stamp earlier than this time are not included.
Constraints:
Range: 0 -
startTime
- The start of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to this time or later than this time are included. Events with a time stamp earlier than this time are not included.
public GetLogEventsRequest withStartTime(java.lang.Long startTime)
The start of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to this time or later than this time are included. Events with a time stamp earlier than this time are not included.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Range: 0 -
startTime
- The start of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to this time or later than this time are included. Events with a time stamp earlier than this time are not included.
public java.lang.Long getEndTime()
The end of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to or later than this time are not included.
Constraints:
Range: 0 -
The end of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to or later than this time are not included.
public void setEndTime(java.lang.Long endTime)
The end of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to or later than this time are not included.
Constraints:
Range: 0 -
endTime
- The end of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to or later than this time are not included.
public GetLogEventsRequest withEndTime(java.lang.Long endTime)
The end of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to or later than this time are not included.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Range: 0 -
endTime
- The end of the time range, expressed as the number of milliseconds after Jan 1, 1970 00:00:00 UTC. Events with a time stamp equal to or later than this time are not included.
public java.lang.String getNextToken()
The token for the next set of items to return. (You received this token from a previous call.)
Constraints:
Length: 1 -
The token for the next set of items to return. (You received this token from a previous call.)
public void setNextToken(java.lang.String nextToken)
The token for the next set of items to return. (You received this token from a previous call.)
Constraints:
Length: 1 -
nextToken
- The token for the next set of items to return. (You received this token from a previous call.)
public GetLogEventsRequest withNextToken(java.lang.String nextToken)
The token for the next set of items to return. (You received this token from a previous call.)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 -
nextToken
- The token for the next set of items to return. (You received this token from a previous call.)
public java.lang.Integer getLimit()
The maximum number of log events returned. If you don't specify a value, the maximum is as many log events as can fit in a response size of 1 MB, up to 10,000 log events.
Constraints:
Range: 1 - 10000
The maximum number of log events returned. If you don't specify a value, the maximum is as many log events as can fit in a response size of 1 MB, up to 10,000 log events.
public void setLimit(java.lang.Integer limit)
The maximum number of log events returned. If you don't specify a value, the maximum is as many log events as can fit in a response size of 1 MB, up to 10,000 log events.
Constraints:
Range: 1 - 10000
limit
- The maximum number of log events returned. If you don't specify a value, the maximum is as many log events as can fit in a response size of 1 MB, up to 10,000 log events.
public GetLogEventsRequest withLimit(java.lang.Integer limit)
The maximum number of log events returned. If you don't specify a value, the maximum is as many log events as can fit in a response size of 1 MB, up to 10,000 log events.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Range: 1 - 10000
limit
- The maximum number of log events returned. If you don't specify a value, the maximum is as many log events as can fit in a response size of 1 MB, up to 10,000 log events.
public java.lang.Boolean isStartFromHead()
If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
public java.lang.Boolean getStartFromHead()
If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
public void setStartFromHead(java.lang.Boolean startFromHead)
If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
startFromHead
- If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
public GetLogEventsRequest withStartFromHead(java.lang.Boolean startFromHead)
If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
Returns a reference to this object so that method calls can be chained together.
startFromHead
- If the value is true, the earliest log events are returned first. If the value is false, the latest log events are returned first. The default value is false.
public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
Copyright © 2018 Amazon Web Services, Inc. All Rights Reserved.