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 "hfi_typedef.hxx"
24 
25 
26 // NOT FULLY DEFINED SERVICES
27 #include <ary/idl/i_ce.hxx>
28 #include <ary/idl/ik_typedef.hxx>
29 #include <toolkit/hf_docentry.hxx>
30 #include <toolkit/hf_linachain.hxx>
31 #include <toolkit/hf_title.hxx>
32 #include "hfi_navibar.hxx"
33 #include "hfi_typetext.hxx"
34 #include "hi_linkhelper.hxx"
35 
36 
37 
HF_IdlTypedef(Environment & io_rEnv,Xml::Element & o_rOut)38 HF_IdlTypedef::HF_IdlTypedef( Environment &         io_rEnv,
39                               Xml::Element &        o_rOut )
40     :   HtmlFactory_Idl(io_rEnv, &o_rOut)
41 {
42 }
43 
~HF_IdlTypedef()44 HF_IdlTypedef::~HF_IdlTypedef()
45 {
46 }
47 
48 typedef ary::idl::ifc_typedef::attr TypedefAttr;
49 
50 void
Produce_byData(const client & i_ce) const51 HF_IdlTypedef::Produce_byData( const client & i_ce ) const
52 {
53     make_Navibar(i_ce);
54 
55     HF_TitleTable
56         aTitle(CurOut());
57 
58     HF_LinkedNameChain
59         aNameChain(aTitle.Add_Row());
60 
61     aNameChain.Produce_CompleteChain(Env().CurPosition(), nameChainLinker);
62     produce_Title(aTitle, C_sCePrefix_Typedef, i_ce);
63 
64     HF_DocEntryList
65         aTopList( aTitle.Add_Row() );
66     aTopList.Produce_Term("Defining Type");
67 
68     HF_IdlTypeText
69         aDefinition( Env(), aTopList.Produce_Definition(), true );
70     aDefinition.Produce_byData( TypedefAttr::DefiningType(i_ce) );
71 
72     CurOut() << new Html::HorizontalLine;
73 
74     write_Docu(aTitle.Add_Row(), i_ce);
75     CurOut() << new Html::HorizontalLine();
76 }
77 
78 void
make_Navibar(const client & i_ce) const79 HF_IdlTypedef::make_Navibar( const client & i_ce ) const
80 {
81     HF_IdlNavigationBar
82         aNaviBar(Env(), CurOut());
83     aNaviBar.Produce_CeMainRow(i_ce);
84 
85     CurOut() << new Html::HorizontalLine();
86 }
87