@staticmethod
def _get_triggering_events(inputs):
    """Get a list of triggering events.

        Args:
            inputs: A list of lists where the elements of the outer list
                represent inputs of a job, while the elements of inner lists
                are names of events in those inputs.

        Returns:
            A list of event tokens, one per input, that may be used to trigger
            the job.  If any of the inputs has no events in it, the result list
            will be empty.

        Example:
            inputs = [[token('/workflows/wf/events/j/i1/e1'),
                       token('/workflows/wf/events/j/i1/e2')].
                      [token('/workflows/wf/events/j/i2/e3')]]
            return: [token('/workflows/wf/events/j/i1/e1'),
                     token('/workflows/wf/events/j/i2/e3')]

            inputs = [[token('/workflows/wf/events/j/i1/e1'),
                       token('/workflows/wf/events/j/i1/e2')].
                      []]
            return: []
        """
    triggering_events = []
    for events in inputs:
        if not events:
            return []
        triggering_events.append(events[0])
    return triggering_events
