SimpleITK  
sitkCommand.h
Go to the documentation of this file.
1/*=========================================================================
2 *
3 * Copyright NumFOCUS
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0.txt
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 *
17 *=========================================================================*/
18#ifndef sitkCommand_h
19#define sitkCommand_h
20
21
22#include "sitkCommon.h"
23#include "sitkObjectOwnedBase.h"
24
25#include <set>
26
27namespace itk::simple
28{
29
30class ProcessObject;
31
45{
46public:
49
51 virtual ~Command() override;
52
54 std::string
55 GetName() const override;
56 void
57 SetName(const std::string & n) override;
58
60 virtual void
62
63protected:
65
66#ifndef SWIG
67 // internal methods to maintain reference between ProcessObject and
68 // Command, so when either is destroyed, the other will be notified.
69 //
70 // Return value is the number of referenced process objects after
71 // operation.
72 virtual size_t
74 virtual size_t
76
77#endif
78};
79
80} // namespace itk::simple
81
82#endif
virtual size_t RemoveProcessObject(const itk::simple::ProcessObject *o)
void SetName(const std::string &n) override
virtual void Execute()
Command()
Default Constructor.
std::string GetName() const override
virtual ~Command() override
virtual size_t AddProcessObject(itk::simple::ProcessObject *o)
Base class for SimpleITK classes based on ProcessObject.
#define SITKCommon_EXPORT
Definition sitkCommon.h:41