Question: Suppose I have a `Collection` of `DateTimes`, how I can filter all `DateTime` objects that have a time between 10h00m and 12h30m? 

For example: 

`new DateTime(2013,1,1,10,0)` - is right, 

`new DateTime(2013,1,1,16,0)` - is not. 

Parameters like month, year, day are not significant.
Any ideas?

Answer: 
You can really take advantage of joda's `LocalTime` class here :

```
LocalTime lowerBound = new LocalTime(10, 0);
LocalTime upperBound = new LocalTime(12, 30);

List<DateTime> filtered = new ArrayList<>();

for (DateTime dateTime : originals) {
    LocalTime localTime = new LocalTime(dateTime);
    if (lowerBound.isBefore(localTime) && upperBound.isAfter(localTime)) {
        filtered.add(dateTime);
    }
}

```

You may need to tweak for inclusive or exclusive, but `LocalTime` is `Comparable`, and on top of that, has friendly compare methods that help readability.
```
List<DateTime> filtered = new ArrayList<>();    
for (DateTime dt : mycollection){
    if (dt.getHourOfDay >= 10 && dt.getHourOfDay <= 12){
        if (dt.getHourOfDay != 12 || 
            (dt.getHourOfDay == 12 && dt.getMinuteOfHour <= 30)){
                filtered.add(dt);
        }
    }
}

```