+/**
+ * \brief Constructor
+ * \note End user must use : DicomDirPatient::NewStudy()
+ */
+DicomDirStudy::DicomDirStudy(bool empty)
+ :DicomDirObject()
+{
+ if ( !empty )
+ {
+ ListDicomDirStudyElem const &elemList =
+ Global::GetDicomDirElements()->GetDicomDirStudyElements();
+ FillObject(elemList);
+ }
+}
+
+/**
+ * \brief Canonical destructor.
+ */
+DicomDirStudy::~DicomDirStudy()
+{
+ ClearSerie();
+}
+
+//-----------------------------------------------------------------------------
+// Public
+/**
+ * \brief Writes the Object
+ * @param fp ofstream to write to
+ * @param t Type of the File (explicit VR, implicitVR, ...)
+ * @return
+ */
+void DicomDirStudy::WriteContent(std::ofstream *fp, FileType t, bool , bool )
+{
+ DicomDirObject::WriteContent(fp, t, false, true);
+
+ for(ListDicomDirSerie::iterator cc = Series.begin();
+ cc!= Series.end();
+ ++cc )
+ {
+ (*cc)->WriteContent( fp, t, false, true );
+ }
+
+ for(ListDicomDirVisit::iterator icc = Visits.begin();
+ icc!= Visits.end();
+ ++icc )
+ {
+ (*icc)->WriteContent( fp, t, false, true );
+ }
+}