1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-14 13:30:48 +03:00

0026850: Replace nested instantiations of TCollection generic classes by NCollection templates

Remaining instantiations of NCollection generics are converted to NCollection templates; unused and duplicates removed
This commit is contained in:
abv
2015-11-08 00:12:47 +03:00
parent 487bf1ceaa
commit 5d88fd549c
141 changed files with 146 additions and 8256 deletions

View File

@@ -17,267 +17,9 @@
#ifndef _IntPatch_SequenceOfIWLineOfTheIWalking_HeaderFile
#define _IntPatch_SequenceOfIWLineOfTheIWalking_HeaderFile
#include <Standard.hxx>
#include <Standard_DefineAlloc.hxx>
#include <Standard_Handle.hxx>
#include <TCollection_BaseSequence.hxx>
#include <Standard_Integer.hxx>
class Standard_NoSuchObject;
class Standard_OutOfRange;
class IntPatch_TheIWLineOfTheIWalking;
class IntPatch_SequenceNodeOfSequenceOfIWLineOfTheIWalking;
class IntPatch_SequenceOfIWLineOfTheIWalking : public TCollection_BaseSequence
{
public:
DEFINE_STANDARD_ALLOC
//! Constructs an empty sequence.
//! Use:
//! - the function Append or Prepend to add an item or
//! a collection of items at the end, or at the beginning of the sequence,
//! - the function InsertAfter or InsertBefore to add an
//! item or a collection of items at any position in the sequence,
//! - operator() or the function SetValue to assign a
//! new value to an item of the sequence,
//! - operator() to read an item of the sequence,
//! - the function Remove to remove an item at any
//! position in the sequence.
//! Warning
//! To copy a sequence, you must explicitly call the
//! assignment operator (operator=).
IntPatch_SequenceOfIWLineOfTheIWalking();
//! Creation by copy of existing Sequence.
Standard_EXPORT IntPatch_SequenceOfIWLineOfTheIWalking(const IntPatch_SequenceOfIWLineOfTheIWalking& Other);
//! Removes all element(s) of the sequence <me>
//! Example:
//! before
//! me = (A B C)
//! after
//! me = ()
Standard_EXPORT void Clear();
~IntPatch_SequenceOfIWLineOfTheIWalking()
{
Clear();
}
//! Copies the contents of the sequence Other into this sequence.
//! If this sequence is not empty, it is automatically cleared before the copy.
Standard_EXPORT const IntPatch_SequenceOfIWLineOfTheIWalking& Assign (const IntPatch_SequenceOfIWLineOfTheIWalking& Other);
const IntPatch_SequenceOfIWLineOfTheIWalking& operator = (const IntPatch_SequenceOfIWLineOfTheIWalking& Other)
{
return Assign(Other);
}
//! Appends <T> at the end of <me>.
//! Example:
//! before
//! me = (A B C)
//! after
//! me = (A B C T)
Standard_EXPORT void Append (const Handle(IntPatch_TheIWLineOfTheIWalking)& T);
//! Concatenates <S> at the end of <me>.
//! <S> is cleared.
//! Example:
//! before
//! me = (A B C)
//! S = (D E F)
//! after
//! me = (A B C D E F)
//! S = ()
void Append (IntPatch_SequenceOfIWLineOfTheIWalking& S);
//! Add <T> at the beginning of <me>.
//! Example:
//! before
//! me = (A B C)
//! after
//! me = (T A B C )
Standard_EXPORT void Prepend (const Handle(IntPatch_TheIWLineOfTheIWalking)& T);
//! Concatenates <S> at the beginning of <me>.
//! <S> is cleared.
//! Example:
//! before
//! me = (A B C) S = (D E F)
//! after me = (D E F A B C)
//! S = ()
void Prepend (IntPatch_SequenceOfIWLineOfTheIWalking& S);
//! Inserts <T> in <me> before the position <Index>.
//! Raises an exception if the index is out of bounds.
//! Example:
//! before
//! me = (A B D), Index = 3, T = C
//! after
//! me = (A B C D )
void InsertBefore (const Standard_Integer Index, const Handle(IntPatch_TheIWLineOfTheIWalking)& T);
//! Inserts the sequence <S> in <me> before
//! the position <Index>. <S> is cleared.
//! Raises an exception if the index is out of bounds
//! Example:
//! before
//! me = (A B F), Index = 3, S = (C D E)
//! after
//! me = (A B C D E F)
//! S = ()
void InsertBefore (const Standard_Integer Index, IntPatch_SequenceOfIWLineOfTheIWalking& S);
//! Inserts <T> in <me> after the position <Index>.
//! Raises an exception if the index is out of bound
//! Example:
//! before
//! me = (A B C), Index = 3, T = D
//! after
//! me = (A B C D)
Standard_EXPORT void InsertAfter (const Standard_Integer Index, const Handle(IntPatch_TheIWLineOfTheIWalking)& T);
//! Inserts the sequence <S> in <me> after the
//! position <Index>. <S> is cleared.
//! Raises an exception if the index is out of bound.
//! Example:
//! before
//! me = (A B C), Index = 3, S = (D E F)
//! after
//! me = (A B C D E F)
//! S = ()
void InsertAfter (const Standard_Integer Index, IntPatch_SequenceOfIWLineOfTheIWalking& S);
//! Returns the first element of the sequence <me>
//! Raises an exception if the sequence is empty.
//! Example:
//! before
//! me = (A B C)
//! after
//! me = (A B C)
//! returns A
Standard_EXPORT const Handle(IntPatch_TheIWLineOfTheIWalking)& First() const;
//! Returns the last element of the sequence <me>
//! Raises an exception if the sequence is empty.
//! Example:
//! before
//! me = (A B C)
//! after
//! me = (A B C)
//! returns C
Standard_EXPORT const Handle(IntPatch_TheIWLineOfTheIWalking)& Last() const;
//! Keeps in <me> the items 1 to <Index>-1 and
//! puts in <Sub> the items <Index> to the end.
//! Example:
//! before
//! me = (A B C D) ,Index = 3
//! after
//! me = (A B)
//! Sub = (C D)
void Split (const Standard_Integer Index, IntPatch_SequenceOfIWLineOfTheIWalking& Sub);
//! Returns the Item at position <Index> in <me>.
//! Raises an exception if the index is out of bound
//! Example:
//! before
//! me = (A B C), Index = 1
//! after
//! me = (A B C)
//! returns
//! A
Standard_EXPORT const Handle(IntPatch_TheIWLineOfTheIWalking)& Value (const Standard_Integer Index) const;
const Handle(IntPatch_TheIWLineOfTheIWalking)& operator() (const Standard_Integer Index) const
{
return Value(Index);
}
//! Changes the item at position <Index>
//! Raises an exception if the index is out of bound
//! Example:
//! before
//! me = (A B C), Index = 1, Item = D
//! after
//! me = (D B C)
Standard_EXPORT void SetValue (const Standard_Integer Index, const Handle(IntPatch_TheIWLineOfTheIWalking)& I);
//! Returns the Item at position <Index> in
//! <me>. This method may be used to modify
//! <me> : S.Value(Index) = Item.
//! Raises an exception if the index is out of bound
//! Example:
//! before
//! me = (A B C), Index = 1
//! after
//! me = (A B C)
//! returns
//! A
Standard_EXPORT Handle(IntPatch_TheIWLineOfTheIWalking)& ChangeValue (const Standard_Integer Index);
Handle(IntPatch_TheIWLineOfTheIWalking)& operator() (const Standard_Integer Index)
{
return ChangeValue(Index);
}
//! Removes from <me> the item at position <Index>.
//! Raises an exception if the index is out of bounds
//! Example:
//! before
//! me = (A B C), Index = 3
//! after
//! me = (A B)
Standard_EXPORT void Remove (const Standard_Integer Index);
//! Removes from <me> all the items of
//! positions between <FromIndex> and <ToIndex>.
//! Raises an exception if the indices are out of bounds.
//! Example:
//! before
//! me = (A B C D E F), FromIndex = 1 ToIndex = 3
//! after
//! me = (D E F)
Standard_EXPORT void Remove (const Standard_Integer FromIndex, const Standard_Integer ToIndex);
protected:
private:
};
#define SeqItem Handle(IntPatch_TheIWLineOfTheIWalking)
#define SeqItem_hxx <IntPatch_TheIWLineOfTheIWalking.hxx>
#define TCollection_SequenceNode IntPatch_SequenceNodeOfSequenceOfIWLineOfTheIWalking
#define TCollection_SequenceNode_hxx <IntPatch_SequenceNodeOfSequenceOfIWLineOfTheIWalking.hxx>
#define Handle_TCollection_SequenceNode Handle(IntPatch_SequenceNodeOfSequenceOfIWLineOfTheIWalking)
#define TCollection_Sequence IntPatch_SequenceOfIWLineOfTheIWalking
#define TCollection_Sequence_hxx <IntPatch_SequenceOfIWLineOfTheIWalking.hxx>
#include <TCollection_Sequence.lxx>
#undef SeqItem
#undef SeqItem_hxx
#undef TCollection_SequenceNode
#undef TCollection_SequenceNode_hxx
#undef Handle_TCollection_SequenceNode
#undef TCollection_Sequence
#undef TCollection_Sequence_hxx
#include <IntPatch_TheIWLineOfTheIWalking.hxx>
#include <NCollection_Sequence.hxx>
typedef NCollection_Sequence<Handle(IntPatch_TheIWLineOfTheIWalking)> IntPatch_SequenceOfIWLineOfTheIWalking;
#endif // _IntPatch_SequenceOfIWLineOfTheIWalking_HeaderFile