c++(STL) 에서 type 정의에 관한 질문
글쓴이: vigor96 / 작성시간: 목, 2003/06/05 - 11:48오전
vector<T>::const_iterator
와 같은 것이 type 이 될 수 있다고 하던데...
vector<T>::value_type
vector<T>::pointer
vector<T>::reference 이런 것들이요...
이런 것이 어떻게 정의가 되어 있어서 ..
type 이 될 수가 있는 건지 궁금합니다.
typedef 로 되어 있을 거라고 어느 정도 예상은 해보지만.
:: 는 static 변수나 static 함수에 접근할 때
쓰는 것으로 알고만 있었던 지라 혼란이 오네요..
답변 부탁드립니다.
Forums:
소스를 간단하게 보시면 [code:1]class Vector
소스를 간단하게 보시면
이렇게 되어있답니다. 결국 하나의 클래스죠 ^^
=========================
CharSyam ^^ --- 고운 하루
=========================
답은....
C++ Standard Library에 잘 나와 있습니다
내부 class로 되어 있는것도 있지만
Reference 그런것은 typedef로 되어 있는것도 있습니다
승자는 자기보다 우월한 사람을 보면 존경심을 갖고 그로부터 배울 점을 찾지만 패자는 자기보다 우월한 사람을 만나면 질투심을 갖고 어디 구멍난 곳이 없는지 찾는다.
- 하비스
댓글 달기