blob: b87f1855fecff2b61e0615c53862f1016e691770 [file] [log] [blame]
HIGUCHI Yuta9092db82016-01-03 18:45:01 -08001/*
Brian O'Connora09fe5b2017-08-03 21:12:30 -07002 * Copyright 2016-present Open Networking Foundation
HIGUCHI Yuta9092db82016-01-03 18:45:01 -08003 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16package org.onosproject.events;
17
18import java.util.Deque;
19
20import org.onosproject.event.Event;
21
22import com.google.common.annotations.Beta;
23
24/**
25 * Provides history of instance local ONOS Events.
26 */
27@Beta
28public interface EventHistoryService {
29
30 /**
31 * Returns unmodifiable view of ONOS events history.
32 *
33 * @return ONOS events (First element is the oldest event stored)
34 */
35 Deque<Event<?, ?>> history();
36
37 /**
38 * Clears all stored history.
39 */
40 void clear();
41}