You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tika.apache.org by "Jukka Zitting (JIRA)" <ji...@apache.org> on 2007/10/20 00:24:50 UTC

[jira] Created: (TIKA-84) Add MimeTypes.getMimeType(InputStream)

Add MimeTypes.getMimeType(InputStream)
--------------------------------------

                 Key: TIKA-84
                 URL: https://issues.apache.org/jira/browse/TIKA-84
             Project: Tika
          Issue Type: New Feature
            Reporter: Jukka Zitting
            Assignee: Jukka Zitting
            Priority: Minor
             Fix For: 0.1-incubator


The MimeTypes class should have a utility method for detecting the MIME type from a given InputStream.

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


[jira] Resolved: (TIKA-84) Add MimeTypes.getMimeType(InputStream)

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/TIKA-84?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jukka Zitting resolved TIKA-84.
-------------------------------

    Resolution: Fixed

Fixed in revisions 586632 and 587217.

I also added a getMimeType(String, InputStream) method as a complement to the existing getMimeType(String, byte[]) method.

> Add MimeTypes.getMimeType(InputStream)
> --------------------------------------
>
>                 Key: TIKA-84
>                 URL: https://issues.apache.org/jira/browse/TIKA-84
>             Project: Tika
>          Issue Type: New Feature
>            Reporter: Jukka Zitting
>            Assignee: Jukka Zitting
>            Priority: Minor
>             Fix For: 0.1-incubator
>
>
> The MimeTypes class should have a utility method for detecting the MIME type from a given InputStream.

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


[jira] Commented: (TIKA-84) Add MimeTypes.getMimeType(InputStream)

Posted by "Keith R. Bennett (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/TIKA-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12536783 ] 

Keith R. Bennett commented on TIKA-84:
--------------------------------------

Please ignore my previous comment.

I didn't notice that the change had already been committed, and the need for doing the mark and release was documented to be the responsibility of the caller.



> Add MimeTypes.getMimeType(InputStream)
> --------------------------------------
>
>                 Key: TIKA-84
>                 URL: https://issues.apache.org/jira/browse/TIKA-84
>             Project: Tika
>          Issue Type: New Feature
>            Reporter: Jukka Zitting
>            Assignee: Jukka Zitting
>            Priority: Minor
>             Fix For: 0.1-incubator
>
>
> The MimeTypes class should have a utility method for detecting the MIME type from a given InputStream.

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


[jira] Commented: (TIKA-84) Add MimeTypes.getMimeType(InputStream)

Posted by "Keith R. Bennett (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/TIKA-84?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12536767 ] 

Keith R. Bennett commented on TIKA-84:
--------------------------------------

Jukka -

If the stream passed did not implement mark and release (i.e. its markSupported() would return false), then how would that be handled?  Would an exception be thrown?  Or null returned? Or something else?

Even if we create a BufferedInputStream to wrap it, after the method returns, the stream passed by the caller will have passed over the header.

- Keith


> Add MimeTypes.getMimeType(InputStream)
> --------------------------------------
>
>                 Key: TIKA-84
>                 URL: https://issues.apache.org/jira/browse/TIKA-84
>             Project: Tika
>          Issue Type: New Feature
>            Reporter: Jukka Zitting
>            Assignee: Jukka Zitting
>            Priority: Minor
>             Fix For: 0.1-incubator
>
>
> The MimeTypes class should have a utility method for detecting the MIME type from a given InputStream.

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