~ubuntu-branches/ubuntu/utopic/eclipse-linuxtools/utopic

« back to all changes in this revision

Viewing changes to lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/internal/tmf/ui/project/wizards/tracepkg/TracePackageBookmarkElement.java

  • Committer: Package Import Robot
  • Author(s): Jakub Adam
  • Date: 2014-05-12 18:11:40 UTC
  • mfrom: (3.1.2 sid)
  • Revision ID: package-import@ubuntu.com-20140512181140-w237r3vsah1tmybz
Tags: 2.2.1-1
* New upstream release.
* Refreshed d/patches.
* Removed eclipse-cdt-valgrind-remote package, all its functionality
  is now provided by eclipse-cdt-profiling-framework-remote.
* Added remove-license-feature.patch.
* Bump Standards-Version to 3.9.5.
* Enable eclipse-changelog package.
* Enable eclipse-rpm-editor package.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*******************************************************************************
 
2
 * Copyright (c) 2013 Ericsson
 
3
 *
 
4
 * All rights reserved. This program and the accompanying materials are
 
5
 * made available under the terms of the Eclipse Public License v1.0 which
 
6
 * accompanies this distribution, and is available at
 
7
 * http://www.eclipse.org/legal/epl-v10.html
 
8
 *
 
9
 * Contributors:
 
10
 *     Marc-Andre Laperle - Initial API and implementation
 
11
 *******************************************************************************/
 
12
 
 
13
package org.eclipse.linuxtools.internal.tmf.ui.project.wizards.tracepkg;
 
14
 
 
15
import java.util.List;
 
16
import java.util.Map;
 
17
 
 
18
import org.eclipse.linuxtools.internal.tmf.ui.Activator;
 
19
import org.eclipse.swt.graphics.Image;
 
20
 
 
21
/**
 
22
 * A trace package element representing the bookmarks of a trace
 
23
 *
 
24
 * @author Marc-Andre Laperle
 
25
 */
 
26
public class TracePackageBookmarkElement extends TracePackageElement {
 
27
    private static final String BOOKMARK_IMAGE_PATH = "icons/elcl16/bookmark_obj.gif"; //$NON-NLS-1$
 
28
    private final List<Map<String, String>> bookmarkAttribs;
 
29
 
 
30
    /**
 
31
     * Construct a bookmark element containing all the bookmarks
 
32
     *
 
33
     * @param parent
 
34
     *            the parent node
 
35
     * @param bookmarkAttribs
 
36
     *            the bookmarks for the trace
 
37
     */
 
38
    public TracePackageBookmarkElement(TracePackageElement parent, List<Map<String, String>> bookmarkAttribs) {
 
39
        super(parent);
 
40
        this.bookmarkAttribs = bookmarkAttribs;
 
41
    }
 
42
 
 
43
    @Override
 
44
    public long getSize(boolean checkedOnly) {
 
45
        return 0;
 
46
    }
 
47
 
 
48
    @Override
 
49
    public String getText() {
 
50
        return Messages.TracePackage_Bookmarks;
 
51
    }
 
52
 
 
53
    @Override
 
54
    public Image getImage() {
 
55
        return Activator.getDefault().getImageFromImageRegistry(BOOKMARK_IMAGE_PATH);
 
56
    }
 
57
 
 
58
    /**
 
59
     * Get all the bookmarks
 
60
     *
 
61
     * @return the bookmarks
 
62
     */
 
63
    public List<Map<String, String>> getBookmarks() {
 
64
        return bookmarkAttribs;
 
65
    }
 
66
}
 
 
b'\\ No newline at end of file'