-// Copyright (C) 2006-2016 CEA/DEN, EDF R&D
+// Copyright (C) 2006-2023 CEA, EDF
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
repr.insert(s.begin(),s.end());
}
-void *InputPort4DF2DS::get() const throw(YACS::Exception)
+void *InputPort4DF2DS::get() const
{
if(!_data)
{
_initValue->incrRef();
}
-void InputPort4DF2DS::put(const void *data) throw(ConversionException)
+void InputPort4DF2DS::put(const void *data)
{
put((Any *)data);
}
throw Exception("InputPort4DF2DS::clone : internal error");
}
-void InputPort4DF2DS::put(Any *data)
+void InputPort4DF2DS::releaseData()
{
if(_data)
_data->decrRef();
+ _data = nullptr;
+}
+
+void InputPort4DF2DS::put(Any *data)
+{
+ InputPort4DF2DS::releaseData();
_data=data;
_data->incrRef();
}
{
}
-InputPort *DFToDSForLoop::getInputPort(const std::string& name) const throw(YACS::Exception)
+InputPort *DFToDSForLoop::getInputPort(const std::string& name) const
{
try {
return Node::getInputPort(name);
return (*it);
}
-OutputDataStreamPort *DFToDSForLoop::getOutputDataStreamPort(const std::string& name) const throw(YACS::Exception)
+OutputDataStreamPort *DFToDSForLoop::getOutputDataStreamPort(const std::string& name) const
{
list<OutputDataStreamPort *>::const_iterator it =_setOfOutputDataStreamPort.begin();
return (*it);
(*iter)->getAllRepresented(represented);
}
-void OutputPort4DS2DF::put(const void *data) throw(ConversionException)
+void OutputPort4DS2DF::put(const void *data)
{
put((Any *)data);
OutputPort::put(data);
{
}
-OutputPort *DSToDFForLoop::getOutputPort(const std::string& name) const throw(YACS::Exception)
+OutputPort *DSToDFForLoop::getOutputPort(const std::string& name) const
{
list<OutputPort *>::const_iterator it = _setOfOutputPort.begin();
return (*it);
}
-InputDataStreamPort *DSToDFForLoop::getInputDataStreamPort(const std::string& name) const throw(YACS::Exception)
+InputDataStreamPort *DSToDFForLoop::getInputDataStreamPort(const std::string& name) const
{
list<InputDataStreamPort *>::const_iterator it = _setOfInputDataStreamPort.begin();
return (*it);
return ret;
}
-bool Loop::edAddChild(Node *node) throw(YACS::Exception)
+bool Loop::edAddChild(Node *node)
{
return edSetNode(node);
}
}
}
-void Loop::edRemoveChild(Node *node) throw(YACS::Exception)
+void Loop::edRemoveChild(Node *node)
{
StaticDefinedComposedNode::edRemoveChild(node);
if(_node==node)
return _node->getMaxLevelOfParallelism();
}
-double Loop::getWeightRegardingDPL() const
+void Loop::getWeightRegardingDPL(ComplexWeight *weight)
{
- if(!_node)
- return 0.;
- return _node->getWeightRegardingDPL();
+ if(_node)
+ _node->getWeightRegardingDPL(weight);
}
void Loop::partitionRegardingDPL(const PartDefinition *pd, std::map<ComposedNode *, YACS::BASES::AutoRefCnt<PartDefinition> >& zeMap)
_node->partitionRegardingDPL(pd,zeMap);
}
-Node *Loop::getChildByShortName(const std::string& name) const throw(YACS::Exception)
+Node *Loop::getChildByShortName(const std::string& name) const
{
if (_node)
if(name==_node->getName())
throw Exception(what);
}
-TypeCode* Loop::MappingDF2DS(TypeCode* type) throw(YACS::Exception)
+TypeCode* Loop::MappingDF2DS(TypeCode* type)
{
return type;
}
-TypeCode* Loop::MappingDS2DF(TypeCode* type) throw(YACS::Exception)
+TypeCode* Loop::MappingDS2DF(TypeCode* type)
{
return type;
}
port.first=(*iter)->getOutputDataStreamPort("");
}
-void Loop::getDelegateOf(InPort * & port, OutPort *initialStart, const std::list<ComposedNode *>& pointsOfView) throw(YACS::Exception)
+void Loop::getDelegateOf(InPort * & port, OutPort *initialStart, const std::list<ComposedNode *>& pointsOfView)
{
string typeOfPortInstance=port->getNameOfTypeOfCurrentInstance();
if(typeOfPortInstance!=InputPort::NAME ||
}
void Loop::getDelegateOf(std::pair<OutPort *, OutPort *>& port, InPort *finalTarget,
- const std::list<ComposedNode *>& pointsOfView) throw(YACS::Exception)
+ const std::list<ComposedNode *>& pointsOfView)
{
string typeOfPortInstance=(port.first)->getNameOfTypeOfCurrentInstance();
if(typeOfPortInstance!=OutputPort::NAME ||
port.first=(*iter)->getOutputDataStreamPort("");
}
-void Loop::releaseDelegateOf(InPort * & port, OutPort *initialStart, const std::list<ComposedNode *>& pointsOfView) throw(YACS::Exception)
+void Loop::releaseDelegateOf(InPort * & port, OutPort *initialStart, const std::list<ComposedNode *>& pointsOfView)
{
string typeOfPortInstance=port->getNameOfTypeOfCurrentInstance();
if(typeOfPortInstance!=InputPort::NAME ||
}
}
-void Loop::releaseDelegateOf(OutPort *portDwn, OutPort *portUp, InPort *finalTarget, const std::list<ComposedNode *>& pointsOfView) throw(YACS::Exception)
+void Loop::releaseDelegateOf(OutPort *portDwn, OutPort *portUp, InPort *finalTarget, const std::list<ComposedNode *>& pointsOfView)
{
if(portDwn==portUp)
return ;
}
}
-void Loop::checkNoCyclePassingThrough(Node *node) throw(YACS::Exception)
+void Loop::checkNoCyclePassingThrough(Node *node)
{
//throw Exception("Loop::checkNoCyclePassingThrough : Internal error occured");
}
* \param end : the InPort to connect
* \return true if a new link has been created, false otherwise.
*/
-bool Loop::edAddDFLink(OutPort *start, InPort *end) throw(YACS::Exception)
+bool Loop::edAddDFLink(OutPort *start, InPort *end)
{
return edAddLink(start,end);
}
fw[(ComposedNode *)this].push_back(start);
}
-void Loop::checkBasicConsistency() const throw(YACS::Exception)
+void Loop::checkBasicConsistency() const
{
DEBTRACE("Loop::checkBasicConsistency");
ComposedNode::checkBasicConsistency();