pytilities.geometry.boundvector.BoundVector

Package pytilities :: Package geometry :: Module boundvector :: Class BoundVector |
[hide private]
[frames] | no frames]

# Class BoundVector

source code

       object --+
                |
    vector.Vector --+
                    |
                   BoundVector

Vector whose x and y values are stored elsewhere.

Put differently, it creates a vector view of an x and a y value.

For Vector specific documentation, see Vector.

Instance Methods | [hide private]
__init__(self, target, x_attribute, y_attribute) Construct a BoundVector | source code
Inherited from `vector.Vector`: `Delegator`, `__abs__`, `__add__`, `__copy__`, `__div__`, `__eq__`, `__floordiv__`, `__getattr__`, `__getitem__`, `__iadd__`, `__imul__`, `__iter__`, `__len__`, `__mul__`, `__neg__`, `__neq__`, `__pos__`, `__rdiv__`, `__rfloordiv__`, `__rmul__`, `__rtruediv__`, `__setitem__`, `__str__`, `__sub__`, `__truediv__`, `assign`, `copy`, `cross`, `dot`, `move_by`, `move_to`, `normalize`, `normalized`, `reflect` Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__sizeof__`, `__subclasshook__`

Class Variables | [hide private]
Inherited from `vector.Vector`: `INFINITY`, `NULL` Inherited from `vector.Vector` (private): `_delegator_factory`

Properties | [hide private]
Inherited from `vector.Vector`: `length`, `length_squared`, `x`, `y` Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, target, x_attribute, y_attribute) (Constructor) | source code
Construct a BoundVector X and y attributes will be looked up on `target` with names `x_attribute` and `y_attribute`. Parameters: target the object to bind to. The object on which the x and y attributes reside. x_attribute :: string name of attribute of the x value on the target y_attribute :: string name of attribute of the y value on the target Overrides: object.__init__