Project

General

Profile

Download (1.31 KB) Statistics
| Branch: | Tag: | Revision:
1
/**
2
* Copyright (C) 2014 EDIT
3
* European Distributed Institute of Taxonomy
4
* http://www.e-taxonomy.eu
5
*
6
* The contents of this file are subject to the Mozilla Public License Version 1.1
7
* See LICENSE.TXT at the top of this package for the full license terms.
8
*/
9
package eu.etaxonomy.taxeditor.editor.view.derivate;
10

    
11
import org.eclipse.jface.viewers.ISelection;
12

    
13
/**
14
 * Wrapper for {@link ISelection} which additionally holds a
15
 * reference to the {@link DerivateView}
16
 * @author pplitzner
17
 * @date 14.05.2014
18
 *
19
 */
20
public class DerivateViewSelection implements ISelection {
21

    
22
    private final ISelection selection;
23
    private final DerivateView derivateView;
24

    
25
    /**
26
     * @param selection
27
     * @param derivateView
28
     */
29
    public DerivateViewSelection(ISelection selection, DerivateView derivateView) {
30
        super();
31
        this.selection = selection;
32
        this.derivateView = derivateView;
33
    }
34

    
35
    /**
36
     * @return the selection
37
     */
38
    public ISelection getSelection() {
39
        return selection;
40
    }
41

    
42
    /**
43
     * @return the derivateView
44
     */
45
    public DerivateView getDerivateView() {
46
        return derivateView;
47
    }
48

    
49
    /* (non-Javadoc)
50
     * @see org.eclipse.jface.viewers.ISelection#isEmpty()
51
     */
52
    @Override
53
    public boolean isEmpty() {
54
        return selection.isEmpty();
55
    }
56

    
57
}
(5-5/6)