[Insight-developers] GlobalReleaseDataFlag and ReleaseData testing
Luis Ibanez
luis.ibanez at kitware.com
Thu Feb 19 10:26:01 EST 2009
Hi Brad,
Thanks for pointing this out.
I agree with you in that the methods:
void itk::DataObject::GlobalReleaseDataFlagOn()
void itk::DataObject::GlobalReleaseDataFlagOff()
should be static.
The only thing they are doing, is calling
another static method.
Luis
---------------------
Bradley Lowekamp wrote:
> Hello,
>
> I am working on this bug:
>
> http://www.itk.org/Bug/view.php?id=8490
>
> I wanted to verify my assertion, that this same bug would be problematic
> for the ReleaseData flag. So I searched to see what testing we do of that:
>
> victoria:Insight/Testing blowek1$ grep -R ReleaseData *
> Code/BasicFilters/itkThresholdImageFilterTest.cxx:
> random->ReleaseDataFlagOn();
>
> Thats not much testing of this option! So I am writing a test to do a
> little more testing of it. I notice that in in itkDataObject we have the
> following:
>
> static void SetGlobalReleaseDataFlag(const bool val);
> static bool GetGlobalReleaseDataFlag();
> void GlobalReleaseDataFlagOn()
> {this->SetGlobalReleaseDataFlag(true);}
> void GlobalReleaseDataFlagOff()
> {this->SetGlobalReleaseDataFlag(false);}
>
> I can't think of any reason why the On/Off methods are not static. It
> appears to be there since day one. Any objections to changing them to
> static?
>
> Brad
>
>
> ========================================================
>
> Bradley Lowekamp
>
> Lockheed Martin Contractor for
>
> Office of High Performance Computing and Communications
>
> National Library of Medicine
>
> blowekamp at mail.nih.gov <mailto:blowekamp at mail.nih.gov>
>
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ITK FAQ at: http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-developers
More information about the Insight-developers
mailing list