Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Issue URL: https://github.com/sunpy/sunpy/issues/532
- class Wave(Attr, _Range):
- def __init__(self, wavemin, wavemax, waveunit='Angstrom'):
- self.min, self.max = sorted(
- to_angstrom(v, waveunit) for v in [float(wavemin), float(wavemax)]
- )
- self.unit = 'Angstrom'
- Attr.__init__(self)
- _Range.__init__(self, self.min, self.max, self.__class__)
- def collides(self, other):
- return isinstance(other, self.__class__)
- def __repr__(self):
- return 'Min: {0}, Max: {1}, Units Used: {2}'.format(self.min, self.max, self.unit)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement