cmCablePackageEntryCommand.cxx 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. /*=========================================================================
  2. Program: Insight Segmentation & Registration Toolkit
  3. Module: $RCSfile$
  4. Language: C++
  5. Date: $Date$
  6. Version: $Revision$
  7. Copyright (c) 2000 National Library of Medicine
  8. All rights reserved.
  9. See COPYRIGHT.txt for copyright details.
  10. =========================================================================*/
  11. #include "cmCablePackageEntryCommand.h"
  12. #include "cmCacheManager.h"
  13. // cmCablePackageEntryCommand
  14. bool cmCablePackageEntryCommand::Invoke(std::vector<std::string>& args)
  15. {
  16. if(args.size() < 1)
  17. {
  18. this->SetError("called with incorrect number of arguments");
  19. return false;
  20. }
  21. // This command instance needs to use the cmCableData instance.
  22. this->SetupCableData();
  23. // The arguments are the entries to the Pacakge.
  24. for(std::vector<std::string>::const_iterator arg = args.begin();
  25. arg != args.end(); ++arg)
  26. {
  27. m_Entries.push_back(*arg);
  28. }
  29. // Write this command's configuration.
  30. this->WriteConfiguration();
  31. return true;
  32. }