JUCE: AndroidDocumentInputSource Class Reference

JUCE

- Main Page
- Related Pages
- Modules
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Loading...
Searching...
No Matches
Public Member Functions | List of all members
AndroidDocumentInputSource Class Reference
juce_core » streams

An InputSource backed by an AndroidDocument. More...

`#include <juce_AndroidDocumentInputSource.h>`

Inheritance diagram for AndroidDocumentInputSource:

## Public Member Functions
| AndroidDocumentInputSource (const AndroidDocument &doc)
| Creates a new AndroidDocumentInputSource, backed by the provided document.
InputStream * | createInputStream () override
| Returns a new InputStream to read this item.
InputStream * | createInputStreamFor (const String &relatedItemPath) override
int64 | hashCode () const override
| Returns a hash code that uniquely represents this item.
Public Member Functions inherited from InputSource
| InputSource ()=default
virtual | ~InputSource ()=default
| Destructor.
virtual InputStream * | createInputStream ()=0
| Returns a new InputStream to read this item.
virtual InputStream * | createInputStreamFor (const String &relatedItemPath)=0
| Returns a new InputStream to read an item, relative.
virtual int64 | hashCode () const =0
| Returns a hash code that uniquely represents this item.

## Detailed Description

An InputSource backed by an AndroidDocument.

See also
  InputSource, AndroidDocument

## Constructor & Destructor Documentation

## ◆ AndroidDocumentInputSource()

AndroidDocumentInputSource::AndroidDocumentInputSource | ( | const AndroidDocument & | doc | ) |
| explicit

Creates a new AndroidDocumentInputSource, backed by the provided document.

## Member Function Documentation

## ◆ createInputStream()

InputStream * AndroidDocumentInputSource::createInputStream | ( |  | ) |
| overridevirtual

Returns a new InputStream to read this item.

Returns
  an inputstream that the caller will delete, or nullptr if the document can't be opened.

Implements InputSource.

## ◆ createInputStreamFor()

InputStream * AndroidDocumentInputSource::createInputStreamFor | ( | const String & | relatedItemPath | ) |
| overridevirtual

An AndroidDocument doesn't use conventional filesystem paths. Use the member functions of AndroidDocument to locate relative items.

Parameters

  relatedItemPath | the relative pathname of the resource that is required

Returns
  an input stream if relatedItemPath was empty, otherwise nullptr.

Implements InputSource.

References String::isEmpty().

## ◆ hashCode()

int64 AndroidDocumentInputSource::hashCode | ( |  | ) | const
| overridevirtual

Returns a hash code that uniquely represents this item.

Implements InputSource.

The documentation for this class was generated from the following file:

- juce_AndroidDocumentInputSource.h