std::sub_match
Da cppreference.com
![]() | This page has been machine-translated from the English version of the wiki using Google Translate. The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
Definido no cabeçalho <regex> | ||
template< class BidirIt | (desde C++11) | |
O
sub_match
modelo de classe é usado pelo mecanismo de expressão regular para indicar sequências de caracteres pareados por acentuada sub-expressões.Original:
The class template
sub_match
is used by the regular expression engine to denote sequences of characters matched by marked sub-expressions.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
A partida é um par
[begin, end)
dentro da faixa alvo correspondido pela expressão regular, mas com funções de observação adicionais para aumentar a clareza de código.Original:
A match is a
[begin, end)
pair within the target range matched by the regular expression, but with additional observer functions to enhance code clarity.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Apenas o construtor padrão é acessível ao público. Instâncias de
sub_match
normalmente são construídos e preenchido, como uma parte de um recipiente std::match_results durante o processamento de um dos algoritmos regex.Original:
Only the default constructor is publicly accessible. Instances of
sub_match
are normally constructed and populated as a part of a std::match_results container during the processing of one of the regex algorithms.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
As funções de membro retornar valores padrão definidos a menos que o membro matched é
true
.Original:
The member functions return defined default values unless the matched member is
true
.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
sub_match
herda std::pair<BidirIt, BidirIt>, embora ela não pode ser tratada como um objeto std::pair porque as funções membros, como a permuta e cessão não vai funcionar como esperado.Original:
sub_match
inherits from std::pair<BidirIt, BidirIt>, although it cannot be treated as a std::pair object because member functions such as swap and assignment will not work as expected.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Índice |
[editar]Requisitos de tipo
-BidirIt must meet the requirements of BidirectionalIterator . |
[editar]Especializações
Várias especializações para tipos de seqüência de caracteres comuns são fornecidos:
Original:
Several specializations for common character sequence types are provided:
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Defined in header <regex> | |
Tipo Original: Type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | Definition |
csub_match | sub_match<constchar*> |
wcsub_match | sub_match<constwchar_t*> |
ssub_match | sub_match<std::string::const_iterator> |
wssub_match | sub_match<std::wstring::const_iterator> |
[editar]Tipos de membro
Tipo de membro Original: Member type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | Definition |
iterator | BidirIt |
value_type | std::iterator_traits<BidirIt>::value_type |
difference_type | std::iterator_traits<BidirIt>::difference_type |
string_type | std::basic_string<value_type> |
[editar]Objetos Membros
matched | Indica se este jogo foi bem sucedido . Original: Indicates if this match was successful. The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
Herdado de std::pair
first | Início da sequência de jogo . Original: Start of the match sequence. The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
second | Um-passado-fim-da seqüência jogo . Original: One-past-the-end of the match sequence. The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[editar]Funções de membro
constrói o objeto partida Original: constructs the match object The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (função pública membro) | |
Original: Observers The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. | |
retorna o comprimento da partida (se houver) Original: returns the length of the match (if any) The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (função pública membro) | |
converte para o tipo string subjacente Original: converts to the underlying string type The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (função pública membro) | |
compara subsequência correspondente (se houver) Original: compares matched subsequence (if any) The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (função pública membro) |
[editar]Não-membros funções
lexicographically compara os valores no recipiente Original: lexicographically compares the values in the container The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (função) | |
gera a subseqüência de caracteres correspondida Original: outputs the matched character subsequence The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (modelo de função) |
[editar]Veja também
(C++11) | itera submatches regex Original: iterates through regex submatches The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (modelo de classe) |