Wt  4.12.4
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Wt::FromStringDataInfo Class Reference

Internal class. More...

#include <FromStringDataInfo.h>

Inheritance diagram for Wt::FromStringDataInfo:
[legend]

Public Member Functions

std::string filePath () const override
 Returns a path to a file containing the data.
 
std::string url () const override
 Returns the URL of the data.
 
std::string dataUri () const override
 Returns the data in data URI format.
 
bool hasFilePath () const override
 Returns whether this contains a path to a file.
 
bool hasUrl () const override
 Returns whether this contains a URL.
 
virtual bool hasDataUri () const
 Returns whether this can return the data in data URI format.
 
- Public Member Functions inherited from Wt::WAbstractDataInfo
virtual std::string name () const
 Returns the name of the Data.
 

Detailed Description

Internal class.

DataInfo created from a string like before DataInfo existed.

Member Function Documentation

◆ dataUri()

std::string Wt::FromStringDataInfo::dataUri ( ) const
overridevirtual

Returns the data in data URI format.

This returns the data in data URI format (see: https://developer.mozilla.org/en-US/docs/Web/URI/Reference/Schemes/data).

By default this will throw an exception.

Warning
If you reimplement this function, you must also reimplement hasDataUri()
See also
hasDataUri()

Reimplemented from Wt::WAbstractDataInfo.

◆ filePath()

std::string Wt::FromStringDataInfo::filePath ( ) const
overridevirtual

Returns a path to a file containing the data.

This returns a path to a file containing the data. This should point to a path that exists on the system.

By default this will throw an exception.

Warning
If you reimplement this function, you must also reimplement hasFilePath()
See also
hasFilePath()

Reimplemented from Wt::WAbstractDataInfo.

◆ hasDataUri()

virtual bool Wt::FromStringDataInfo::hasDataUri ( ) const
virtual

Returns whether this can return the data in data URI format.

This returns whether dataUri() returns the data in data URI format.

By default this returns false.

See also
dataUri()

Reimplemented from Wt::WAbstractDataInfo.

◆ hasFilePath()

bool Wt::FromStringDataInfo::hasFilePath ( ) const
overridevirtual

Returns whether this contains a path to a file.

This returns whether filePath returns a path to a file containing the data.

By default this returns false.

See also
filePath()

Reimplemented from Wt::WAbstractDataInfo.

◆ hasUrl()

bool Wt::FromStringDataInfo::hasUrl ( ) const
overridevirtual

Returns whether this contains a URL.

This returns whether url() returns a URL of the data.

By default this returns false.

See also
url()

Reimplemented from Wt::WAbstractDataInfo.

◆ url()

std::string Wt::FromStringDataInfo::url ( ) const
overridevirtual

Returns the URL of the data.

This returns the URL of the data. This can be both an absolute URL or a URL relative to the application's base URL.

By default this will throw an exception.

Warning
If you reimplement this function, you must also reimplement hasUrl()
See also
hasUrl()

Reimplemented from Wt::WAbstractDataInfo.