File: secondary_emails.py

package info (click to toggle)
python-dropbox 12.0.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 6,772 kB
  • sloc: python: 76,994; sh: 27; makefile: 24
file content (60 lines) | stat: -rw-r--r-- 1,782 bytes parent folder | download | duplicates (2)
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
# -*- coding: utf-8 -*-
# Auto-generated by Stone, do not modify.
# @generated
# flake8: noqa
# pylint: skip-file
from __future__ import unicode_literals
from stone.backends.python_rsrc import stone_base as bb
from stone.backends.python_rsrc import stone_validators as bv

from dropbox import common

class SecondaryEmail(bb.Struct):
    """
    :ivar secondary_emails.SecondaryEmail.email: Secondary email address.
    :ivar secondary_emails.SecondaryEmail.is_verified: Whether or not the
        secondary email address is verified to be owned by a user.
    """

    __slots__ = [
        '_email_value',
        '_is_verified_value',
    ]

    _has_required_fields = True

    def __init__(self,
                 email=None,
                 is_verified=None):
        self._email_value = bb.NOT_SET
        self._is_verified_value = bb.NOT_SET
        if email is not None:
            self.email = email
        if is_verified is not None:
            self.is_verified = is_verified

    # Instance attribute type: str (validator is set below)
    email = bb.Attribute("email")

    # Instance attribute type: bool (validator is set below)
    is_verified = bb.Attribute("is_verified")

    def _process_custom_annotations(self, annotation_type, field_path, processor):
        super(SecondaryEmail, self)._process_custom_annotations(annotation_type, field_path, processor)

SecondaryEmail_validator = bv.Struct(SecondaryEmail)

SecondaryEmail.email.validator = common.EmailAddress_validator
SecondaryEmail.is_verified.validator = bv.Boolean()
SecondaryEmail._all_field_names_ = set([
    'email',
    'is_verified',
])
SecondaryEmail._all_fields_ = [
    ('email', SecondaryEmail.email.validator),
    ('is_verified', SecondaryEmail.is_verified.validator),
]

ROUTES = {
}