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