1 // Copyright (C) 2005 CEA/DEN, EDF R&D, OPEN CASCADE, PRINCIPIA R&D
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License.
8 // This library is distributed in the hope that it will be useful
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/
19 #include "DDS_KeyWords.h"
21 IMPLEMENT_STANDARD_HANDLE(DDS_KeyWords, MMgt_TShared)
22 IMPLEMENT_STANDARD_RTTIEXT(DDS_KeyWords, MMgt_TShared)
24 DDS_KeyWords::DDS_KeyWords()
27 SetKeyWord( "D_URI", "dictionary" );
29 SetKeyWord( "COMPONENT", "component" );
30 SetKeyWord( "COMPONENT_NAME", "name" );
32 SetKeyWord( "UNIT_SYSTEMS", "unitSystems" );
33 SetKeyWord( "UNIT_SYSTEM", "system" );
34 SetKeyWord( "UNIT_SYSTEM_NAME", "name" );
35 SetKeyWord( "UNIT_SYSTEM_LABEL", "label" );
37 SetKeyWord( "DATUM", "datum" );
38 SetKeyWord( "DATUM_ID", "id" );
39 SetKeyWord( "DATUM_LABEL", "label" );
40 SetKeyWord( "DATUM_UNITS", "units" );
41 SetKeyWord( "DATUM_FORMAT", "format" );
42 SetKeyWord( "DATUM_FILTER", "filter" );
43 SetKeyWord( "DATUM_REQUIRED", "required" );
45 SetKeyWord( "VALUE_LIST", "valueList" );
46 SetKeyWord( "VALUE_LIST_ID", "listid" );
47 SetKeyWord( "VALUE_LIST_NAME", "name" );
48 SetKeyWord( "VALUE_LIST_TYPE", "type" );
49 SetKeyWord( "VALUE_LIST_VALUE", "value" );
50 SetKeyWord( "VALUE_LIST_VALUEID", "id" );
51 SetKeyWord( "VALUE_LIST_VALUEICON", "icon" );
53 SetKeyWord( "DY_DOMAIN", "domain" );
54 SetKeyWord( "WARNING_LEVEL", "warningLevel" );
55 SetKeyWord( "WRONG_VALUE", "wrongValue" );
56 SetKeyWord( "VALUE_DESCR", "valueDescr" );
57 SetKeyWord( "VALUE_LIST_REF", "listRef" );
59 SetKeyWord( "DESCR", "description" );
60 SetKeyWord( "LONG_D", "longDescr" );
61 SetKeyWord( "SHORT_D", "shortDescr" );
63 SetKeyWord( "VD_TYPE", "type" );
64 SetKeyWord( "VD_DEFV", "default" );
65 SetKeyWord( "VD_MAXV", "max" );
66 SetKeyWord( "VD_MINV", "min" );
67 SetKeyWord( "VD_SPEC", "specVal" );
68 SetKeyWord( "VLR_LIST", "list" );
69 SetKeyWord( "PRS", "presentation" );
70 SetKeyWord( "LATERAL_ZOOM", "lateralZoom" );
71 SetKeyWord( "LZ_MINV", "min" );
72 SetKeyWord( "LZ_MAXV", "max" );
73 SetKeyWord( "LZ_ORDER", "order" );
76 Handle(DDS_KeyWords) DDS_KeyWords::Get()
78 static Handle(DDS_KeyWords) keyWords;
80 if ( keyWords.IsNull() )
81 keyWords = new DDS_KeyWords();
86 TCollection_AsciiString DDS_KeyWords::GetKeyWord( const TCollection_AsciiString& key ) const
88 TCollection_AsciiString keyWord;
89 if ( myKeyWord.IsBound( key ) )
90 keyWord = myKeyWord.Find( key );
94 void DDS_KeyWords::SetKeyWord( const TCollection_AsciiString& key,
95 const TCollection_AsciiString& keyWord )
97 if ( myKeyWord.IsBound( key ) )
98 myKeyWord.UnBind( key );
100 myKeyWord.Bind( key, keyWord );