Qucs-S S-parameter Viewer & RF Synthesis Tools
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
jinja2.runtime.Undefined Class Reference
Inheritance diagram for jinja2.runtime.Undefined:
Inheritance graph
[legend]

Public Member Functions

None __init__ (self, t.Optional[str] hint=None, t.Any obj=missing, t.Optional[str] name=None, t.Type[TemplateRuntimeError] exc=UndefinedError)
 
t.Any __getattr__ (self, str name)
 
bool __eq__ (self, t.Any other)
 
bool __ne__ (self, t.Any other)
 
int __hash__ (self)
 
str __str__ (self)
 
int __len__ (self)
 
t.Iterator[t.Any] __iter__ (self)
 
t.AsyncIterator[t.Any] __aiter__ (self)
 
bool __bool__ (self)
 
str __repr__ (self)
 

Protected Member Functions

str _undefined_message (self)
 
"te.NoReturn" _fail_with_undefined_error (self, *t.Any args, **t.Any kwargs)
 

Protected Attributes

 _undefined_hint
 
 _undefined_obj
 
 _undefined_name
 
 _undefined_exception
 
 _undefined_message
 

Detailed Description

The default undefined type. This can be printed, iterated, and treated as
a boolean. Any other operation will raise an :exc:`UndefinedError`.

>>> foo = Undefined(name='foo')
>>> str(foo)
''
>>> not foo
True
>>> foo + 42
Traceback (most recent call last):
  ...
jinja2.exceptions.UndefinedError: 'foo' is undefined

Member Function Documentation

◆ _fail_with_undefined_error()

"te.NoReturn" jinja2.runtime.Undefined._fail_with_undefined_error (   self,
*t.Any  args,
**t.Any   kwargs 
)
protected
Raise an :exc:`UndefinedError` when operations are performed
on the undefined value.

◆ _undefined_message()

str jinja2.runtime.Undefined._undefined_message (   self)
protected
Build a message about the undefined value based on how it was
accessed.

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