properties

File Purpose: tools for simple properties

Functions

alias(attribute_name[, doc])

returns a property which is an alias to attribute_name.

alias_child(child_name, attribute_name[, ...])

returns a property which is an alias to obj.child_name.attribute_name.

alias_in(cls, attr, new_attr)

sets cls.new_attr to be an alias for cls.attr.

alias_key_of(dict_attribute_name, key, *[, ...])

returns a property which is an alias to obj.dict_attribute_name[key].

alias_to_result_of(attribute_name[, doc])

returns a property which is an alias to the result of calling attribute_name.

dict_with_defaults_property(internal_name, ...)

return a property which gives a dictionary, and gives key_aliases a chance to edit the dict.

elementwise_property(attr, *[, as_array, ...])

return property which returns tuple(element.attr for element in self).

simple_property(internal_name, *[, doc, ...])

return a property with a setter and getter method for internal_name.

simple_tuple_property(*internal_names[, ...])

return a property which refers to a tuple of internal names.

weakref_property_simple(internal_attr[, doc])

defines a property which behaves like the value it contains, but is actually a weakref.