commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sebb (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (COMPRESS-300) LZWInputStream has mutable protected fields; these should be accessed via getter/setter and made private
Date Thu, 05 Feb 2015 10:32:35 GMT

    [ https://issues.apache.org/jira/browse/COMPRESS-300?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14306974#comment-14306974
] 

Sebb commented on COMPRESS-300:
-------------------------------

I'm not sure that is a good idea.
At least one of the fields was not used outside the class, so it should never have been protected.
Also it looks like some of the fields need to be related to each other.

> LZWInputStream has mutable protected fields; these should be accessed via getter/setter
and made private
> --------------------------------------------------------------------------------------------------------
>
>                 Key: COMPRESS-300
>                 URL: https://issues.apache.org/jira/browse/COMPRESS-300
>             Project: Commons Compress
>          Issue Type: Bug
>            Reporter: Sebb
>         Attachments: COMPRESS-300.patch
>
>
> As per the discussion on the dev list, the class LZWInputStream has some non-private
mutable fields.
> These should be accessed via getters/setters only (data encapsulation).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message