1*0841af79SAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*0841af79SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*0841af79SAndrew Rist * or more contributor license agreements. See the NOTICE file 5*0841af79SAndrew Rist * distributed with this work for additional information 6*0841af79SAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*0841af79SAndrew Rist * to you under the Apache License, Version 2.0 (the 8*0841af79SAndrew Rist * "License"); you may not use this file except in compliance 9*0841af79SAndrew Rist * with the License. You may obtain a copy of the License at 10cdf0e10cSrcweir * 11*0841af79SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12cdf0e10cSrcweir * 13*0841af79SAndrew Rist * Unless required by applicable law or agreed to in writing, 14*0841af79SAndrew Rist * software distributed under the License is distributed on an 15*0841af79SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*0841af79SAndrew Rist * KIND, either express or implied. See the License for the 17*0841af79SAndrew Rist * specific language governing permissions and limitations 18*0841af79SAndrew Rist * under the License. 19cdf0e10cSrcweir * 20*0841af79SAndrew Rist *************************************************************/ 21cdf0e10cSrcweir 22cdf0e10cSrcweir #include <precomp.h> 23cdf0e10cSrcweir #include "hfi_property.hxx" 24cdf0e10cSrcweir 25cdf0e10cSrcweir 26cdf0e10cSrcweir // NOT FULLY DEFINED SERVICES 27cdf0e10cSrcweir #include <ary/idl/i_ce.hxx> 28cdf0e10cSrcweir #include <ary/idl/ik_attribute.hxx> 29cdf0e10cSrcweir #include <ary/idl/ik_constant.hxx> 30cdf0e10cSrcweir #include <ary/idl/ik_enumvalue.hxx> 31cdf0e10cSrcweir #include <ary/idl/ik_property.hxx> 32cdf0e10cSrcweir #include <ary/idl/ik_structelem.hxx> 33cdf0e10cSrcweir #include <toolkit/hf_docentry.hxx> 34cdf0e10cSrcweir #include <toolkit/hf_title.hxx> 35cdf0e10cSrcweir #include "hfi_typetext.hxx" 36cdf0e10cSrcweir #include "hfi_doc.hxx" 37cdf0e10cSrcweir #include "hfi_tag.hxx" 38cdf0e10cSrcweir #include "hi_env.hxx" 39cdf0e10cSrcweir #include "hi_ary.hxx" 40cdf0e10cSrcweir #include "hi_linkhelper.hxx" 41cdf0e10cSrcweir 42cdf0e10cSrcweir void 43cdf0e10cSrcweir HF_IdlDataMember::Produce_byData( const client & ce ) const 44cdf0e10cSrcweir { 45cdf0e10cSrcweir write_Title(ce); 46cdf0e10cSrcweir enter_ContentCell(); 47cdf0e10cSrcweir write_Declaration(ce); 48cdf0e10cSrcweir write_Description(ce); 49cdf0e10cSrcweir leave_ContentCell(); 50cdf0e10cSrcweir } 51cdf0e10cSrcweir 52cdf0e10cSrcweir HF_IdlDataMember::HF_IdlDataMember( Environment & io_rEnv, 53cdf0e10cSrcweir HF_SubTitleTable & o_table ) 54cdf0e10cSrcweir : HtmlFactory_Idl( io_rEnv, 55cdf0e10cSrcweir &(o_table.Add_Row() 56cdf0e10cSrcweir >> *new Html::TableCell 57cdf0e10cSrcweir << new Html::ClassAttr(C_sCellStyle_MDetail)) 58cdf0e10cSrcweir ) 59cdf0e10cSrcweir { 60cdf0e10cSrcweir } 61cdf0e10cSrcweir 62cdf0e10cSrcweir const String sContentBorder("0"); 63cdf0e10cSrcweir const String sContentWidth("96%"); 64cdf0e10cSrcweir const String sContentPadding("5"); 65cdf0e10cSrcweir const String sContentSpacing("0"); 66cdf0e10cSrcweir 67cdf0e10cSrcweir const String sBgWhite("#ffffff"); 68cdf0e10cSrcweir const String sCenter("center"); 69cdf0e10cSrcweir 70cdf0e10cSrcweir void 71cdf0e10cSrcweir HF_IdlDataMember::write_Title( const client & i_ce ) const 72cdf0e10cSrcweir { 73cdf0e10cSrcweir CurOut() 74cdf0e10cSrcweir >> *new Html::Label(i_ce.LocalName()) 75cdf0e10cSrcweir << new Html::ClassAttr(C_sMemberTitle) 76cdf0e10cSrcweir << i_ce.LocalName(); 77cdf0e10cSrcweir } 78cdf0e10cSrcweir 79cdf0e10cSrcweir void 80cdf0e10cSrcweir HF_IdlDataMember::write_Description( const client & i_ce ) const 81cdf0e10cSrcweir { 82cdf0e10cSrcweir CurOut() << new Html::HorizontalLine; 83cdf0e10cSrcweir write_Docu(CurOut(), i_ce); 84cdf0e10cSrcweir } 85cdf0e10cSrcweir 86cdf0e10cSrcweir void 87cdf0e10cSrcweir HF_IdlDataMember::enter_ContentCell() const 88cdf0e10cSrcweir { 89cdf0e10cSrcweir 90cdf0e10cSrcweir Xml::Element & 91cdf0e10cSrcweir rContentCell = CurOut() 92cdf0e10cSrcweir >> *new Html::Table( sContentBorder, 93cdf0e10cSrcweir sContentWidth, 94cdf0e10cSrcweir sContentPadding, 95cdf0e10cSrcweir sContentSpacing ) 96cdf0e10cSrcweir << new Html::ClassAttr("table-in-data") 97cdf0e10cSrcweir << new Html::BgColorAttr(sBgWhite) 98cdf0e10cSrcweir << new Html::AlignAttr(sCenter) 99cdf0e10cSrcweir >> *new Html::TableRow 100cdf0e10cSrcweir >> *new Html::TableCell; 101cdf0e10cSrcweir Out().Enter(rContentCell); 102cdf0e10cSrcweir } 103cdf0e10cSrcweir 104cdf0e10cSrcweir 105cdf0e10cSrcweir void 106cdf0e10cSrcweir HF_IdlDataMember::leave_ContentCell() const 107cdf0e10cSrcweir { 108cdf0e10cSrcweir Out().Leave(); 109cdf0e10cSrcweir } 110cdf0e10cSrcweir 111cdf0e10cSrcweir 112cdf0e10cSrcweir HF_IdlProperty::~HF_IdlProperty() 113cdf0e10cSrcweir { 114cdf0e10cSrcweir } 115cdf0e10cSrcweir 116cdf0e10cSrcweir typedef ary::idl::ifc_property::attr PropertyAttr; 117cdf0e10cSrcweir 118cdf0e10cSrcweir void 119cdf0e10cSrcweir HF_IdlProperty::write_Declaration( const client & i_ce ) const 120cdf0e10cSrcweir { 121cdf0e10cSrcweir if (PropertyAttr::HasAnyStereotype(i_ce)) 122cdf0e10cSrcweir { 123cdf0e10cSrcweir CurOut() << "[ "; 124cdf0e10cSrcweir if (PropertyAttr::IsReadOnly(i_ce)) 125cdf0e10cSrcweir CurOut() << "readonly "; 126cdf0e10cSrcweir if (PropertyAttr::IsBound(i_ce)) 127cdf0e10cSrcweir CurOut() << "bound "; 128cdf0e10cSrcweir if (PropertyAttr::IsConstrained(i_ce)) 129cdf0e10cSrcweir CurOut() << "constrained "; 130cdf0e10cSrcweir if (PropertyAttr::IsMayBeAmbiguous(i_ce)) 131cdf0e10cSrcweir CurOut() << "maybeambiguous "; 132cdf0e10cSrcweir if (PropertyAttr::IsMayBeDefault(i_ce)) 133cdf0e10cSrcweir CurOut() << "maybedefault "; 134cdf0e10cSrcweir if (PropertyAttr::IsMayBeVoid(i_ce)) 135cdf0e10cSrcweir CurOut() << "maybevoid "; 136cdf0e10cSrcweir if (PropertyAttr::IsRemovable(i_ce)) 137cdf0e10cSrcweir CurOut() << "removable "; 138cdf0e10cSrcweir if (PropertyAttr::IsTransient(i_ce)) 139cdf0e10cSrcweir CurOut() << "transient "; 140cdf0e10cSrcweir CurOut() << "] "; 141cdf0e10cSrcweir } // end if 142cdf0e10cSrcweir 143cdf0e10cSrcweir HF_IdlTypeText 144cdf0e10cSrcweir aType( Env(), CurOut(), true ); 145cdf0e10cSrcweir aType.Produce_byData( PropertyAttr::Type(i_ce) ); 146cdf0e10cSrcweir 147cdf0e10cSrcweir CurOut() << " " >> *new Html::Bold << i_ce.LocalName(); 148cdf0e10cSrcweir CurOut() << ";"; 149cdf0e10cSrcweir } 150cdf0e10cSrcweir 151cdf0e10cSrcweir 152cdf0e10cSrcweir 153cdf0e10cSrcweir 154cdf0e10cSrcweir HF_IdlAttribute::~HF_IdlAttribute() 155cdf0e10cSrcweir { 156cdf0e10cSrcweir } 157cdf0e10cSrcweir 158cdf0e10cSrcweir typedef ary::idl::ifc_attribute::attr AttributeAttr; 159cdf0e10cSrcweir 160cdf0e10cSrcweir void 161cdf0e10cSrcweir HF_IdlAttribute::write_Declaration( const client & i_ce ) const 162cdf0e10cSrcweir { 163cdf0e10cSrcweir if (AttributeAttr::HasAnyStereotype(i_ce)) 164cdf0e10cSrcweir { 165cdf0e10cSrcweir CurOut() << "[ "; 166cdf0e10cSrcweir if (AttributeAttr::IsReadOnly(i_ce)) 167cdf0e10cSrcweir CurOut() << "readonly "; 168cdf0e10cSrcweir if (AttributeAttr::IsBound(i_ce)) 169cdf0e10cSrcweir CurOut() << "bound "; 170cdf0e10cSrcweir CurOut() << "] "; 171cdf0e10cSrcweir } 172cdf0e10cSrcweir 173cdf0e10cSrcweir HF_IdlTypeText 174cdf0e10cSrcweir aType( Env(), CurOut(), true ); 175cdf0e10cSrcweir aType.Produce_byData( AttributeAttr::Type(i_ce) ); 176cdf0e10cSrcweir 177cdf0e10cSrcweir CurOut() 178cdf0e10cSrcweir << " " 179cdf0e10cSrcweir >> *new Html::Bold 180cdf0e10cSrcweir << i_ce.LocalName(); 181cdf0e10cSrcweir 182cdf0e10cSrcweir dyn_type_list pGetExceptions; 183cdf0e10cSrcweir dyn_type_list pSetExceptions; 184cdf0e10cSrcweir AttributeAttr::Get_GetExceptions(pGetExceptions, i_ce); 185cdf0e10cSrcweir AttributeAttr::Get_SetExceptions(pSetExceptions, i_ce); 186cdf0e10cSrcweir 187cdf0e10cSrcweir bool bGetRaises = (*pGetExceptions).IsValid(); 188cdf0e10cSrcweir bool bSetRaises = (*pSetExceptions).IsValid(); 189cdf0e10cSrcweir bool bRaises = bGetRaises OR bSetRaises; 190cdf0e10cSrcweir if (bRaises) 191cdf0e10cSrcweir { 192cdf0e10cSrcweir HF_DocEntryList aSub(CurOut()); 193cdf0e10cSrcweir 194cdf0e10cSrcweir if (bGetRaises) 195cdf0e10cSrcweir { 196cdf0e10cSrcweir Xml::Element & 197cdf0e10cSrcweir rGet = aSub.Produce_Definition(); 198cdf0e10cSrcweir HF_IdlTypeText 199cdf0e10cSrcweir aExc(Env(), rGet, true); 200cdf0e10cSrcweir type_list & itExc = *pGetExceptions; 201cdf0e10cSrcweir 202cdf0e10cSrcweir rGet << "get raises ("; 203cdf0e10cSrcweir aExc.Produce_byData(*itExc); 204cdf0e10cSrcweir for (++itExc; itExc.operator bool(); ++itExc) 205cdf0e10cSrcweir { 206cdf0e10cSrcweir rGet 207cdf0e10cSrcweir << ","; 208cdf0e10cSrcweir aExc.Produce_byData(*itExc); 209cdf0e10cSrcweir } // end for 210cdf0e10cSrcweir rGet << ")"; 211cdf0e10cSrcweir if (NOT bSetRaises) 212cdf0e10cSrcweir rGet << ";"; 213cdf0e10cSrcweir } // end if (bGetRaises) 214cdf0e10cSrcweir 215cdf0e10cSrcweir if (bSetRaises) 216cdf0e10cSrcweir { 217cdf0e10cSrcweir Xml::Element & 218cdf0e10cSrcweir rSet = aSub.Produce_Definition(); 219cdf0e10cSrcweir HF_IdlTypeText 220cdf0e10cSrcweir aExc(Env(), rSet, true); 221cdf0e10cSrcweir type_list & itExc = *pSetExceptions; 222cdf0e10cSrcweir 223cdf0e10cSrcweir rSet << "set raises ("; 224cdf0e10cSrcweir aExc.Produce_byData(*itExc); 225cdf0e10cSrcweir for (++itExc; itExc.operator bool(); ++itExc) 226cdf0e10cSrcweir { 227cdf0e10cSrcweir rSet 228cdf0e10cSrcweir << ","; 229cdf0e10cSrcweir aExc.Produce_byData(*itExc); 230cdf0e10cSrcweir } // end for 231cdf0e10cSrcweir rSet << ");"; 232cdf0e10cSrcweir } // end if (bSetRaises) 233cdf0e10cSrcweir } 234cdf0e10cSrcweir else 235cdf0e10cSrcweir { 236cdf0e10cSrcweir CurOut() << ";"; 237cdf0e10cSrcweir } 238cdf0e10cSrcweir } 239cdf0e10cSrcweir 240cdf0e10cSrcweir 241cdf0e10cSrcweir 242cdf0e10cSrcweir 243cdf0e10cSrcweir HF_IdlEnumValue::~HF_IdlEnumValue() 244cdf0e10cSrcweir { 245cdf0e10cSrcweir } 246cdf0e10cSrcweir 247cdf0e10cSrcweir typedef ary::idl::ifc_enumvalue::attr EnumValueAttr; 248cdf0e10cSrcweir 249cdf0e10cSrcweir void 250cdf0e10cSrcweir HF_IdlEnumValue::write_Declaration( const client & i_ce ) const 251cdf0e10cSrcweir { 252cdf0e10cSrcweir CurOut() 253cdf0e10cSrcweir >> *new Html::Bold 254cdf0e10cSrcweir << i_ce.LocalName(); 255cdf0e10cSrcweir 256cdf0e10cSrcweir const String & 257cdf0e10cSrcweir rValue = EnumValueAttr::Value(i_ce); 258cdf0e10cSrcweir if ( NOT rValue.empty() ) 259cdf0e10cSrcweir { CurOut() << " " // << " = " // In the moment this is somehow in the value 260cdf0e10cSrcweir << rValue; 261cdf0e10cSrcweir // CurOut() << ","; // In the moment this is somehow in the value 262cdf0e10cSrcweir } 263cdf0e10cSrcweir else 264cdf0e10cSrcweir CurOut() << ","; 265cdf0e10cSrcweir } 266cdf0e10cSrcweir 267cdf0e10cSrcweir 268cdf0e10cSrcweir HF_IdlConstant::~HF_IdlConstant() 269cdf0e10cSrcweir { 270cdf0e10cSrcweir } 271cdf0e10cSrcweir 272cdf0e10cSrcweir typedef ary::idl::ifc_constant::attr ConstantAttr; 273cdf0e10cSrcweir 274cdf0e10cSrcweir void 275cdf0e10cSrcweir HF_IdlConstant::write_Declaration( const client & i_ce ) const 276cdf0e10cSrcweir { 277cdf0e10cSrcweir CurOut() << "const "; 278cdf0e10cSrcweir HF_IdlTypeText 279cdf0e10cSrcweir aType( Env(), CurOut(), true ); 280cdf0e10cSrcweir aType.Produce_byData(ConstantAttr::Type(i_ce)); 281cdf0e10cSrcweir CurOut() 282cdf0e10cSrcweir << " " 283cdf0e10cSrcweir >> *new Html::Bold 284cdf0e10cSrcweir << i_ce.LocalName(); 285cdf0e10cSrcweir const String & 286cdf0e10cSrcweir rValue = ConstantAttr::Value(i_ce); 287cdf0e10cSrcweir CurOut() << " " // << " = " // In the moment this is somehow in the value 288cdf0e10cSrcweir << rValue; 289cdf0e10cSrcweir // << ";"; // In the moment this is somehow in the value 290cdf0e10cSrcweir } 291cdf0e10cSrcweir 292cdf0e10cSrcweir 293cdf0e10cSrcweir HF_IdlStructElement::~HF_IdlStructElement() 294cdf0e10cSrcweir { 295cdf0e10cSrcweir } 296cdf0e10cSrcweir 297cdf0e10cSrcweir typedef ary::idl::ifc_structelement::attr StructElementAttr; 298cdf0e10cSrcweir 299cdf0e10cSrcweir void 300cdf0e10cSrcweir HF_IdlStructElement::write_Declaration( const client & i_ce ) const 301cdf0e10cSrcweir { 302cdf0e10cSrcweir HF_IdlTypeText 303cdf0e10cSrcweir aType( Env(), CurOut(), true ); 304cdf0e10cSrcweir aType.Produce_byData(StructElementAttr::Type(i_ce)); 305cdf0e10cSrcweir CurOut() 306cdf0e10cSrcweir << " " 307cdf0e10cSrcweir >> *new Html::Bold 308cdf0e10cSrcweir << i_ce.LocalName(); 309cdf0e10cSrcweir CurOut() 310cdf0e10cSrcweir << ";"; 311cdf0e10cSrcweir } 312cdf0e10cSrcweir 313cdf0e10cSrcweir HF_IdlCommentedRelationElement::~HF_IdlCommentedRelationElement() 314cdf0e10cSrcweir { 315cdf0e10cSrcweir } 316cdf0e10cSrcweir 317cdf0e10cSrcweir void 318cdf0e10cSrcweir HF_IdlCommentedRelationElement::produce_Summary( Environment & io_env, 319cdf0e10cSrcweir Xml::Element & io_context, 320cdf0e10cSrcweir const comref & i_commentedRef, 321cdf0e10cSrcweir const client & i_rScopeGivingCe ) 322cdf0e10cSrcweir { 323cdf0e10cSrcweir csv_assert( i_commentedRef.Info() ); 324cdf0e10cSrcweir 325cdf0e10cSrcweir const ary::idl::Type_id aType = i_commentedRef.Type(); 326cdf0e10cSrcweir const ce_info & rDocu = *i_commentedRef.Info(); 327cdf0e10cSrcweir 328cdf0e10cSrcweir bool bShort = NOT rDocu.Short().IsEmpty(); 329cdf0e10cSrcweir bool bDescr = NOT rDocu.Description().IsEmpty(); 330cdf0e10cSrcweir 331cdf0e10cSrcweir if ( bShort ) 332cdf0e10cSrcweir { 333cdf0e10cSrcweir HF_IdlDocuTextDisplay 334cdf0e10cSrcweir aDescription(io_env, 0, i_rScopeGivingCe); 335cdf0e10cSrcweir 336cdf0e10cSrcweir Xml::Element& rPara = io_context >> *new Html::Paragraph; 337cdf0e10cSrcweir aDescription.Out().Enter( rPara ); 338cdf0e10cSrcweir rDocu.Short().DisplayAt( aDescription ); 339cdf0e10cSrcweir 340cdf0e10cSrcweir // if there's more than just the summary - i.e. a description, or usage restrictions, or tags -, 341cdf0e10cSrcweir // then add a link to the details section 342cdf0e10cSrcweir if ( bDescr OR rDocu.IsDeprecated() OR rDocu.IsOptional() OR NOT rDocu.Tags().empty() ) 343cdf0e10cSrcweir { 344cdf0e10cSrcweir StreamLock aLocalLink(100); 345cdf0e10cSrcweir aLocalLink() << "#" << get_LocalLinkName(io_env, i_commentedRef); 346cdf0e10cSrcweir 347cdf0e10cSrcweir aDescription.Out().Out() << "("; 348cdf0e10cSrcweir aDescription.Out().Out() 349cdf0e10cSrcweir >> *new Html::Link( aLocalLink().c_str() ) 350cdf0e10cSrcweir << "details"; 351cdf0e10cSrcweir aDescription.Out().Out() << ")"; 352cdf0e10cSrcweir } 353cdf0e10cSrcweir 354cdf0e10cSrcweir aDescription.Out().Leave(); 355cdf0e10cSrcweir } 356cdf0e10cSrcweir } 357cdf0e10cSrcweir 358cdf0e10cSrcweir void 359cdf0e10cSrcweir HF_IdlCommentedRelationElement::produce_LinkDoc( Environment & io_env, 360cdf0e10cSrcweir const client & i_ce, 361cdf0e10cSrcweir Xml::Element & io_context, 362cdf0e10cSrcweir const comref & i_commentedRef, 363cdf0e10cSrcweir const E_DocType i_docType ) 364cdf0e10cSrcweir { 365cdf0e10cSrcweir if ( i_commentedRef.Info() != 0 ) 366cdf0e10cSrcweir { 367cdf0e10cSrcweir if ( i_docType == doctype_complete ) 368cdf0e10cSrcweir { 369cdf0e10cSrcweir HF_DocEntryList aDocList(io_context); 370cdf0e10cSrcweir HF_IdlDocu aDocuDisplay(io_env, aDocList); 371cdf0e10cSrcweir 372cdf0e10cSrcweir aDocuDisplay.Produce_fromReference(*i_commentedRef.Info(), i_ce); 373cdf0e10cSrcweir } 374cdf0e10cSrcweir else 375cdf0e10cSrcweir { 376cdf0e10cSrcweir produce_Summary(io_env, io_context, i_commentedRef, i_ce); 377cdf0e10cSrcweir } 378cdf0e10cSrcweir } 379cdf0e10cSrcweir else 380cdf0e10cSrcweir { 381cdf0e10cSrcweir HF_DocEntryList aDocList(io_context); 382cdf0e10cSrcweir 383cdf0e10cSrcweir const client * 384cdf0e10cSrcweir pCe = io_env.Linker().Search_CeFromType(i_commentedRef.Type()); 385cdf0e10cSrcweir const ce_info * 386cdf0e10cSrcweir pShort = pCe != 0 387cdf0e10cSrcweir ? Get_IdlDocu(pCe->Docu()) 388cdf0e10cSrcweir : (const ce_info *)(0); 389cdf0e10cSrcweir if ( pShort != 0 ) 390cdf0e10cSrcweir { 391cdf0e10cSrcweir aDocList.Produce_NormalTerm("(referenced entity's summary:)"); 392cdf0e10cSrcweir Xml::Element & 393cdf0e10cSrcweir rDef = aDocList.Produce_Definition(); 394cdf0e10cSrcweir HF_IdlDocuTextDisplay 395cdf0e10cSrcweir aShortDisplay( io_env, &rDef, *pCe); 396cdf0e10cSrcweir pShort->Short().DisplayAt(aShortDisplay); 397cdf0e10cSrcweir } // end if (pShort != 0) 398cdf0e10cSrcweir } // endif ( (*i_commentedRef).Info() != 0 ) else 399cdf0e10cSrcweir } 400cdf0e10cSrcweir 401cdf0e10cSrcweir 402cdf0e10cSrcweir String 403cdf0e10cSrcweir HF_IdlCommentedRelationElement::get_LocalLinkName( Environment & io_env, 404cdf0e10cSrcweir const comref & i_commentedRef ) 405cdf0e10cSrcweir { 406cdf0e10cSrcweir StringVector aModules; 407cdf0e10cSrcweir String sLocalName; 408cdf0e10cSrcweir ce_id nCe; 409cdf0e10cSrcweir int nSequenceCount = 0; 410cdf0e10cSrcweir 411cdf0e10cSrcweir const ary::idl::Type & 412cdf0e10cSrcweir rType = io_env.Data().Find_Type(i_commentedRef.Type()); 413cdf0e10cSrcweir io_env.Data().Get_TypeText(aModules, sLocalName, nCe, nSequenceCount, rType); 414cdf0e10cSrcweir 415cdf0e10cSrcweir // speaking strictly, this is not correct: If we have two interfaces with the same local 416cdf0e10cSrcweir // name, but in different modules, then the link name will be ambiguous. However, this should 417cdf0e10cSrcweir // be too seldom a case to really make the link names that ugly by adding the module information. 418cdf0e10cSrcweir return sLocalName; 419cdf0e10cSrcweir } 420cdf0e10cSrcweir 421cdf0e10cSrcweir void 422cdf0e10cSrcweir HF_IdlCommentedRelationElement::write_Title( const client & /*i_ce*/ ) const 423cdf0e10cSrcweir { 424cdf0e10cSrcweir 425cdf0e10cSrcweir Xml::Element & 426cdf0e10cSrcweir rAnchor = CurOut() 427cdf0e10cSrcweir >> *new Html::Label(get_LocalLinkName(Env(), m_relation)) 428cdf0e10cSrcweir << new Html::ClassAttr(C_sMemberTitle); 429cdf0e10cSrcweir 430cdf0e10cSrcweir HF_IdlTypeText 431cdf0e10cSrcweir aText(Env(), rAnchor, true); 432cdf0e10cSrcweir aText.Produce_byData(m_relation.Type()); 433cdf0e10cSrcweir } 434cdf0e10cSrcweir 435cdf0e10cSrcweir void 436cdf0e10cSrcweir HF_IdlCommentedRelationElement::write_Declaration( const client & /*i_ce*/ ) const 437cdf0e10cSrcweir { 438cdf0e10cSrcweir // nothing to do here - an entity which is a commented relation does not have a declaration 439cdf0e10cSrcweir } 440cdf0e10cSrcweir 441cdf0e10cSrcweir void 442cdf0e10cSrcweir HF_IdlCommentedRelationElement::write_Description( const client & i_ce ) const 443cdf0e10cSrcweir { 444cdf0e10cSrcweir produce_LinkDoc( Env(), i_ce, CurOut(), m_relation, doctype_complete ); 445cdf0e10cSrcweir } 446