Class Trail
- All Implemented Interfaces:
Serializable
,Cloneable
The settings for a trail.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()
boolean
Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.The region in which the trail was created.Set to True to include AWS API calls from AWS global services such as IAM.Specifies whether the trail belongs only to one region or exists in all regions.Specifies the KMS key ID that encrypts the logs delivered by CloudTrail.Specifies whether log file validation is enabled.getName()
Name of the trail set by calling CreateTrail.Name of the Amazon S3 bucket into which CloudTrail delivers your trail files.Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery.Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.Deprecated.Specifies the ARN of the trail.int
hashCode()
Set to True to include AWS API calls from AWS global services such as IAM.Specifies whether log file validation is enabled.Specifies whether the trail belongs only to one region or exists in all regions.void
setCloudWatchLogsLogGroupArn
(String cloudWatchLogsLogGroupArn) Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.void
setCloudWatchLogsRoleArn
(String cloudWatchLogsRoleArn) Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.void
setHomeRegion
(String homeRegion) The region in which the trail was created.void
setIncludeGlobalServiceEvents
(Boolean includeGlobalServiceEvents) Set to True to include AWS API calls from AWS global services such as IAM.void
setIsMultiRegionTrail
(Boolean isMultiRegionTrail) Specifies whether the trail belongs only to one region or exists in all regions.void
setKmsKeyId
(String kmsKeyId) Specifies the KMS key ID that encrypts the logs delivered by CloudTrail.void
setLogFileValidationEnabled
(Boolean logFileValidationEnabled) Specifies whether log file validation is enabled.void
Name of the trail set by calling CreateTrail.void
setS3BucketName
(String s3BucketName) Name of the Amazon S3 bucket into which CloudTrail delivers your trail files.void
setS3KeyPrefix
(String s3KeyPrefix) Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery.void
setSnsTopicARN
(String snsTopicARN) Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.void
setSnsTopicName
(String snsTopicName) Deprecated.void
setTrailARN
(String trailARN) Specifies the ARN of the trail.toString()
Returns a string representation of this object; useful for testing and debugging.withCloudWatchLogsLogGroupArn
(String cloudWatchLogsLogGroupArn) Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.withCloudWatchLogsRoleArn
(String cloudWatchLogsRoleArn) Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.withHomeRegion
(String homeRegion) The region in which the trail was created.withIncludeGlobalServiceEvents
(Boolean includeGlobalServiceEvents) Set to True to include AWS API calls from AWS global services such as IAM.withIsMultiRegionTrail
(Boolean isMultiRegionTrail) Specifies whether the trail belongs only to one region or exists in all regions.withKmsKeyId
(String kmsKeyId) Specifies the KMS key ID that encrypts the logs delivered by CloudTrail.withLogFileValidationEnabled
(Boolean logFileValidationEnabled) Specifies whether log file validation is enabled.Name of the trail set by calling CreateTrail.withS3BucketName
(String s3BucketName) Name of the Amazon S3 bucket into which CloudTrail delivers your trail files.withS3KeyPrefix
(String s3KeyPrefix) Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery.withSnsTopicARN
(String snsTopicARN) Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.withSnsTopicName
(String snsTopicName) Deprecated.withTrailARN
(String trailARN) Specifies the ARN of the trail.
-
Constructor Details
-
Trail
public Trail()
-
-
Method Details
-
setName
Name of the trail set by calling CreateTrail. The maximum length is 128 characters.
- Parameters:
name
- Name of the trail set by calling CreateTrail. The maximum length is 128 characters.
-
getName
Name of the trail set by calling CreateTrail. The maximum length is 128 characters.
- Returns:
- Name of the trail set by calling CreateTrail. The maximum length is 128 characters.
-
withName
Name of the trail set by calling CreateTrail. The maximum length is 128 characters.
- Parameters:
name
- Name of the trail set by calling CreateTrail. The maximum length is 128 characters.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setS3BucketName
Name of the Amazon S3 bucket into which CloudTrail delivers your trail files. See Amazon S3 Bucket Naming Requirements.
- Parameters:
s3BucketName
- Name of the Amazon S3 bucket into which CloudTrail delivers your trail files. See Amazon S3 Bucket Naming Requirements.
-
getS3BucketName
Name of the Amazon S3 bucket into which CloudTrail delivers your trail files. See Amazon S3 Bucket Naming Requirements.
- Returns:
- Name of the Amazon S3 bucket into which CloudTrail delivers your trail files. See Amazon S3 Bucket Naming Requirements.
-
withS3BucketName
Name of the Amazon S3 bucket into which CloudTrail delivers your trail files. See Amazon S3 Bucket Naming Requirements.
- Parameters:
s3BucketName
- Name of the Amazon S3 bucket into which CloudTrail delivers your trail files. See Amazon S3 Bucket Naming Requirements.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setS3KeyPrefix
Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery. For more information, see Finding Your CloudTrail Log Files.The maximum length is 200 characters.
- Parameters:
s3KeyPrefix
- Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery. For more information, see Finding Your CloudTrail Log Files.The maximum length is 200 characters.
-
getS3KeyPrefix
Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery. For more information, see Finding Your CloudTrail Log Files.The maximum length is 200 characters.
- Returns:
- Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery. For more information, see Finding Your CloudTrail Log Files.The maximum length is 200 characters.
-
withS3KeyPrefix
Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery. For more information, see Finding Your CloudTrail Log Files.The maximum length is 200 characters.
- Parameters:
s3KeyPrefix
- Specifies the Amazon S3 key prefix that comes after the name of the bucket you have designated for log file delivery. For more information, see Finding Your CloudTrail Log Files.The maximum length is 200 characters.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setSnsTopicName
Deprecated.Specifies the name of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.
- Parameters:
snsTopicName
- Specifies the name of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.
-
getSnsTopicName
Deprecated.Specifies the name of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.
- Returns:
- Specifies the name of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.
-
withSnsTopicName
Deprecated.Specifies the name of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.
- Parameters:
snsTopicName
- Specifies the name of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setSnsTopicARN
Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered. The format of a topic ARN is:
arn:aws:sns:us-east-1:123456789012:MyTopic
- Parameters:
snsTopicARN
- Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered. The format of a topic ARN is:arn:aws:sns:us-east-1:123456789012:MyTopic
-
getSnsTopicARN
Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered. The format of a topic ARN is:
arn:aws:sns:us-east-1:123456789012:MyTopic
- Returns:
- Specifies the ARN of the Amazon SNS topic that CloudTrail uses to
send notifications when log files are delivered. The format of a
topic ARN is:
arn:aws:sns:us-east-1:123456789012:MyTopic
-
withSnsTopicARN
Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered. The format of a topic ARN is:
arn:aws:sns:us-east-1:123456789012:MyTopic
- Parameters:
snsTopicARN
- Specifies the ARN of the Amazon SNS topic that CloudTrail uses to send notifications when log files are delivered. The format of a topic ARN is:arn:aws:sns:us-east-1:123456789012:MyTopic
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setIncludeGlobalServiceEvents
Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.
- Parameters:
includeGlobalServiceEvents
- Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.
-
getIncludeGlobalServiceEvents
Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.
- Returns:
- Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.
-
withIncludeGlobalServiceEvents
Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.
- Parameters:
includeGlobalServiceEvents
- Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isIncludeGlobalServiceEvents
Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.
- Returns:
- Set to True to include AWS API calls from AWS global services such as IAM. Otherwise, False.
-
setIsMultiRegionTrail
Specifies whether the trail belongs only to one region or exists in all regions.
- Parameters:
isMultiRegionTrail
- Specifies whether the trail belongs only to one region or exists in all regions.
-
getIsMultiRegionTrail
Specifies whether the trail belongs only to one region or exists in all regions.
- Returns:
- Specifies whether the trail belongs only to one region or exists in all regions.
-
withIsMultiRegionTrail
Specifies whether the trail belongs only to one region or exists in all regions.
- Parameters:
isMultiRegionTrail
- Specifies whether the trail belongs only to one region or exists in all regions.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isMultiRegionTrail
Specifies whether the trail belongs only to one region or exists in all regions.
- Returns:
- Specifies whether the trail belongs only to one region or exists in all regions.
-
setHomeRegion
The region in which the trail was created.
- Parameters:
homeRegion
- The region in which the trail was created.
-
getHomeRegion
The region in which the trail was created.
- Returns:
- The region in which the trail was created.
-
withHomeRegion
The region in which the trail was created.
- Parameters:
homeRegion
- The region in which the trail was created.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setTrailARN
Specifies the ARN of the trail. The format of a trail ARN is:
arn:aws:cloudtrail:us-east-1:123456789012:trail/MyTrail
- Parameters:
trailARN
- Specifies the ARN of the trail. The format of a trail ARN is:arn:aws:cloudtrail:us-east-1:123456789012:trail/MyTrail
-
getTrailARN
Specifies the ARN of the trail. The format of a trail ARN is:
arn:aws:cloudtrail:us-east-1:123456789012:trail/MyTrail
- Returns:
- Specifies the ARN of the trail. The format of a trail ARN is:
arn:aws:cloudtrail:us-east-1:123456789012:trail/MyTrail
-
withTrailARN
Specifies the ARN of the trail. The format of a trail ARN is:
arn:aws:cloudtrail:us-east-1:123456789012:trail/MyTrail
- Parameters:
trailARN
- Specifies the ARN of the trail. The format of a trail ARN is:arn:aws:cloudtrail:us-east-1:123456789012:trail/MyTrail
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setLogFileValidationEnabled
Specifies whether log file validation is enabled.
- Parameters:
logFileValidationEnabled
- Specifies whether log file validation is enabled.
-
getLogFileValidationEnabled
Specifies whether log file validation is enabled.
- Returns:
- Specifies whether log file validation is enabled.
-
withLogFileValidationEnabled
Specifies whether log file validation is enabled.
- Parameters:
logFileValidationEnabled
- Specifies whether log file validation is enabled.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isLogFileValidationEnabled
Specifies whether log file validation is enabled.
- Returns:
- Specifies whether log file validation is enabled.
-
setCloudWatchLogsLogGroupArn
Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.
- Parameters:
cloudWatchLogsLogGroupArn
- Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.
-
getCloudWatchLogsLogGroupArn
Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.
- Returns:
- Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.
-
withCloudWatchLogsLogGroupArn
Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.
- Parameters:
cloudWatchLogsLogGroupArn
- Specifies an Amazon Resource Name (ARN), a unique identifier that represents the log group to which CloudTrail logs will be delivered.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setCloudWatchLogsRoleArn
Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.
- Parameters:
cloudWatchLogsRoleArn
- Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.
-
getCloudWatchLogsRoleArn
Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.
- Returns:
- Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.
-
withCloudWatchLogsRoleArn
Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.
- Parameters:
cloudWatchLogsRoleArn
- Specifies the role for the CloudWatch Logs endpoint to assume to write to a user's log group.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setKmsKeyId
Specifies the KMS key ID that encrypts the logs delivered by CloudTrail. The value is a fully specified ARN to a KMS key in the format:
arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
- Parameters:
kmsKeyId
- Specifies the KMS key ID that encrypts the logs delivered by CloudTrail. The value is a fully specified ARN to a KMS key in the format:arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
-
getKmsKeyId
Specifies the KMS key ID that encrypts the logs delivered by CloudTrail. The value is a fully specified ARN to a KMS key in the format:
arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
- Returns:
- Specifies the KMS key ID that encrypts the logs delivered by
CloudTrail. The value is a fully specified ARN to a KMS key in
the format:
arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
-
withKmsKeyId
Specifies the KMS key ID that encrypts the logs delivered by CloudTrail. The value is a fully specified ARN to a KMS key in the format:
arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
- Parameters:
kmsKeyId
- Specifies the KMS key ID that encrypts the logs delivered by CloudTrail. The value is a fully specified ARN to a KMS key in the format:arn:aws:kms:us-east-1:123456789012:key/12345678-1234-1234-1234-123456789012
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
toString
Returns a string representation of this object; useful for testing and debugging. -
equals
-
hashCode
public int hashCode() -
clone
-