OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
Public Member Functions | Private Attributes | Friends | List of all members
ossimKeyword Class Reference

#include <ossimKeyword.h>

Public Member Functions

 ossimKeyword ()
 
 ossimKeyword (const char *key, const char *description)
 
 ossimKeyword (const char *key, const char *description, const char *value)
 
 ossimKeyword (const ossimKeyword &src)
 
 ~ossimKeyword ()
 
const ossimKeywordoperator= (const ossimKeyword &kw)
 
 operator const char * () const
 
const char * key () const
 
const char * description () const
 
const char * value () const
 
ossimString keyString () const
 
ossimString descriptionString () const
 
ossimString valueString () const
 
void setValue (const char *val)
 
void setValue (const ossimString &val)
 
void setDescription (const char *desc)
 
void setDescription (const ossimString &desc)
 

Private Attributes

ossimString theKey
 
ossimString theDesc
 
ossimString theValue
 

Friends

OSSIM_DLL std::ostream & operator<< (std::ostream &os, const ossimKeyword &kw)
 

Detailed Description

Definition at line 17 of file ossimKeyword.h.

Constructor & Destructor Documentation

◆ ossimKeyword() [1/4]

ossimKeyword::ossimKeyword ( )

Definition at line 16 of file ossimKeyword.cpp.

17  :
18  theKey(""),
19  theDesc(""),
20  theValue("")
21 {}
ossimString theKey
Definition: ossimKeyword.h:45
ossimString theValue
Definition: ossimKeyword.h:47
ossimString theDesc
Definition: ossimKeyword.h:46

◆ ossimKeyword() [2/4]

ossimKeyword::ossimKeyword ( const char *  key,
const char *  description 
)

Definition at line 23 of file ossimKeyword.cpp.

24  :
25  theKey(key),
27  theValue("")
28 {}
ossimString theKey
Definition: ossimKeyword.h:45
const char * description() const
ossimString theValue
Definition: ossimKeyword.h:47
ossimString theDesc
Definition: ossimKeyword.h:46
const char * key() const

◆ ossimKeyword() [3/4]

ossimKeyword::ossimKeyword ( const char *  key,
const char *  description,
const char *  value 
)

Definition at line 30 of file ossimKeyword.cpp.

33  :
34  theKey(key),
36  theValue(value)
37 {}
ossimString theKey
Definition: ossimKeyword.h:45
const char * description() const
const char * value() const
ossimString theValue
Definition: ossimKeyword.h:47
ossimString theDesc
Definition: ossimKeyword.h:46
const char * key() const

◆ ossimKeyword() [4/4]

ossimKeyword::ossimKeyword ( const ossimKeyword src)

Definition at line 39 of file ossimKeyword.cpp.

40  :
41  theKey(src.key()),
42  theDesc(src.description()),
43  theValue(src.value())
44 {}
ossimString theKey
Definition: ossimKeyword.h:45
const char * description() const
const char * value() const
ossimString theValue
Definition: ossimKeyword.h:47
ossimString theDesc
Definition: ossimKeyword.h:46
const char * key() const

◆ ~ossimKeyword()

ossimKeyword::~ossimKeyword ( )

Definition at line 46 of file ossimKeyword.cpp.

47 {}

Member Function Documentation

◆ description()

const char * ossimKeyword::description ( ) const

Definition at line 59 of file ossimKeyword.cpp.

References ossimString::c_str(), and theDesc.

Referenced by operator<<(), and operator=().

60 {
61  return theDesc.c_str();
62 }
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396
ossimString theDesc
Definition: ossimKeyword.h:46

◆ descriptionString()

ossimString ossimKeyword::descriptionString ( ) const

Definition at line 74 of file ossimKeyword.cpp.

References theDesc.

75 {
76  return theDesc;
77 }
ossimString theDesc
Definition: ossimKeyword.h:46

◆ key()

const char * ossimKeyword::key ( ) const

Definition at line 54 of file ossimKeyword.cpp.

References ossimString::c_str(), and theKey.

Referenced by operator<<(), and operator=().

55 {
56  return theKey.c_str();
57 }
ossimString theKey
Definition: ossimKeyword.h:45
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396

◆ keyString()

ossimString ossimKeyword::keyString ( ) const

Definition at line 69 of file ossimKeyword.cpp.

References theKey.

70 {
71  return theKey;
72 }
ossimString theKey
Definition: ossimKeyword.h:45

◆ operator const char *()

ossimKeyword::operator const char * ( ) const

Definition at line 49 of file ossimKeyword.cpp.

50 {
51  return theKey.c_str();
52 }
ossimString theKey
Definition: ossimKeyword.h:45
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396

◆ operator=()

const ossimKeyword & ossimKeyword::operator= ( const ossimKeyword kw)

Definition at line 104 of file ossimKeyword.cpp.

References description(), key(), theDesc, theKey, theValue, and value().

105 {
106  if (this != &kw)
107  {
108  theKey = kw.key();
109  theDesc = kw.description();
110  theValue = kw.value();
111  }
112 
113  return *this;
114 }
ossimString theKey
Definition: ossimKeyword.h:45
const char * description() const
const char * value() const
ossimString theValue
Definition: ossimKeyword.h:47
ossimString theDesc
Definition: ossimKeyword.h:46
const char * key() const

◆ setDescription() [1/2]

void ossimKeyword::setDescription ( const char *  desc)

Definition at line 94 of file ossimKeyword.cpp.

References theDesc.

95 {
96  theDesc = desc;
97 }
ossimString theDesc
Definition: ossimKeyword.h:46

◆ setDescription() [2/2]

void ossimKeyword::setDescription ( const ossimString desc)

Definition at line 99 of file ossimKeyword.cpp.

References theDesc.

100 {
101  theDesc = desc;
102 }
ossimString theDesc
Definition: ossimKeyword.h:46

◆ setValue() [1/2]

void ossimKeyword::setValue ( const char *  val)

Definition at line 84 of file ossimKeyword.cpp.

References theValue.

85 {
86  theValue = val;
87 }
ossimString theValue
Definition: ossimKeyword.h:47

◆ setValue() [2/2]

void ossimKeyword::setValue ( const ossimString val)

Definition at line 89 of file ossimKeyword.cpp.

References theValue.

90 {
91  theValue = val;
92 }
ossimString theValue
Definition: ossimKeyword.h:47

◆ value()

const char * ossimKeyword::value ( ) const

Definition at line 64 of file ossimKeyword.cpp.

References ossimString::c_str(), and theValue.

Referenced by operator<<(), and operator=().

65 {
66  return theValue.c_str();
67 }
ossimString theValue
Definition: ossimKeyword.h:47
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396

◆ valueString()

ossimString ossimKeyword::valueString ( ) const

Definition at line 79 of file ossimKeyword.cpp.

References theValue.

80 {
81  return theValue;
82 }
ossimString theValue
Definition: ossimKeyword.h:47

Friends And Related Function Documentation

◆ operator<<

OSSIM_DLL std::ostream& operator<< ( std::ostream &  os,
const ossimKeyword kw 
)
friend

Definition at line 116 of file ossimKeyword.cpp.

117 {
118  os << "\n key = " << kw.key()
119  << "\n desc = " << kw.description()
120  << "\n value = " << kw.value()
121  << std::endl;
122  return os;
123 }
const char * description() const
const char * value() const
const char * key() const

Member Data Documentation

◆ theDesc

ossimString ossimKeyword::theDesc
private

Definition at line 46 of file ossimKeyword.h.

Referenced by description(), descriptionString(), operator=(), and setDescription().

◆ theKey

ossimString ossimKeyword::theKey
private

Definition at line 45 of file ossimKeyword.h.

Referenced by key(), keyString(), and operator=().

◆ theValue

ossimString ossimKeyword::theValue
private

Definition at line 47 of file ossimKeyword.h.

Referenced by operator=(), setValue(), value(), and valueString().


The documentation for this class was generated from the following files: