◐ Shell
clean mode source ↗

std::swap(std::shared_ptr) - cppreference.com

Da cppreference.com.

Questa pagina è stata tradotta in modo automatico dalla versione in ineglese della wiki usando Google Translate.

La traduzione potrebbe contenere errori e termini strani. Muovi il puntatore sopra al testo per vedere la versione originale. Puoi aiutarci a correggere gli gli errori. Per ulteriori istruzioni clicca qui.

Click here for the English version of this page

<metanoindex/>

<tbody> </tbody>

template< class T > void swap( shared_ptr<T> &lhs, shared_ptr<T> &rhs );

(dal C++11)

Specializzato l'algoritmo std::swap per std::shared_ptr. Scambia i puntatori di lhs e rhs. Chiamate lhs.swap(rhs).

Original:

Specializes the std::swap algorithm for std::shared_ptr. Swaps the pointers of lhs and rhs. Calls lhs.swap(rhs).

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Parametri

lhs, rhs -

puntatori intelligenti il ​​cui contenuto di scambiare

Original:

smart pointers whose contents to swap

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Valore di ritorno

(Nessuno)

Original:

(none)

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Complessità

Constant

Original:

Constant

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Vedi anche

swap il contenuto

Original:

swaps the contents

The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.


(metodo pubblico) [modifica]