summaryrefslogtreecommitdiff
path: root/src/ChFiDS/ChFiDS_StripeMap.cxx
blob: fa6b7e4c6181257a4555bc073cbbadccce937d67 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
// File:	ChFiDS_StripeMap.cxx
// Created:	Thu Nov 18 11:51:01 1993
// Author:	Isabelle GRIGNON
//		<isg@zerox>


#include <ChFiDS_StripeMap.ixx>

//=======================================================================
//function : ChFiDS_StripeMap
//purpose  : 
//=======================================================================

ChFiDS_StripeMap::ChFiDS_StripeMap() 
{
}



//=======================================================================
//function : Add
//purpose  : 
//=======================================================================

void  ChFiDS_StripeMap::Add(const TopoDS_Vertex& V, 
			       const Handle(ChFiDS_Stripe)& F)
{
  Standard_Integer Index = mymap.FindIndex(V);
  if (Index==0) {
    ChFiDS_ListOfStripe Empty;
    Index = mymap.Add(V,Empty);
  }
  mymap(Index).Append(F);
}



//=======================================================================
//function : FindFromKey
//purpose  : 
//=======================================================================

const ChFiDS_ListOfStripe&  ChFiDS_StripeMap::FindFromKey(
						  const TopoDS_Vertex& V)const 
{
  return mymap.FindFromKey(V);
}



//=======================================================================
//function : FindFromIndex
//purpose  : 
//=======================================================================

const ChFiDS_ListOfStripe&  ChFiDS_StripeMap::
                               FindFromIndex(const Standard_Integer I)const 
{
  return mymap.FindFromIndex(I);
}

void ChFiDS_StripeMap::Clear()
{
  mymap.Clear();
}