org.modeshape.jcr.api.text

## Interface TextExtractor.Context

- All Known Implementing Classes:
    TextExtractorContext
  Enclosing class:
    TextExtractor

      public static interface TextExtractor.Context

  Interface which provides additional information to the text extractors, during the extraction operation.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `mimeTypeOf(String name, Binary binaryValue)` Determines the mime-type of the given binary value .

- - ### Method Detail

    - #### mimeTypeOf

          String mimeTypeOf(String name,
                          Binary binaryValue)
                            throws RepositoryException,
                                   IOException

      Determines the mime-type of the given binary value .
      Parameters:
        `name` - a symbolic name of the binary value (e.g. the name of a file); may be `null`
        `binaryValue` - a `Binary` instance which represents the binary data; may not be `null`
      Returns:
        either a valid mime-type or `null` if it's not possible to determine the mimetype.
      Throws:
        `RepositoryException` - if there are any problems accessing the binary value from the repository.
        `IOException` - if there are any problems reading bytes from the binary value.

Copyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.