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

John Hewson edited comment on PDFBOX-3576 at 11/16/16 6:40 PM:
---------------------------------------------------------------

We could, but I'd rather support use of TextPosition and TextStripper in a 
vanilla manner first - then accommodate subclassing only if strictly necessary.

How many times has "let me arbitrarily subclass this thing" actually meant "I 
need one small feature added to PDFBox". I've lost count.


was (Author: jahewson):
We could, but I'd rather support use of TextPosition and TextStripper in a 
vanilla manner first - then accommodate subclassing only if strictly necessary.

> Add getter methods to TextPosition
> ----------------------------------
>
>                 Key: PDFBOX-3576
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3576
>             Project: PDFBox
>          Issue Type: Improvement
>    Affects Versions: 2.0.3
>            Reporter: Kurt Devlin
>
> I've inherited code in my department that created a local copy of 
> TextPosition and broke it's immutability. I'm trying to refactor this code 
> and use the core Apache implementation and I understand the need for 
> TextPosition to be immutable, but can getters be added to provide read-only 
> access to the class's fields?
> We have custom code that does comparison of endX/endY values to determine if 
> there are overlapping characters and other features. In our application, we 
> also have a swap feature where we need to create/clone new TextPosition 
> instances with minor differences between an existing TextPosition instance. 
> Since there are a lot of fields that are required by the constructor of the 
> new instances, but can't be read from an existing instance, we need a way to 
> access these fields.
> There probably should also be an override for equals() and hashCode().



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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org

Reply via email to