1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 #include <precomp.h>
23 #include "parsefct.hxx"
24 
25 
26 // NOT FULLY DECLARED SERVICES
27 #include <cpp/prs_cpp.hxx>
28 #include <adoc/prs_adoc.hxx>
29 #include <tools/filecoll.hxx>
30 
31 
32 DYN ParseToolsFactory * ParseToolsFactory::dpTheInstance_ = 0;
33 
34 
35 namespace autodoc
36 {
37 
38 ParseToolsFactory_Ifc &
GetIt_()39 ParseToolsFactory_Ifc::GetIt_()
40 {
41     if ( ParseToolsFactory::dpTheInstance_ == 0 )
42         ParseToolsFactory::dpTheInstance_ = new ParseToolsFactory;
43     return *ParseToolsFactory::dpTheInstance_;
44 }
45 
46 }   // namespace autodoc
47 
48 
ParseToolsFactory()49 ParseToolsFactory::ParseToolsFactory()
50 {
51 }
52 
~ParseToolsFactory()53 ParseToolsFactory::~ParseToolsFactory()
54 {
55 }
56 
57 DYN autodoc::CodeParser_Ifc *
Create_Parser_Cplusplus() const58 ParseToolsFactory::Create_Parser_Cplusplus() const
59 {
60     return new cpp::Cpluplus_Parser;
61 }
62 
63 DYN autodoc::DocumentationParser_Ifc *
Create_DocuParser_AutodocStyle() const64 ParseToolsFactory::Create_DocuParser_AutodocStyle() const
65 {
66     return new adoc::DocuParser_AutodocStyle;
67 }
68 
69 DYN autodoc::FileCollector_Ifc *
Create_FileCollector(uintt i_nEstimatedNrOfFiles) const70 ParseToolsFactory::Create_FileCollector( uintt i_nEstimatedNrOfFiles ) const
71 {
72     return new FileCollector(i_nEstimatedNrOfFiles);
73 }
74 
75 
76