obspy/obspy — pull request #634 by claudiodsf (2013-09-12 13:43:41+00:00)
Title: Fix for zero valued int and float attributes in core.event._eventTypeClassFactory()

Zero valued int and float attributes belonging to an `_eventTypeClassFactory()` object are tested as `False`.
This creates problems like this:
```python
>>> from obspy.core.event import CompositeTime
>>> c = CompositeTime(2011, 1, 1, 0, 0, 0)
>>> print c
CompositeTime(year=2011, month=1, day=1)
```
where `hour`, `minute` and `second` are not printed, because equal to `0.0`.

Or this:
```python
>>> from obspy.core.event import CompositeTime
>>> c = CompositeTime()
>>> c.hour = 0
>>> print bool(c)
False
```
where `c` tests as False, even if not empty.

This pull request fixes this behavior and produces the correct output, i.e.:
```python
CompositeTime
year: 2011
month: 1
day: 1
hour: 0
minute: 0
second: 0.0
```
for the first example, and:
```python
True
```
for the second one.

Tests related to this pull request are all passing.
However, not all the tests are passing right now (and the Travis build should likely fail) due to unrelated modifications to other parts of the codebase (`obspy.imaging`).