-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path__init__.py
158 lines (108 loc) · 4.44 KB
/
__init__.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
#
# (C) Copyright 2004,2006 Hewlett-Packard Development Company, L.P.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation; version 2 of the License.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
# Author: Tim Potter <[email protected]>
# Martin Pool <[email protected]>
"""
PyWBEM provides a WBEM client library and some related utilities, written in
pure Python.
The WBEM client library allows issuing operations to a WBEM server, using
the CIM operations over HTTP (CIM-XML) protocol defined in the DMTF standards
DSP0200 and DSP0201. See http://www.dmtf.org/standards/wbem for information
about WBEM.
It is based on the idea that a good WBEM client should be easy to use and not
necessarily require a large amount of programming knowledge. It is suitable for
a large range of tasks from simply poking around to writing web and GUI
applications.
* `WBEMConnection` : Main class of the WBEM client library and a good starting
point to read about it.
The WBEM-related utilities included in this package are:
* `mof_compiler` : Script for compiling MOF files, can also be used as a
module.
* `cim_provider` : Module for writing CIM providers in Python.
* `cim_provider2` : Another module for writing CIM providers in Python.
* `twisted_client` : An experimental alternative WBEM client library that uses
the Python `twisted` package.
* `wbemcli` : Script providing a WBEM client CLI as an interactive shell.
Importing the `pywbem` package causes a subset of symbols from its sub-modules
to be folded into the target namespace.
The use of these folded symbols is shown for the example of class
`WBEMConnection`:
.. code:: python
import pywbem
conn = pywbem.WBEMConnection(...)
or:
.. code:: python
from pywbem import WBEMConnection
conn = WBEMConnection(...)
or (less preferred):
.. code:: python
from pywbem import *
conn = WBEMConnection(...)
The folded symbols' origin symbols in the sub-modules are also considered part
of the public interface of the `pywbem` package.
Programs using sub-modules that are not part of the WBEM client library, or
specific symbols that are not folded into the target namespace of the `pywbem`
package need to import the respective sub-modules explicitly.
The use of such sub-modules is shown for the example of class
`cim_provider.CIMProvider`:
.. code:: python
from pywbem import cim_provider
provider = cim_provider.CIMProvider(...)
or:
.. code:: python
from pywbem.cim_provider import CIMProvider
provider = CIMProvider(...)
or:
.. code:: python
import pywbem.cim_provider
provider = pywbem.cim_provider.CIMProvider(...)
Version
-------
This version of PyWBEM is 3.8.0~dev.
The version number follows these conventions:
* M.N.U~dev : During development of the future M.N.U version.
* M.N.U~rc1 : For release candidate 1 (etc.) of the future M.N.U version.
* M.N.U : For the final (=released) M.N.U version.
The use of the tilde (~) causes RPM to correctly treat the preliminary versions
to be younger than the final version.
Changes
-------
The change log is in the `NEWS <../NEWS>`_ file.
Compatibility
-------------
PyWBEM has been tested with Python 2.7 on Windows and Linux, and with Python
2.6 on Linux (due to a restriction of the `M2Crypto` package on Windows).
Contributing
------------
PyWBEM is on SourceForge (http://sourceforge.net/projects/pywbem/). Bug
reports and discussion on the mailing list are welcome.
License
-------
PyWBEM is licensed with GNU LGPL v2.
See the `LICENSE.txt <../LICENSE.txt>`_ file.
"""
# Version of the pywbem package
# !!! Keep in sync with version stated in module docstring, above !!!
__version__ = '3.8.0~dev'
# There are submodules, but clients shouldn't need to know about them.
# Importing just this module is enough.
# These are explicitly safe for 'import *'
from .cim_constants import *
from .cim_types import *
from .cim_obj import *
from .cim_operations import WBEMConnection
from .tupleparse import ParseError