<sstream>

Iostreams 작업 시퀀스를 개체에 할당 된 배열에 저장을 지 원하는 여러 템플릿 클래스를 정의 합니다.이러한 시퀀스는 템플릿 클래스의 개체를 쉽게 변환 됩니다 basic_string.

namespace std {
template<class CharType,
    class Traits = char_traits<CharType>,
    class Allocator = allocator<CharType> >
    class basic_stringbuf;
typedef basic_stringbuf<char> stringbuf;
typedef basic_stringbuf<wchar_t> wstringbuf;

template<class CharType,
    class Traits = char_traits<CharType>,
    class Allocator = allocator<CharType> >
    class basic_istringstream;
typedef basic_istringstream<char> istringstream;
typedef basic_istringstream<wchar_t> wistringstream;

template<class CharType,
    class Traits = char_traits<CharType>,
    class Allocator = allocator<CharType> >
    class basic_ostringstream;
typedef basic_ostringstream<char> ostringstream;
typedef basic_ostringstream<wchar_t> wostringstream;

template<class CharType,
    class Traits = char_traits<CharType>,
    class Allocator = allocator<CharType> >
    class basic_stringstream;
typedef basic_stringstream<char> stringstream;
typedef basic_stringstream<wchar_t> wstringstream;

        // TEMPLATE FUNCTIONS
template<class CharType, class Traits, class Allocator>
    void swap(
        basic_stringbuf<CharType, Traits, Allocator>& _Left,
        basic_stringbuf<CharType, Traits, Allocator>& _Right
    ); 
template<class CharType, class Traits, class Allocator>
    void swap(
        basic_istringstream<CharType, Traits, Allocator>& _Left,
        basic_istringstream<CharType, Traits, Allocator>& _Right
    );
template<class CharType, class Traits, class Allocator>
    void swap(
        basic_ostringstream<CharType, Traits, Allocator>& _Left,
        basic_ostringstream<CharType, Traits, Allocator>& _Right
    );
template<class CharType, class Traits, class Allocator>
    void swap (
        basic_stringstream<CharType, Traits, Allocator>& _Left,
        basic_stringstream<CharType, Traits, Allocator>& _Right
    );
}  // namespace std

매개 변수

Parameter

설명

_Left

참조 하는 sstream 개체입니다.

_Right

참조 하는 sstream 개체입니다.

설명

개체 형식의 char * 기능을 사용할 수 있습니다 <strstream> 스트리밍.그러나 <strstream> 되지 않습니다 및 사용 <sstream> 되는 것이 좋습니다.

kb1es779.collapse_all(ko-kr,VS.110).gif형식 정의

istringstream

형식을 만듭니다 basic_istringstream 에 특수 한 char 템플릿 매개 변수.

ostringstream

형식을 만듭니다 basic_ostringstream 에 특수 한 char 템플릿 매개 변수.

stringbuf

형식을 만듭니다 basic_stringbuf 에 특수 한 char 템플릿 매개 변수.

stringstream

형식을 만듭니다 basic_stringstream 에 특수 한 char 템플릿 매개 변수.

wistringstream

형식을 만듭니다 basic_istringstream 에 특수 한 wchar_t 템플릿 매개 변수.

wostringstream

형식을 만듭니다 basic_ostringstream 에 특수 한 wchar_t 템플릿 매개 변수.

wstringbuf

형식을 만듭니다 basic_stringbuf 에 특수 한 wchar_t 템플릿 매개 변수.

wstringstream

형식을 만듭니다 basic_stringstream 에 특수 한 wchar_t 템플릿 매개 변수.

kb1es779.collapse_all(ko-kr,VS.110).gifManipulators

스왑

값이 두 개 사이 교환 sstream 개체입니다.

kb1es779.collapse_all(ko-kr,VS.110).gif클래스

basic_stringbuf

설명 형식 요소의 전송을 제어 하는 스트림 버퍼 Elem, 문자 특성은 클래스에 의해 결정 됩니다 Tr하 고 시퀀스의 요소를 array 개체에 저장 합니다.

basic_istringstream

인코딩된 스트림 버퍼 클래스의 개체 요소 추출 제어 개체 설명 basic_stringbuf<Elem, Tr, Alloc>, 형식 요소의 Elem, 해당 문자 특성 클래스에 의해 결정 됩니다 Tr, 및 요소는 클래스의 할당자에 의해 할당 Alloc.

basic_ostringstream

Object 요소 삽입 컨트롤 및 인코딩된 개체 클래스는 스트림 버퍼에 설명 basic_stringbuf<Elem, Tr, Alloc>, 형식 요소의 Elem, 해당 문자 특성 클래스에 의해 결정 됩니다 Tr, 및 요소는 클래스의 할당자에 의해 할당 Alloc.

basic_stringstream

삽입 및 추출 하는 요소를 제어 하는 개체와 스트림 버퍼 클래스를 사용 하 여 인코딩된 개체 설명 basic_stringbuf<Elem, Tr, Alloc>, 형식 요소의 Elem, 해당 문자 특성 클래스에 의해 결정 됩니다 Tr, 및 요소는 클래스의 할당자에 의해 할당 Alloc.

요구 사항

  • 헤더: <sstream>

  • 네임 스페이스: std

참고 항목

참조

표준 C++ 라이브러리에서 스레드로부터의 안전성

iostream 프로그래밍

iostreams 규칙

기타 리소스

헤더 파일