2 * Copyright (C) 2015 - EfficiOS Inc., Alexandre Montplaisir <alexmonthy@efficios.com>
4 * This library is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU Lesser General Public License, version 2.1 only,
6 * as published by the Free Software Foundation.
8 * This library is distributed in the hope that it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
13 * You should have received a copy of the GNU Lesser General Public License
14 * along with this library; if not, write to the Free Software Foundation,
15 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18 package org
.lttng
.ust
.agent
;
20 import java
.util
.Collection
;
24 * Interface to define LTTng Java agents.
26 * An "agent" is a representative of an LTTng session daemon in the Java world.
27 * It tracks the settings of a tracing session as they defined in the session
30 * It also track the current logging handlers that are sending events to UST.
32 * @author Alexandre Montplaisir
35 * The type of logging handler that should register to this agent
37 public interface ILttngAgent
<T
extends ILttngHandler
> {
39 // ------------------------------------------------------------------------
40 // Agent configuration elements
41 // ------------------------------------------------------------------------
44 * Tracing domains. Corresponds to domains defined by LTTng Tools.
50 private Domain(int value
) {
60 * The tracing domain of this agent.
62 * @return The tracing domain.
66 // ------------------------------------------------------------------------
67 // Log handler registering
68 // ------------------------------------------------------------------------
71 * Register a handler to this agent.
74 * The handler to register
76 void registerHandler(T handler
);
79 * Deregister a handler from this agent.
82 * The handler to deregister.
84 void unregisterHandler(T handler
);
86 // ------------------------------------------------------------------------
87 // Tracing session parameters
88 // ------------------------------------------------------------------------
91 * Query if a given event is currently enabled in a current tracing session,
92 * meaning it should be sent to UST.
95 * The name of the event to check.
96 * @return True if the event is currently enabled, false if it is not.
98 boolean isEventEnabled(String eventName
);
101 * Return the list of application contexts enabled in the tracing sessions.
103 * @return The application contexts, first indexed by retriever name, then
106 Collection
<Map
.Entry
<String
, Map
<String
, Integer
>>> getEnabledAppContexts();
This page took 0.032187 seconds and 4 git commands to generate.