Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add bucketVersioningEnabled helper methods #86

Conversation

mdedetrich
Copy link
Contributor

Follow up on from #84, one of the common usecases for bucket versioning is to figure out if its enabled/disabled and due to the current field being nested inside of an option with a custom ADT the helper methods are being added to trivialize the operation.

Note that a Java alias is being added since the rest of the models in S3 follow the field/getField for Scala/Java repsectively.

Copy link
Contributor

@nvollmar nvollmar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@mdedetrich mdedetrich merged commit 108235f into apache:main May 1, 2023
48 of 50 checks passed
@@ -194,6 +200,12 @@ final class BucketVersioning private (val status: Option[BucketVersioningStatus]
/** Java API */
def getMfaDelete: java.util.Optional[MFAStatus] = mfaDelete.asJava

/** Java API */
def getBucketVersioningEnabled: Boolean = bucketVersioningEnabled
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With Java APIs, it is more common to use 'is' instead of 'get' for the names of getters that return booleans.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants