37 #include <tqvaluevector.h>
38 #include <tdemacros.h>
44 class DNAttributeOrderConfigWidget;
58 TQString name2label( const TQString & s ) const;
59 TQStringList names() const;
61 const TQStringList & attributeOrder() const;
63 void setAttributeOrder( const TQStringList & order );
65 DNAttributeOrderConfigWidget * configWidget( TQWidget * parent=0, const char * name=0 ) const;
79 typedef TQValueVector<Attribute> AttributeList;
80 typedef AttributeList::const_iterator const_iterator;
83 DN( const TQString & dn );
84 DN( const char * utf8DN );
85 DN( const DN & other );
88 const DN & operator=( const DN & other );
91 static TQString escape( const TQString & value );
95 TQString prettyDN() const;
99 TQString operator[]( const TQString & attr ) const;
101 void append( const Attribute & attr );
103 const_iterator begin() const;
104 const_iterator end() const;
113 class TDE_EXPORT DN::Attribute {
115 typedef DN::AttributeList List;
117 Attribute( const TQString & name=TQString(), const TQString & value=TQString() )
118 : mName( name.upper() ), mValue( value ) {}
119 Attribute( const Attribute & other )
120 : mName( other.name() ), mValue( other.value() ) {}
122 const Attribute & operator=( const Attribute & other ) {
123 if ( this != &other ) {
124 mName = other.name();
125 mValue = other.value();
130 const TQString & name() const { return mName; }
131 const TQString & value() const { return mValue; }
133 void setValue( const TQString & value ) { mValue = value; }
|