summaryrefslogtreecommitdiff
path: root/cpp/src/slice2wsdl/Gen.h
blob: 8ea3c88424df2cc4c27fdec9a4663790433e84e9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
// **********************************************************************
//
// Copyright (c) 2001
// Mutable Realms, Inc.
// Huntsville, AL, USA
//
// All Rights Reserved
//
// **********************************************************************

#ifndef GEN_H
#define GEN_H

#include <Slice/Parser.h>
#include <stack>

namespace IceUtil
{

class XMLOutput;

}

namespace Slice
{

class Gen : public ::IceUtil::noncopyable, public ParserVisitor
{
public:

    Gen(const std::string&,
	const std::string&,
	const std::string&,
	const std::vector<std::string>&,
	const std::string&);
    virtual ~Gen();

    virtual bool visitClassDefStart(const ClassDefPtr&);

private:

    void emitMessage(::IceUtil::XMLOutput&, const OperationPtr&);
    void emitOperation(::IceUtil::XMLOutput&, const OperationPtr&);

    void printHeader(::IceUtil::XMLOutput&);

    std::string containedToId(const ContainedPtr&);

    std::string _name;
    std::string _base;
    std::string _include;
    std::string _orgName;
    std::vector<std::string> _includePaths;
    std::string _dir;
};

}

#endif