1.2.840.10008.1.2.4.90 JPEG 2000 Image Compression (Lossless Only)
1.2.840.10008.1.2.4.91 JPEG 2000 Image Compression
1.2.840.10008.1.2.5 RLE Lossless
-1.2.840.113619.5.2 Implicit VR - Little Endian GE DLX xadc
+1.2.840.113619.5.2 Implicit VR - Big Endian (GE Private)
1.2.840.10008.1.1 Verification SOP Class
1.2.840.10008.1.3.10 Media Storage Directory Storage
logical blocks of code with the concerned comments.
- Use parantheses around conditions e.g. with an if statement:
if ( someLocalVariable == 2 ) { ... }
- - Add spaces around parantheses, or braces. Use
+ - Add spaces around parentheses, or braces. Use
if ( someLocalVariable == 2 ) { ClassMenber += 1; }
and not
if (someLocalVariable == 2) {ClassMenber += 1;}
* dictionaries), look for the element value representation of
* a given tag.
* @param group Group number of the searched tag.
- * @param element Element number of the searched tag.
+ * @param elem Element number of the searched tag.
* @return Corresponding element value representation when it exists,
* and the string "gdcm::Unfound" otherwise.
*/
- std::string Document::GetEntryByNumber(guint16 group, guint16 element)
+ std::string Document::GetEntryByNumber(guint16 group, guint16 elem)
{
...
}
warnings won't work).
- Don't use the C standard library. Don't include stdio.h, ctype.h...
Don't use printf(), sprinf(), FILE*...
- - Don't use the NULL notation (either as macro, or as const int NULL=0).
+ - Don't use the NULL notation (neither as macro, nor as const int NULL=0).
A pointer that doesn't refer to an object should simply be defined as
DataPointer* MyDataPointer = 0;
* Basic types:
- Assume T is a given type. When declaring or defining with the
"pointer to T" notation, the * character must be adjacent to
- the type and not the variable. That is use
+ the variable and not the type. That is use
+ T *foo = 0;
+ and not
T* foo = 0;
+ - Assume T is a given type. When declaring or defining with the
+ "reference to T" notation, the & character must be adjacent to
+ the variable and not the type. That is use
+ T &foo = 0;
and not
- T *foo = 0;
+ T& foo = 0;
+ This is the common notation, not a 'gdcm special' notation.
+ (doxygen will not have any longer to correct)
+
- Always define a typedef for a new type and be consistent in usage.
Use
typedef Header* HeaderPointer;
Program: gdcm
Module: $RCSfile: gdcmBase.cxx,v $
Language: C++
- Date: $Date: 2004/12/21 15:16:07 $
- Version: $Revision: 1.2 $
+ Date: $Date: 2005/01/06 17:08:06 $
+ Version: $Revision: 1.3 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
* \brief Print all the object
* @param os The output stream to be written to.
*/
-void Base::Print(std::ostream &)
+void Base::Print(std::ostream & os)
{
}
Program: gdcm
Module: $RCSfile: gdcmDict.cxx,v $
Language: C++
- Date: $Date: 2004/11/16 02:54:35 $
- Version: $Revision: 1.52 $
+ Date: $Date: 2005/01/06 17:08:06 $
+ Version: $Revision: 1.53 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
//-----------------------------------------------------------------------------
// Constructor / Destructor
/**
- * \brief Construtor
+ * \brief Constructor
* @param filename from which to build the dictionary.
*/
-Dict::Dict(std::string const & filename)
+Dict::Dict(std::string const &filename)
{
uint16_t group;
uint16_t element;
* unpredictable result
* @param os The output stream to be written to.
*/
-void Dict::PrintByName(std::ostream& os)
+void Dict::PrintByName(std::ostream &os)
{
std::ostringstream s;
* @param newEntry entry to add
* @return false if Dicom Element already exists
*/
-bool Dict::AddNewEntry(DictEntry const & newEntry)
+bool Dict::AddNewEntry(DictEntry const &newEntry)
{
- const TagKey & key = newEntry.GetKey();
+ const TagKey &key = newEntry.GetKey();
if(KeyHt.count(key) == 1)
{
* @param newEntry new entry (overwrites any previous one with same tag)
* @return false if Dicom Element doesn't exist
*/
-bool Dict::ReplaceEntry(DictEntry const & newEntry)
+bool Dict::ReplaceEntry(DictEntry const &newEntry)
{
if ( RemoveEntry(newEntry.GetKey()) )
{
* @param key (group|element)
* @return false if Dicom Dictionary Entry doesn't exist
*/
-bool Dict::RemoveEntry (TagKey const & key)
+bool Dict::RemoveEntry (TagKey const &key)
{
TagKeyHT::const_iterator it = KeyHt.find(key);
if(it != KeyHt.end())
* the name MAY CHANGE between two versions !
* @return the corresponding dictionnary entry when existing, NULL otherwise
*/
-DictEntry* Dict::GetDictEntryByName(TagName const & name)
+DictEntry *Dict::GetDictEntryByName(TagName const &name)
{
TagNameHT::iterator it = NameHt.find(name);
if ( it == NameHt.end() )
* @param element element of the entry to be found
* @return the corresponding dictionnary entry when existing, NULL otherwise
*/
-DictEntry* Dict::GetDictEntryByNumber(uint16_t group, uint16_t element)
+DictEntry *Dict::GetDictEntryByNumber(uint16_t group, uint16_t element)
{
TagKey key = DictEntry::TranslateToKey(group, element);
TagKeyHT::iterator it = KeyHt.find(key);
* \sa DictSet::GetPubDictTagNamesByCategory
* @return A list of all entries of the public dicom dictionnary.
*/
-EntryNamesList* Dict::GetDictEntryNames()
+EntryNamesList *Dict::GetDictEntryNames()
{
EntryNamesList *result = new EntryNamesList;
for (TagKeyHT::iterator tag = KeyHt.begin(); tag != KeyHt.end(); ++tag)