|
|
@ -51,6 +51,8 @@ namespace storm { |
|
|
|
return mId; |
|
|
|
} |
|
|
|
|
|
|
|
virtual DFTElementType type() const = 0; |
|
|
|
|
|
|
|
virtual void setRank(size_t rank) { |
|
|
|
mRank = rank; |
|
|
|
} |
|
|
@ -115,6 +117,10 @@ namespace storm { |
|
|
|
return !mParents.empty(); |
|
|
|
} |
|
|
|
|
|
|
|
size_t nrParents() const { |
|
|
|
return mParents.size(); |
|
|
|
} |
|
|
|
|
|
|
|
DFTGateVector const& parents() const { |
|
|
|
return mParents; |
|
|
|
} |
|
|
@ -349,6 +355,10 @@ namespace storm { |
|
|
|
DFTElement<ValueType>(id, name), mActiveFailureRate(failureRate), mPassiveFailureRate(dormancyFactor * failureRate) |
|
|
|
{} |
|
|
|
|
|
|
|
DFTElementType type() const override { |
|
|
|
return DFTElementType::BE; |
|
|
|
} |
|
|
|
|
|
|
|
virtual size_t nrChildren() const { |
|
|
|
return 0; |
|
|
|
} |
|
|
@ -394,6 +404,15 @@ namespace storm { |
|
|
|
DFTElement<ValueType>(id, name), mFailed(failed) |
|
|
|
{} |
|
|
|
|
|
|
|
DFTElementType type() const override { |
|
|
|
if(mFailed) { |
|
|
|
return DFTElementType::CONSTF; |
|
|
|
} else { |
|
|
|
return DFTElementType::CONSTS; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
bool failed() const { |
|
|
|
return mFailed; |
|
|
|
} |
|
|
@ -438,15 +457,15 @@ namespace storm { |
|
|
|
mDependentEvent = dependentEvent; |
|
|
|
} |
|
|
|
|
|
|
|
std::string nameTrigger() { |
|
|
|
std::string nameTrigger() const { |
|
|
|
return mNameTrigger; |
|
|
|
} |
|
|
|
|
|
|
|
std::string nameDependent() { |
|
|
|
std::string nameDependent() const { |
|
|
|
return mNameDependent; |
|
|
|
} |
|
|
|
|
|
|
|
ValueType probability() { |
|
|
|
ValueType const& probability() const { |
|
|
|
return mProbability; |
|
|
|
} |
|
|
|
|
|
|
@ -460,6 +479,10 @@ namespace storm { |
|
|
|
return mDependentEvent; |
|
|
|
} |
|
|
|
|
|
|
|
DFTElementType type() const override { |
|
|
|
return DFTElementType::PDEP; |
|
|
|
} |
|
|
|
|
|
|
|
virtual size_t nrChildren() const override { |
|
|
|
return 1; |
|
|
|
} |
|
|
@ -520,6 +543,10 @@ namespace storm { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
virtual DFTElementType type() const override { |
|
|
|
return DFTElementType::AND; |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const { |
|
|
|
return "AND"; |
|
|
|
} |
|
|
@ -556,6 +583,10 @@ namespace storm { |
|
|
|
this->failsafe(state, queues); |
|
|
|
} |
|
|
|
|
|
|
|
virtual DFTElementType type() const override { |
|
|
|
return DFTElementType::OR; |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const { |
|
|
|
return "OR"; |
|
|
|
} |
|
|
@ -607,7 +638,11 @@ namespace storm { |
|
|
|
//return false; |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const { |
|
|
|
virtual DFTElementType type() const override { |
|
|
|
return DFTElementType::SEQAND; |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const override { |
|
|
|
return "SEQAND"; |
|
|
|
} |
|
|
|
}; |
|
|
@ -654,7 +689,11 @@ namespace storm { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const { |
|
|
|
virtual DFTElementType type() const override { |
|
|
|
return DFTElementType::PAND; |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const override { |
|
|
|
return "PAND"; |
|
|
|
} |
|
|
|
}; |
|
|
@ -681,7 +720,11 @@ namespace storm { |
|
|
|
assert(false); |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const { |
|
|
|
virtual DFTElementType type() const override { |
|
|
|
return DFTElementType::POR; |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const override { |
|
|
|
return "POR"; |
|
|
|
} |
|
|
|
}; |
|
|
@ -741,6 +784,10 @@ namespace storm { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
virtual DFTElementType type() const override { |
|
|
|
return DFTElementType::VOT; |
|
|
|
} |
|
|
|
|
|
|
|
std::string typestring() const { |
|
|
|
return "VOT (" + std::to_string(mThreshold) + ")"; |
|
|
|
} |
|
|
@ -766,11 +813,15 @@ namespace storm { |
|
|
|
DFTGate<ValueType>(id, name, children) |
|
|
|
{} |
|
|
|
|
|
|
|
std::string typestring() const { |
|
|
|
std::string typestring() const override { |
|
|
|
return "SPARE"; |
|
|
|
} |
|
|
|
|
|
|
|
bool isSpareGate() const { |
|
|
|
virtual DFTElementType type() const override { |
|
|
|
return DFTElementType::SPARE; |
|
|
|
} |
|
|
|
|
|
|
|
bool isSpareGate() const override { |
|
|
|
return true; |
|
|
|
} |
|
|
|
|
|
|
|