-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathsetup.py
47 lines (38 loc) · 1.08 KB
/
setup.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
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
VERSION = '1.2.1'
LONG_DESCRIPTION = '''
pyhessian2 is implemented for serialize and deserialize data in hessian2 protocol.
Usage
-----
>>> # encoding
>>> from pyhessian2 import HessianObject, Encoder
>>> attrs = {
"name": "xx",
"age": 20,
}
>>> obj = HessianObject("com.xx.person", attrs)
>>> data = Encoder().encode(obj)
>>> print "%r" % data
>>> # decoding
>>> from pyhessian2 import Decoder
>>> data = ... # a hessian bytes data
>>> obj = Decoder().decoder(data) # get a Hessianobject instance
>>> print obj # print json serialized data
'''
setup(
name='pyhessian2',
description='an implementation for hessian2',
long_description=LONG_DESCRIPTION,
author='WKPlus',
url='https://github.com/WKPlus/pyhessian2.git',
license='MIT',
author_email='[email protected]',
version=VERSION,
packages = ['pyhessian2'],
install_requires=[],
test_requires=['nose'],
zip_safe=False,
)