Audacity 3.2.0
Public Member Functions | Private Attributes | List of all members
BriefCommandOutputTargets Class Reference

BriefCommandOutputTargets is a CommandOutputTargets that replaces the status message target with the BriefCommandMessageTarget version. More...

#include <CommandTargets.h>

Inheritance diagram for BriefCommandOutputTargets:
[legend]
Collaboration diagram for BriefCommandOutputTargets:
[legend]

Public Member Functions

 BriefCommandOutputTargets (CommandOutputTargets &target)
 
 ~BriefCommandOutputTargets ()
 
- Public Member Functions inherited from CommandOutputTargets
 CommandOutputTargets (std::unique_ptr< CommandProgressTarget > pt=TargetFactory::ProgressDefault(), std::shared_ptr< CommandMessageTarget > st=TargetFactory::MessageDefault(), std::shared_ptr< CommandMessageTarget > et=TargetFactory::MessageDefault())
 
 ~CommandOutputTargets ()
 
void Progress (double completed)
 
void Status (const wxString &status, bool bFlush=false)
 
void Error (const wxString &message)
 
void StartArray ()
 
void EndArray ()
 
void StartStruct ()
 
void EndStruct ()
 
void StartField (const wxString &name)
 
void EndField ()
 
void AddItem (const wxString &value, const wxString &name={})
 
void AddBool (const bool value, const wxString &name={})
 
void AddItem (const double value, const wxString &name={})
 

Private Attributes

CommandOutputTargetspToRestore
 

Additional Inherited Members

- Public Attributes inherited from CommandOutputTargets
std::unique_ptr< CommandProgressTargetmProgressTarget
 
std::shared_ptr< CommandMessageTargetmStatusTarget
 
std::shared_ptr< CommandMessageTargetmErrorTarget
 

Detailed Description

BriefCommandOutputTargets is a CommandOutputTargets that replaces the status message target with the BriefCommandMessageTarget version.

Definition at line 369 of file CommandTargets.h.

Constructor & Destructor Documentation

◆ BriefCommandOutputTargets()

BriefCommandOutputTargets::BriefCommandOutputTargets ( CommandOutputTargets target)

Definition at line 276 of file CommandTargets.cpp.

278 pToRestore( &target )
279{
280 mProgressTarget = std::move(target.mProgressTarget),
281 mStatusTarget = std::make_shared<BriefCommandMessageTarget>( *target.mStatusTarget.get() ),
282 mErrorTarget = std::move( target.mErrorTarget );
283}
CommandOutputTargets * pToRestore
std::shared_ptr< CommandMessageTarget > mStatusTarget
std::unique_ptr< CommandProgressTarget > mProgressTarget
CommandOutputTargets(std::unique_ptr< CommandProgressTarget > pt=TargetFactory::ProgressDefault(), std::shared_ptr< CommandMessageTarget > st=TargetFactory::MessageDefault(), std::shared_ptr< CommandMessageTarget > et=TargetFactory::MessageDefault())
std::shared_ptr< CommandMessageTarget > mErrorTarget

References CommandOutputTargets::mErrorTarget, CommandOutputTargets::mProgressTarget, and CommandOutputTargets::mStatusTarget.

◆ ~BriefCommandOutputTargets()

BriefCommandOutputTargets::~BriefCommandOutputTargets ( )

Definition at line 285 of file CommandTargets.cpp.

286{
288 //The status was never captured so does not need restoring.
289 //pToRestore->mStatusTarget = std::move( mStatusTarget );
290 pToRestore->mErrorTarget = std::move( mErrorTarget );
291}

References CommandOutputTargets::mErrorTarget, CommandOutputTargets::mProgressTarget, and pToRestore.

Member Data Documentation

◆ pToRestore

CommandOutputTargets* BriefCommandOutputTargets::pToRestore
private

Definition at line 375 of file CommandTargets.h.

Referenced by ~BriefCommandOutputTargets().


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