OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
3 * Copyright (C) 2009 Google Inc. All rights reserved. | 3 * Copyright (C) 2009 Google Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 class DequeIterator; | 44 class DequeIterator; |
45 template <typename T, size_t inlineCapacity, typename Allocator> | 45 template <typename T, size_t inlineCapacity, typename Allocator> |
46 class DequeConstIterator; | 46 class DequeConstIterator; |
47 | 47 |
48 template <typename T, | 48 template <typename T, |
49 size_t inlineCapacity = 0, | 49 size_t inlineCapacity = 0, |
50 typename Allocator = PartitionAllocator> | 50 typename Allocator = PartitionAllocator> |
51 class Deque : public ConditionalDestructor<Deque<T, INLINE_CAPACITY, Allocator>, | 51 class Deque : public ConditionalDestructor<Deque<T, INLINE_CAPACITY, Allocator>, |
52 (INLINE_CAPACITY == 0) && | 52 (INLINE_CAPACITY == 0) && |
53 Allocator::isGarbageCollected> { | 53 Allocator::isGarbageCollected> { |
54 WTF_USE_ALLOCATOR(Deque, Allocator); | 54 USE_ALLOCATOR(Deque, Allocator); |
55 | 55 |
56 public: | 56 public: |
57 typedef DequeIterator<T, inlineCapacity, Allocator> iterator; | 57 typedef DequeIterator<T, inlineCapacity, Allocator> iterator; |
58 typedef DequeConstIterator<T, inlineCapacity, Allocator> const_iterator; | 58 typedef DequeConstIterator<T, inlineCapacity, Allocator> const_iterator; |
59 typedef std::reverse_iterator<iterator> reverse_iterator; | 59 typedef std::reverse_iterator<iterator> reverse_iterator; |
60 typedef std::reverse_iterator<const_iterator> const_reverse_iterator; | 60 typedef std::reverse_iterator<const_iterator> const_reverse_iterator; |
61 | 61 |
62 Deque(); | 62 Deque(); |
63 Deque(const Deque&); | 63 Deque(const Deque&); |
64 Deque& operator=(const Deque&); | 64 Deque& operator=(const Deque&); |
(...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
664 inline void swap(Deque<T, inlineCapacity, Allocator>& a, | 664 inline void swap(Deque<T, inlineCapacity, Allocator>& a, |
665 Deque<T, inlineCapacity, Allocator>& b) { | 665 Deque<T, inlineCapacity, Allocator>& b) { |
666 a.swap(b); | 666 a.swap(b); |
667 } | 667 } |
668 | 668 |
669 } // namespace WTF | 669 } // namespace WTF |
670 | 670 |
671 using WTF::Deque; | 671 using WTF::Deque; |
672 | 672 |
673 #endif // WTF_Deque_h | 673 #endif // WTF_Deque_h |
OLD | NEW |