]> Creatis software - gdcm.git/commitdiff
* remove ContentEntry::Write() code, yet the method is 'pure virtual'
authorjpr <jpr>
Wed, 26 Jan 2005 14:56:38 +0000 (14:56 +0000)
committerjpr <jpr>
Wed, 26 Jan 2005 14:56:38 +0000 (14:56 +0000)
  (coverage will be better ;-)

src/gdcmContentEntry.cxx

index 84794b41d6988a311452bcea9e3e04e496d161fb..3afeb1a313d5e6d128d3383dd643d20cd4ef294c 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmContentEntry.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/01/26 10:29:16 $
-  Version:   $Revision: 1.4 $
+  Date:      $Date: 2005/01/26 14:56:38 $
+  Version:   $Revision: 1.5 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -59,60 +59,6 @@ ContentEntry::~ContentEntry ()
 //-----------------------------------------------------------------------------
 // Public
 
-/**
- * \brief   Writes the 'std::string representable' value of a ContentEntry
- * @param fp already open ofstream pointer
- * @param filetype type of the file (ACR, ImplicitVR, ExplicitVR, ...)
- */
-void ContentEntry::WriteContent(std::ofstream *fp, FileType filetype)
-{
-   DocEntry::WriteContent(fp, filetype);
-
-   if ( GetGroup() == 0xfffe )
-   {
-      return; //delimitors have NO value
-   }
-
-   const VRKey &vr = GetVR();
-   unsigned int lgr = GetLength();
-   if (vr == "US" || vr == "SS")
-   {
-      // some 'Short integer' fields may be multivaluated
-      // each single value is separated from the next one by '\'
-      // we split the string and write each value as a short int
-      std::vector<std::string> tokens;
-      tokens.erase(tokens.begin(),tokens.end()); // clean any previous value
-      Util::Tokenize (GetValue(), tokens, "\\");
-      for (unsigned int i=0; i<tokens.size();i++)
-      {
-         uint16_t val_uint16 = atoi(tokens[i].c_str());
-         binary_write( *fp, val_uint16);
-      }
-      tokens.clear();
-      return;
-   }
-   if (vr == "UL" || vr == "SL")
-   {
-      // Some 'Integer' fields may be multivaluated (multiple instances 
-      // of integer). But each single integer value is separated from the
-      // next one by '\' (backslash character). Hence we split the string
-      // along the '\' and write each value as an int:
-      std::vector<std::string> tokens;
-      tokens.erase(tokens.begin(),tokens.end()); // clean any previous value
-      Util::Tokenize (GetValue(), tokens, "\\");
-      for (unsigned int i=0; i<tokens.size();i++)
-      {
-         uint32_t val_uint32 = atoi(tokens[i].c_str());
-         binary_write( *fp, val_uint32);
-      }
-      tokens.clear();
-      return;
-   } 
-
-   gdcmAssertMacro( lgr == GetValue().length() );
-   binary_write(*fp, GetValue());
-} 
-
 //-----------------------------------------------------------------------------
 // Protected