+/**
+ * \ingroup gdcmDicomDir
+ * \brief This predicate, based on hopefully reasonable heuristics,
+ * decides whether or not the current header was properly parsed
+ * and contains the mandatory information for being considered as
+ * a well formed and usable DicomDir.
+ * @return true when gdcmDocument is the one of a reasonable DicomDir,
+ * false otherwise.
+ */
+bool gdcmDicomDir::IsReadable(void)
+{
+ if(!gdcmDocument::IsReadable())
+ return(false);
+ if(!metaElems)
+ return(false);
+ if(patients.size()<=0)
+ return(false);
+
+ return(true);
+}
+
+/**
+ * \ingroup gdcmDicomDir
+ * \brief fills the whole structure, starting from a root Directory
+ */
+void gdcmDicomDir::ParseDirectory(void)
+{
+ CreateDicomDirChainedList(GetFileName());
+ CreateDicomDir();
+}
+
+/**
+ * \ingroup gdcmDicomDir
+ * \brief Set the start method to call when the parsing of the directory starts
+ * @param method Method to call
+ * @param arg Argument to pass to the method
+ * @param argDelete Argument
+ * \warning In python : the arg parameter isn't considered
+ */
+void gdcmDicomDir::SetStartMethod(gdcmMethod *method,void *arg,gdcmMethod *argDelete)
+{
+ if((startArg)&&(startMethodArgDelete))
+ startMethodArgDelete(startArg);
+
+ startMethod=method;
+ startArg=arg;
+ startMethodArgDelete=argDelete;
+}
+
+/**
+ * \ingroup gdcmDicomDir
+ * \brief Set the method to delete the argument
+ * The argument is destroyed when the method is changed or when the
+ * class is destroyed
+ * @param method Method to call to delete the argument
+ */
+void gdcmDicomDir::SetStartMethodArgDelete(gdcmMethod *method)
+{
+ startMethodArgDelete=method;
+}
+
+/**
+ * \ingroup gdcmDicomDir
+ * \brief Set the progress method to call when the parsing of the directory progress
+ * @param method Method to call
+ * @param arg Argument to pass to the method
+ * @param argDelete Argument
+ * \warning In python : the arg parameter isn't considered
+ */
+void gdcmDicomDir::SetProgressMethod(gdcmMethod *method,void *arg,gdcmMethod *argDelete)
+{
+ if((progressArg)&&(progressMethodArgDelete))
+ progressMethodArgDelete(progressArg);
+
+ progressMethod=method;
+ progressArg=arg;
+ progressMethodArgDelete=argDelete;
+}
+
+/**
+ * \ingroup gdcmDicomDir
+ * \brief Set the method to delete the argument
+ * The argument is destroyed when the method is changed or when the
+ * class is destroyed
+ * @param method Method to call to delete the argument
+ */
+void gdcmDicomDir::SetProgressMethodArgDelete(gdcmMethod *method)
+{
+ progressMethodArgDelete=method;
+}
+
+/**
+ * \ingroup gdcmDicomDir
+ * \brief Set the end method to call when the parsing of the directory ends
+ * @param method Method to call
+ * @param arg Argument to pass to the method
+ * @param argDelete Argument
+ * \warning In python : the arg parameter isn't considered
+ */
+void gdcmDicomDir::SetEndMethod(gdcmMethod *method, void *arg, gdcmMethod *argDelete)
+{
+ if((endArg)&&(endMethodArgDelete))
+ endMethodArgDelete(endArg);
+
+ endMethod=method;
+ endArg=arg;
+ endMethodArgDelete=argDelete;
+}
+
+/**
+ * \ingroup gdcmDicomDir
+ * \brief Set the method to delete the argument
+ * The argument is destroyed when the method is changed or when the class
+ * is destroyed
+ * @param method Method to call to delete the argument
+ */
+void gdcmDicomDir::SetEndMethodArgDelete(gdcmMethod *method)
+{
+ endMethodArgDelete=method;
+}
+