(file) Return to CIMNameInline.h CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

  1 r.kieninger 1.2 //%2005////////////////////////////////////////////////////////////////////////
  2                 //
  3                 // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
  4                 // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
  5                 // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
  6                 // IBM Corp.; EMC Corporation, The Open Group.
  7                 // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
  8                 // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
  9                 // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 10                 // EMC Corporation; VERITAS Software Corporation; The Open Group.
 11                 //
 12                 // Permission is hereby granted, free of charge, to any person obtaining a copy
 13                 // of this software and associated documentation files (the "Software"), to
 14                 // deal in the Software without restriction, including without limitation the
 15                 // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
 16                 // sell copies of the Software, and to permit persons to whom the Software is
 17                 // furnished to do so, subject to the following conditions:
 18                 //
 19                 // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
 20                 // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
 21                 // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
 22 r.kieninger 1.2 // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
 23                 // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
 24                 // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 25                 // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 26                 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 27                 //
 28                 //==============================================================================
 29                 //
 30                 //%/////////////////////////////////////////////////////////////////////////////
 31                 
 32 mike        1.3 #if !defined(Pegasus_CIMNameInline_cxx)
 33                 # if !defined(PEGASUS_INTERNALONLY) || defined(PEGASUS_DISABLE_INTERNAL_INLINES)
 34                 #   define Pegasus_CIMNameInline_h
 35                 # endif
 36 r.kieninger 1.2 #endif
 37                 
 38                 #ifndef Pegasus_CIMNameInline_h
 39                 #define Pegasus_CIMNameInline_h
 40                 
 41                 #include <Pegasus/Common/CIMName.h>
 42                 
 43                 #ifdef Pegasus_CIMNameInline_cxx
 44                 # define PEGASUS_CIMNAME_INLINE
 45                 #else
 46                 # define PEGASUS_CIMNAME_INLINE inline
 47                 #endif
 48                 
 49                 PEGASUS_NAMESPACE_BEGIN
 50                 
 51                 PEGASUS_CIMNAME_INLINE CIMName::CIMName()
 52                 {
 53                 }
 54                 
 55                 PEGASUS_CIMNAME_INLINE CIMName& CIMName::operator=(const CIMName& name)
 56                 {
 57 r.kieninger 1.2     cimName = name.cimName;
 58                     return *this;
 59                 }
 60                 
 61                 PEGASUS_CIMNAME_INLINE const String& CIMName::getString() const
 62                 {
 63                     return cimName;
 64                 }
 65                 
 66                 PEGASUS_CIMNAME_INLINE Boolean CIMName::isNull() const
 67                 {
 68                     return (cimName.size() == 0);
 69                 }
 70                 
 71                 PEGASUS_CIMNAME_INLINE void CIMName::clear()
 72                 {
 73                     cimName.clear();
 74                 }
 75                 
 76                 PEGASUS_CIMNAME_INLINE Boolean CIMName::equal(const CIMName& name) const
 77                 {
 78 r.kieninger 1.2     return String::equalNoCase(cimName, name.cimName);
 79                 }
 80                 
 81                 PEGASUS_CIMNAME_INLINE Boolean CIMName::equal(const char* name) const
 82                 {
 83                     return String::equalNoCase(cimName, name);
 84                 }
 85                 
 86                 PEGASUS_CIMNAME_INLINE Boolean operator==(
 87                     const CIMName& name1, const CIMName& name2)
 88                 {
 89                     return name1.equal(name2);
 90                 }
 91                 
 92                 PEGASUS_CIMNAME_INLINE Boolean operator==(
 93                     const CIMName& name1, const char* name2)
 94                 {
 95                     return name1.equal(name2);
 96                 }
 97                 
 98                 PEGASUS_CIMNAME_INLINE Boolean operator==(
 99 r.kieninger 1.2     const char* name1, const CIMName& name2)
100                 {
101                     return name2.equal(name1);
102                 }
103                 
104                 PEGASUS_CIMNAME_INLINE Boolean operator!=(
105                     const CIMName& name1, const CIMName& name2)
106                 {
107                     return !name1.equal(name2);
108                 }
109                 
110                 PEGASUS_CIMNAME_INLINE Boolean operator!=(
111                     const CIMName& name1, const char* name2)
112                 {
113                     return !name1.equal(name2);
114                 }
115                 
116                 PEGASUS_CIMNAME_INLINE Boolean operator!=(
117                     const char* name1, const CIMName& name2)
118                 {
119                     return !name2.equal(name1);
120 r.kieninger 1.2 }
121                 
122                 PEGASUS_CIMNAME_INLINE CIMNamespaceName::CIMNamespaceName()
123                 {
124                 }
125                 
126                 PEGASUS_CIMNAME_INLINE const String& CIMNamespaceName::getString() const
127                 {
128                     return cimNamespaceName;
129                 }
130                 
131                 PEGASUS_CIMNAME_INLINE Boolean CIMNamespaceName::isNull() const
132                 {
133                     return (cimNamespaceName.size() == 0);
134                 }
135                 
136                 PEGASUS_CIMNAME_INLINE void CIMNamespaceName::clear()
137                 {
138                     cimNamespaceName.clear();
139                 }
140                 
141 r.kieninger 1.2 PEGASUS_CIMNAME_INLINE Boolean CIMNamespaceName::equal(
142                     const CIMNamespaceName& name) const
143                 {
144                     return String::equalNoCase(cimNamespaceName, name.cimNamespaceName);
145                 }
146                 
147                 PEGASUS_CIMNAME_INLINE Boolean CIMNamespaceName::equal(const char* name) const
148                 {
149                     return String::equalNoCase(cimNamespaceName, name);
150                 }
151                 
152                 PEGASUS_NAMESPACE_END
153                 
154                 #endif /* Pegasus_CIMNameInline_h */

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2