In a concurrent Java application, what is the recommended way to modify an internal object of a collection?
By using methods like compute for atomic operations
compute
By synchronizing the access to the object
By avoiding any modifications to internal objects
By directly modifying the object after retrieving it from the collection