class documentation

class MaskingAdapter(HasTraits): (source)

View In Hierarchy

Apply a mask to values in a context that are compatible.

Method adapt_getitem Return region in 'value' that fits our mask.
Method adapt_setitem Modify 'value' so that it only affects the masked region of 'name'.
Class Variable __implements__ Undocumented
Method _empty_of_local_shape Create an empty array whose shape matches its environment.
def adapt_getitem(self, context, name, value): (source)

Return region in 'value' that fits our mask.

def adapt_setitem(self, context, name, value): (source)

Modify 'value' so that it only affects the masked region of 'name'.

__implements__ = (source)

Undocumented

def _empty_of_local_shape(self, context, dtype): (source)

Create an empty array whose shape matches its environment. This kind of behavior is necessary because we allow new bindings to be created through masking adapters and need to create a shape for the real, unmasked array. The current behavior is to assume a 'depth' array exists and to use its shape. FIXME