[jira] Created: (VFS-254) Let FileObject and FileContent extend Closeable

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (VFS-254) Let FileObject and FileContent extend Closeable

ASF GitHub Bot (Jira)
Let FileObject and FileContent extend Closeable
-----------------------------------------------

                 Key: VFS-254
                 URL: https://issues.apache.org/jira/browse/VFS-254
             Project: Commons VFS
          Issue Type: Improvement
    Affects Versions: 1.0, 1.1, later, Nightly Builds, 2.0
            Reporter: Marek Zawirski
            Priority: Trivial
             Fix For: 2.0


What about letting FileObject and FileContent extend java.io.Closeable interface?

Some applications have a generic code for closing such resources (and for example ignoring and logging exceptions during close), so it may be useful at application-level.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (VFS-254) Let FileObject and FileContent extend Closeable

ASF GitHub Bot (Jira)

     [ https://issues.apache.org/jira/browse/VFS-254?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Marek Zawirski updated VFS-254:
-------------------------------

    Attachment: extend_cloneable.patch

I am attaching trivial patch proposal.

> Let FileObject and FileContent extend Closeable
> -----------------------------------------------
>
>                 Key: VFS-254
>                 URL: https://issues.apache.org/jira/browse/VFS-254
>             Project: Commons VFS
>          Issue Type: Improvement
>    Affects Versions: 1.0, 1.1, later, Nightly Builds, 2.0
>            Reporter: Marek Zawirski
>            Priority: Trivial
>             Fix For: 2.0
>
>         Attachments: extend_cloneable.patch
>
>
> What about letting FileObject and FileContent extend java.io.Closeable interface?
> Some applications have a generic code for closing such resources (and for example ignoring and logging exceptions during close), so it may be useful at application-level.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (VFS-254) Let FileObject and FileContent extend Closeable

ASF GitHub Bot (Jira)
In reply to this post by ASF GitHub Bot (Jira)

    [ https://issues.apache.org/jira/browse/VFS-254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12707951#action_12707951 ]

Sebb commented on VFS-254:
--------------------------

Closeable requires Java 1.5+

AFAIK, currently VFS targets Java 1.4 (or possibly 1.3)

> Let FileObject and FileContent extend Closeable
> -----------------------------------------------
>
>                 Key: VFS-254
>                 URL: https://issues.apache.org/jira/browse/VFS-254
>             Project: Commons VFS
>          Issue Type: Improvement
>    Affects Versions: 1.0, 1.1, later, Nightly Builds, 2.0
>            Reporter: Marek Zawirski
>            Priority: Trivial
>             Fix For: 2.0
>
>         Attachments: extend_cloneable.patch
>
>
> What about letting FileObject and FileContent extend java.io.Closeable interface?
> Some applications have a generic code for closing such resources (and for example ignoring and logging exceptions during close), so it may be useful at application-level.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (VFS-254) Let FileObject and FileContent extend Closeable

ASF GitHub Bot (Jira)
In reply to this post by ASF GitHub Bot (Jira)

    [ https://issues.apache.org/jira/browse/VFS-254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12774792#action_12774792 ]

Ralph Goers commented on VFS-254:
---------------------------------

VFS 2.0 targets Java 1.4. When 2.0 is released I am considering starting work on a 3.0 that will target Java 1.7 since that will introduce the java.nio.file.spi package.

> Let FileObject and FileContent extend Closeable
> -----------------------------------------------
>
>                 Key: VFS-254
>                 URL: https://issues.apache.org/jira/browse/VFS-254
>             Project: Commons VFS
>          Issue Type: Improvement
>    Affects Versions: 1.0, 1.1, later, Nightly Builds, 2.0
>            Reporter: Marek Zawirski
>            Priority: Trivial
>             Fix For: 2.0
>
>         Attachments: extend_cloneable.patch
>
>
> What about letting FileObject and FileContent extend java.io.Closeable interface?
> Some applications have a generic code for closing such resources (and for example ignoring and logging exceptions during close), so it may be useful at application-level.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (VFS-254) Let FileObject and FileContent extend Closeable

ASF GitHub Bot (Jira)
In reply to this post by ASF GitHub Bot (Jira)

    [ https://issues.apache.org/jira/browse/VFS-254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12887920#action_12887920 ]

Brad Davis commented on VFS-254:
--------------------------------

Can we call 1.4 dead, or at least sufficiently covered by VFS 1.x?

> Let FileObject and FileContent extend Closeable
> -----------------------------------------------
>
>                 Key: VFS-254
>                 URL: https://issues.apache.org/jira/browse/VFS-254
>             Project: Commons VFS
>          Issue Type: Improvement
>    Affects Versions: 1.0, 1.1, later, Nightly Builds, 2.0
>            Reporter: Marek Zawirski
>            Priority: Trivial
>             Fix For: 2.0
>
>         Attachments: extend_cloneable.patch
>
>
> What about letting FileObject and FileContent extend java.io.Closeable interface?
> Some applications have a generic code for closing such resources (and for example ignoring and logging exceptions during close), so it may be useful at application-level.

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.