OpenQuizz
Une application de gestion des contenus pédagogiques
Url Class Reference
Inheritance diagram for Url:
Collaboration diagram for Url:

Public Member Functions

def __init__ (self, *bool relative=False, typing.Optional[types.StrSequenceOrSet] schemes=None, bool require_tld=True, **kwargs)
 
- Public Member Functions inherited from Field
None __init__ (self, *typing.Any default=missing_, typing.Any missing=missing_, typing.Optional[str] data_key=None, typing.Optional[str] attribute=None, typing.Optional[typing.Union[typing.Callable[[typing.Any], typing.Any], typing.Iterable[typing.Callable[[typing.Any], typing.Any]],]] validate=None, bool required=False, typing.Optional[bool] allow_none=None, bool load_only=False, bool dump_only=False, typing.Optional[typing.Dict[str, str]] error_messages=None, typing.Optional[typing.Mapping[str, typing.Any]] metadata=None, **additional_metadata)
 
str __repr__ (self)
 
def __deepcopy__ (self, memo)
 
def get_value (self, obj, attr, accessor=None, default=missing_)
 
ValidationError make_error (self, str key, **kwargs)
 
def fail (self, str key, **kwargs)
 
def serialize (self, str attr, typing.Any obj, typing.Optional[typing.Callable[[typing.Any, str, typing.Any], typing.Any]] accessor=None, **kwargs)
 
def deserialize (self, typing.Any value, typing.Optional[str] attr=None, typing.Optional[typing.Mapping[str, typing.Any]] data=None, **kwargs)
 
def context (self)
 
- Public Member Functions inherited from FieldABC
def serialize (self, attr, obj, accessor=None)
 
def deserialize (self, value)
 

Data Fields

 relative
 
 require_tld
 
- Data Fields inherited from Field
 default
 
 attribute
 
 data_key
 
 validate
 
 validators
 
 allow_none
 
 load_only
 
 dump_only
 
 required
 
 missing
 
 metadata
 
 error_messages
 
 parent
 
 name
 
 root
 

Static Public Attributes

 default_error_messages
 
- Static Public Attributes inherited from String
 default_error_messages
 
- Static Public Attributes inherited from Field
 default_error_messages
 
- Static Public Attributes inherited from FieldABC
 parent
 
 name
 
 root
 

Detailed Description

An URL field.

:param default: Default value for the field if the attribute is not set.
:param relative: Whether to allow relative URLs.
:param require_tld: Whether to reject non-FQDN hostnames.
:param schemes: Valid schemes. By default, ``http``, ``https``,
    ``ftp``, and ``ftps`` are allowed.
:param kwargs: The same keyword arguments that :class:`String` receives.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
*bool   relative = False,
typing.Optional[types.StrSequenceOrSet]   schemes = None,
bool   require_tld = True,
**  kwargs 
)

Field Documentation

◆ default_error_messages

default_error_messages
static

◆ relative

relative

◆ require_tld

require_tld

The documentation for this class was generated from the following file: