00001 /* 00002 * 00003 * Copyright (c) 1994 00004 * Hewlett-Packard Company 00005 * 00006 * Permission to use, copy, modify, distribute and sell this software 00007 * and its documentation for any purpose is hereby granted without fee, 00008 * provided that the above copyright notice appear in all copies and 00009 * that both that copyright notice and this permission notice appear 00010 * in supporting documentation. Hewlett-Packard Company makes no 00011 * representations about the suitability of this software for any 00012 * purpose. It is provided "as is" without express or implied warranty. 00013 * 00014 * 00015 * Copyright (c) 1996 00016 * Silicon Graphics Computer Systems, Inc. 00017 * 00018 * Permission to use, copy, modify, distribute and sell this software 00019 * and its documentation for any purpose is hereby granted without fee, 00020 * provided that the above copyright notice appear in all copies and 00021 * that both that copyright notice and this permission notice appear 00022 * in supporting documentation. Silicon Graphics makes no 00023 * representations about the suitability of this software for any 00024 * purpose. It is provided "as is" without express or implied warranty. 00025 */ 00026 00027 /* NOTE: This is an internal header file, included by other STL headers. 00028 * You should not attempt to use it directly. 00029 */ 00030 00031 #ifndef _CPP_BITS_STL_RAW_STORAGE_ITERATOR_H 00032 #define _CPP_BITS_STL_RAW_STORAGE_ITERATOR_H 1 00033 00034 namespace std 00035 { 00036 00037 template <class _ForwardIterator, class _Tp> 00038 class raw_storage_iterator { 00039 protected: 00040 _ForwardIterator _M_iter; 00041 public: 00042 typedef output_iterator_tag iterator_category; 00043 typedef void value_type; 00044 typedef void difference_type; 00045 typedef void pointer; 00046 typedef void reference; 00047 00048 explicit raw_storage_iterator(_ForwardIterator __x) : _M_iter(__x) {} 00049 raw_storage_iterator& operator*() { return *this; } 00050 raw_storage_iterator& operator=(const _Tp& __element) { 00051 construct(&*_M_iter, __element); 00052 return *this; 00053 } 00054 raw_storage_iterator<_ForwardIterator, _Tp>& operator++() { 00055 ++_M_iter; 00056 return *this; 00057 } 00058 raw_storage_iterator<_ForwardIterator, _Tp> operator++(int) { 00059 raw_storage_iterator<_ForwardIterator, _Tp> __tmp = *this; 00060 ++_M_iter; 00061 return __tmp; 00062 } 00063 }; 00064 00065 00066 } // namespace std 00067 00068 #endif /* _CPP_BITS_STL_RAW_STORAGE_ITERATOR_H */ 00069 00070 // Local Variables: 00071 // mode:C++ 00072 // End: