HomogeneousList¶
-
class
astropy.utils.collections.
HomogeneousList
(types, values=[])[source]¶ Bases:
list
A subclass of list that contains only elements of a given type or types. If an item that is not of the specified type is added to the list, a
TypeError
is raised.- Parameters
- typessequence of types
The types to accept.
- valuessequence, optional
An initial set of values.
Methods Summary
append
(self, x)extend
(self, x)insert
(self, i, x)L.insert(index, object) – insert object before index
Methods Documentation