1
/*******************************************************************************
2
* Copyright (c) 2004,2008 Red Hat, Inc.
3
* All rights reserved. This program and the accompanying materials
4
* are made available under the terms of the Eclipse Public License v1.0
5
* which accompanies this distribution, and is available at
6
* http://www.eclipse.org/legal/epl-v10.html
9
* Keith Seitz <keiths@redhat.com> - initial API and implementation
10
* Kent Sebastian <ksebasti@redhat.com> -
11
*******************************************************************************/
12
package org.eclipse.linuxtools.internal.oprofile.core;
14
import java.util.ArrayList;
16
import org.eclipse.jface.operation.IRunnableWithProgress;
17
import org.eclipse.linuxtools.internal.oprofile.core.daemon.OpInfo;
18
import org.eclipse.linuxtools.internal.oprofile.core.model.OpModelEvent;
19
import org.eclipse.linuxtools.internal.oprofile.core.model.OpModelImage;
22
* Interface for the core to utilize opxml. Platform plugins should define/register an
23
* OpxmlProvider for the core to use.
25
public interface IOpxmlProvider {
28
* Returns an <code>IRunnableWithProgress</code> that fetches generic information from opxml
29
* @param info <code>OpInfo</code> object for results
30
* @return <code>IRunnableWithProgress</code> that may be run by the caller
32
public IRunnableWithProgress info(OpInfo info);
35
* Returns an <code>IRunnableWithProgress</code> that fetches samples for the
36
* given <code>OpModelSession</code>
37
* @param eventName the event for which to fetch samples
38
* @param sessionName the session for which to fetch samples
39
* @param image the image being profiled to be returned to the caller
40
* @return <code>IRunnableWithProgress</code> that may be run by the caller
42
public IRunnableWithProgress modelData(String eventName, String sessionName, OpModelImage image);
45
* Returns an <code>IRunnableWithProgress</code> that checks the validity of the given
46
* event, unit mask, and counter combination
47
* @param ctr the counter
48
* @param event the String event name
49
* @param um the integer unit mask
50
* @param eventValid a size one array to hold the return result (see <code>CheckEventsProcessor</code>)
51
* @return <code>IRunnableWithProgress</code> that may be run by the caller
53
public IRunnableWithProgress checkEvents(int ctr, String event, int um, int[] eventValid);
56
* Returns an /code>IRunnableWithProgress</code> that fetches the list of sessions
57
* @param info the <code>OpInfo</code> for oprofile
58
* @param sessionList an <code>ArrayList</code> in which to return the list of sessions
59
* @return <code>IRunnableWithProgress</code> that may be run by the caller
61
public IRunnableWithProgress sessions(ArrayList<OpModelEvent> sessionList);