RAPP Platform API
Main Page
Packages
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
QrDetection.py
Go to the documentation of this file.
1
from
RappCloud.Objects
import
(
2
File,
3
Payload)
4
5
from
Cloud
import
(
6
CloudMsg,
7
CloudRequest,
8
CloudResponse)
9
10
11
class
QrDetection
(CloudMsg):
12
""" Qr Detection Cloud Message object"""
13
14
class
Request
(CloudRequest):
15
""" Qr Detection Cloud Request object. QrDetection.Request """
16
def
__init__
(self, **kwargs):
17
"""!
18
Constructor
19
20
@param **kwargs - Keyword arguments. Apply values to the request attributes.
21
- @ref imageFilepath
22
"""
23
## File path to the image to load. This is the image to perform
24
# qr-detection on.
25
self.
imageFilepath
=
''
26
super(
QrDetection.Request
, self).
__init__
(**kwargs)
27
28
29
def
make_payload
(self):
30
""" Create and return the Payload of the Request. """
31
return
Payload()
32
33
def
make_files
(self):
34
""" Create and return Array of File objects of the Request. """
35
return
[File(self.
imageFilepath
, postfield=
'file'
)]
36
37
38
class
Response
(CloudResponse):
39
""" Qr Detection Cloud Response object. QrDetection.Response """
40
def
__init__
(self, **kwargs):
41
"""!
42
Constructor
43
44
@param **kwargs - Keyword arguments. Apply values to the request attributes.
45
- @ref error
46
- @ref qr_centers
47
- @ref qr_messages
48
"""
49
50
## Error message
51
self.
error
=
''
52
## Found qr centers. Array of qr_center objects.
53
# TODO Create qr_center objects
54
self.
qr_centers
= []
55
## Found qr messages. Array of strings.
56
self.
qr_messages
= []
57
super(
QrDetection.Response
, self).
__init__
(**kwargs)
58
59
60
def
__init__
(self, **kwargs):
61
"""!
62
Constructor
63
64
@param **kwargs - Keyword arguments. Apply values to the request attributes.
65
- @ref Request.imageFilepath
66
"""
67
68
# Create and hold the Request object for this CloudMsg
69
self.
req
=
QrDetection.Request
()
70
# Create and hold the Response object for this CloudMsg
71
self.
resp
=
QrDetection.Response
()
72
super(QrDetection, self).
__init__
(svcname=
'qr_detection'
, **kwargs)
73
74
RappCloud.CloudMsgs.QrDetection.QrDetection.Request.make_files
def make_files
Definition:
QrDetection.py:33
RappCloud.CloudMsgs.QrDetection.QrDetection.Response.qr_centers
qr_centers
Found qr centers.
Definition:
QrDetection.py:54
RappCloud.CloudMsgs.QrDetection.QrDetection.Response.qr_messages
qr_messages
Found qr messages.
Definition:
QrDetection.py:56
RappCloud.CloudMsgs.QrDetection.QrDetection.__init__
def __init__
Constructor.
Definition:
QrDetection.py:60
RappCloud.Objects
Definition:
__init__.py:1
RappCloud.CloudMsgs.QrDetection.QrDetection.Response.__init__
def __init__
Constructor.
Definition:
QrDetection.py:40
RappCloud.CloudMsgs.QrDetection.QrDetection.Request.make_payload
def make_payload
Definition:
QrDetection.py:29
RappCloud.CloudMsgs.QrDetection.QrDetection.req
req
Definition:
QrDetection.py:69
RappCloud.CloudMsgs.QrDetection.QrDetection.Request.imageFilepath
imageFilepath
File path to the image to load.
Definition:
QrDetection.py:25
RappCloud.CloudMsgs.QrDetection.QrDetection.Response.error
error
Error message.
Definition:
QrDetection.py:51
RappCloud.CloudMsgs.QrDetection.QrDetection.Response
Definition:
QrDetection.py:38
RappCloud.CloudMsgs.QrDetection.QrDetection.Request.__init__
def __init__
Constructor.
Definition:
QrDetection.py:16
RappCloud.CloudMsgs.QrDetection.QrDetection.Request
Definition:
QrDetection.py:14
RappCloud.CloudMsgs.QrDetection.QrDetection
Definition:
QrDetection.py:11
RappCloud.CloudMsgs.QrDetection.QrDetection.resp
resp
Definition:
QrDetection.py:71
python
RappCloud
CloudMsgs
QrDetection.py
Generated on Fri Jul 29 2016 18:45:01 for RAPP Platform API by
1.8.6