Ocean
Ocean::Media::Library::Definition Class Reference

Class combining the url, type, library of a medium, and a unique identifier. More...

Public Member Functions

 Definition ()=default
 Default constructor. More...
 
 Definition (std::string url, const Medium::Type type, std::string library, std::string uniqueIdentifier=std::string())
 Creates a new definition object. More...
 
const std::string & url () const
 Returns the URL of the medium definition. More...
 
Medium::Type type () const
 Returns the type of the medium. More...
 
const std::string & library () const
 Returns the name of the library to which the medium belongs. More...
 
const std::string & uniqueIdentifier () const
 Returns the optional unique identifier of the medium. More...
 

Protected Attributes

std::string url_
 Url of the medium. More...
 
Medium::Type type_ = Medium::MEDIUM
 Type of the medium. More...
 
std::string library_
 Name of the library. More...
 
std::string uniqueIdentifier_
 Optional unique identifier of the medium, e.g., a device name or a serial number. More...
 

Detailed Description

Class combining the url, type, library of a medium, and a unique identifier.

Constructor & Destructor Documentation

◆ Definition() [1/2]

Ocean::Media::Library::Definition::Definition ( )
default

Default constructor.

◆ Definition() [2/2]

Ocean::Media::Library::Definition::Definition ( std::string  url,
const Medium::Type  type,
std::string  library,
std::string  uniqueIdentifier = std::string() 
)
inline

Creates a new definition object.

Parameters
urlThe URL of the medium
typeThe type of the medium
libraryThe name of the library to which the medium belongs
uniqueIdentifierOptional unique identifier of the medium (e.g., in case the medium is a USB device).

Member Function Documentation

◆ library()

const std::string & Ocean::Media::Library::Definition::library ( ) const
inline

Returns the name of the library to which the medium belongs.

Returns
The medium's library

◆ type()

Medium::Type Ocean::Media::Library::Definition::type ( ) const
inline

Returns the type of the medium.

Returns
The medium's type

◆ uniqueIdentifier()

const std::string & Ocean::Media::Library::Definition::uniqueIdentifier ( ) const
inline

Returns the optional unique identifier of the medium.

Returns
The medium's unique identifier, empty if unknown

◆ url()

const std::string & Ocean::Media::Library::Definition::url ( ) const
inline

Returns the URL of the medium definition.

@retrn The medium's URL

Field Documentation

◆ library_

std::string Ocean::Media::Library::Definition::library_
protected

Name of the library.

◆ type_

Medium::Type Ocean::Media::Library::Definition::type_ = Medium::MEDIUM
protected

Type of the medium.

◆ uniqueIdentifier_

std::string Ocean::Media::Library::Definition::uniqueIdentifier_
protected

Optional unique identifier of the medium, e.g., a device name or a serial number.

◆ url_

std::string Ocean::Media::Library::Definition::url_
protected

Url of the medium.


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