0026850: Replace nested instantiations of TCollection generic classes by NCollection...
[occt.git] / src / StepRepr / StepRepr_AssemblyComponentUsage.cxx
CommitLineData
b311480e 1// Created on: 2000-07-03
2// Created by: Andrey BETENEV
973c2be1 3// Copyright (c) 2000-2014 OPEN CASCADE SAS
b311480e 4//
973c2be1 5// This file is part of Open CASCADE Technology software library.
b311480e 6//
d5f74e42 7// This library is free software; you can redistribute it and/or modify it under
8// the terms of the GNU Lesser General Public License version 2.1 as published
973c2be1 9// by the Free Software Foundation, with special exception defined in the file
10// OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11// distribution for complete text of the license and disclaimer of any warranty.
b311480e 12//
973c2be1 13// Alternatively, this file may be used under the terms of Open CASCADE
14// commercial license or contractual agreement.
b311480e 15
7fd59977 16// Generator: ExpToCas (EXPRESS -> CASCADE/XSTEP Translator) V1.1
7fd59977 17
42cf5bc1 18#include <Standard_Type.hxx>
19#include <StepBasic_ProductDefinition.hxx>
20#include <StepRepr_AssemblyComponentUsage.hxx>
21#include <TCollection_HAsciiString.hxx>
7fd59977 22
23//=======================================================================
24//function : StepRepr_AssemblyComponentUsage
25//purpose :
26//=======================================================================
7fd59977 27StepRepr_AssemblyComponentUsage::StepRepr_AssemblyComponentUsage ()
28{
29 defReferenceDesignator = Standard_False;
30}
31
32//=======================================================================
33//function : Init
34//purpose :
35//=======================================================================
36
37void StepRepr_AssemblyComponentUsage::Init (const Handle(TCollection_HAsciiString) &aProductDefinitionRelationship_Id,
38 const Handle(TCollection_HAsciiString) &aProductDefinitionRelationship_Name,
39 const Standard_Boolean hasProductDefinitionRelationship_Description,
40 const Handle(TCollection_HAsciiString) &aProductDefinitionRelationship_Description,
41 const Handle(StepBasic_ProductDefinition) &aProductDefinitionRelationship_RelatingProductDefinition,
42 const Handle(StepBasic_ProductDefinition) &aProductDefinitionRelationship_RelatedProductDefinition,
43 const Standard_Boolean hasReferenceDesignator,
44 const Handle(TCollection_HAsciiString) &aReferenceDesignator)
45{
46 StepRepr_ProductDefinitionUsage::Init(aProductDefinitionRelationship_Id,
47 aProductDefinitionRelationship_Name,
48 hasProductDefinitionRelationship_Description,
49 aProductDefinitionRelationship_Description,
50 aProductDefinitionRelationship_RelatingProductDefinition,
51 aProductDefinitionRelationship_RelatedProductDefinition);
52
53 defReferenceDesignator = hasReferenceDesignator;
54 if (defReferenceDesignator) {
55 theReferenceDesignator = aReferenceDesignator;
56 }
57 else theReferenceDesignator.Nullify();
58}
59
60//=======================================================================
61//function : ReferenceDesignator
62//purpose :
63//=======================================================================
64
65Handle(TCollection_HAsciiString) StepRepr_AssemblyComponentUsage::ReferenceDesignator () const
66{
67 return theReferenceDesignator;
68}
69
70//=======================================================================
71//function : SetReferenceDesignator
72//purpose :
73//=======================================================================
74
75void StepRepr_AssemblyComponentUsage::SetReferenceDesignator (const Handle(TCollection_HAsciiString) &aReferenceDesignator)
76{
77 theReferenceDesignator = aReferenceDesignator;
78}
79
80//=======================================================================
81//function : HasReferenceDesignator
82//purpose :
83//=======================================================================
84
85Standard_Boolean StepRepr_AssemblyComponentUsage::HasReferenceDesignator () const
86{
87 return defReferenceDesignator;
88}