diff options
Diffstat (limited to 'Source/cmDependsJavaParserHelper.h')
-rw-r--r-- | Source/cmDependsJavaParserHelper.h | 31 |
1 files changed, 27 insertions, 4 deletions
diff --git a/Source/cmDependsJavaParserHelper.h b/Source/cmDependsJavaParserHelper.h index 171518e..551e29b 100644 --- a/Source/cmDependsJavaParserHelper.h +++ b/Source/cmDependsJavaParserHelper.h @@ -70,14 +70,37 @@ public: private: class CurrentClass - { + { public: cmStdString Name; - std::vector<CurrentClass> NestedClasses; - CurrentClass() {} + std::vector<CurrentClass>* NestedClasses; + CurrentClass() + { + this->NestedClasses = new std::vector<CurrentClass>; + } + ~CurrentClass() + { + delete this->NestedClasses; + } + CurrentClass& operator=(CurrentClass const& c) + { + this->NestedClasses->clear(); + this->Name = c.Name; + std::copy( + c.NestedClasses->begin(), + c.NestedClasses->end(), + std::back_inserter( + *this->NestedClasses) + ); + return *this; + } + CurrentClass(CurrentClass const& c) + { + (*this) = c; + } void AddFileNamesForPrinting(std::vector<cmStdString> *files, const char* prefix, const char* sep); - }; + }; cmStdString CurrentPackage; cmStdString::size_type InputBufferPos; cmStdString InputBuffer; |