arturobernalg commented on PR #420: URL: https://github.com/apache/httpcomponents-client/pull/420#issuecomment-1464390282
> > @ok2c done? > > @arturobernalg No, not quite. You added `@Immutable` to `CacheControl` but it is not immutable. Its instance variables are not final. You need to make sure the instances of `CacheControl` cannot be mutated after construction. HI @ok2c You are correct, adding @Immutable to CacheControl does not make it immutable by itself. I have made the necessary changes to make CacheControl immutable. I declared the instance variables maxAge and sharedMaxAge as final, removed their setter methods, and modified the constructor to accept the values for these variables and initialize them with these values. With these changes, instances of CacheControl cannot be mutated after construction, making it truly immutable. Please let me know if you have any further concerns or feedback. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
