Added business rules smart notifications feature.
Merge remote-tracking branch 'upstream/master' into bp_rule_state_child_ack

Conflicts:
	shinken/objects/schedulingitem.py
	test/quick_tests.sh
	test/test_properties_defaults.py
Fixed get_template function.

The parameter 'use' is defined as ListProp, and may be a list. In such a
case, get_templates functnions fails.
Merge pull request #988 from geektophe/fix_item_multivalue

FIX: Fixed Item's get_template method.
Fixes a non tested case: single service override.
Fixed Config's `resource_macros_names` definition.

The `resource_macros_names` in the `Config` class was declared as
`StringProp`, but this attribute is a list object. This mislead the
multi valued attribute processing that returned the last list element
rather than the list itself.

Also removed the last uncecessary [] on the `_echo` command definition.
Fixed test_properties_defaults.py modified in #979
Merge pull request #989 from geektophe/fix_single_service_override

FIX: fixes regressions introduced in #984
Merge remote-tracking branch 'upstream/master' into bp_rule_state_child_ack
Enhanced smart notifications in business rules.

- Smart notifications acknowledgement and downtime detection is now based
  on service problems management.
- By default, downtimes are not checked, unless explicitely told to do
  so through the `business_rule_downtime_as_ack` flag.
Fixed problems based smart notifications.

At the previous position, the problems were not filled. Delayed problems
acknowledgements detection on notification blocking processing.
Fix: default templates
Fix on impacts/problems retention loaded services

When services in non ok state were loaded from retention,
impacts/problems hierarchy was not loaded no rebuild, which breaked the
notification processing.

This patch fixes this issue by forcing problems/impacts registration even when
no state change is detected.
Fixed new attributes default values.
Merge pull request #986 from geektophe/bp_rule_state_child_ack

Added business rules smart notifications feature.
Added reversed (negative) xof business rules.

Standard Xof: business rules are used to express idioms such as "at
least X services OK", or "at least X hosts UP". Negative business rules allow
to use the reversed form to express idioms such as "at most X services
WARNING or CRITICAL" or "at most X hosts DOWN".

Also factorised Xof elements processing using an inner function.

Finall, fixed test_properties_defaults.py (forgot to update it in
previous pull request).
Merge pull request #992 from geektophe/pb_rules_negative_xof

Added reversed (negative) Xof business rules.