129
|
1 /*******************************************************************************
|
|
2 * Copyright (c) 2000, 2008 IBM Corporation and others.
|
|
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
|
|
7 *
|
|
8 * Contributors:
|
|
9 * IBM Corporation - initial API and implementation
|
|
10 * Port to the D programming language:
|
|
11 * Frank Benoit <benoit@tionex.de>
|
|
12 *******************************************************************************/
|
|
13 module dwtx.jface.text.projection.Fragment;
|
|
14
|
131
|
15 import dwtx.jface.text.projection.ProjectionMapping; // packageimport
|
|
16 import dwtx.jface.text.projection.ChildDocumentManager; // packageimport
|
|
17 import dwtx.jface.text.projection.SegmentUpdater; // packageimport
|
|
18 import dwtx.jface.text.projection.Segment; // packageimport
|
|
19 import dwtx.jface.text.projection.ProjectionDocument; // packageimport
|
|
20 import dwtx.jface.text.projection.FragmentUpdater; // packageimport
|
|
21 import dwtx.jface.text.projection.ProjectionDocumentEvent; // packageimport
|
|
22 import dwtx.jface.text.projection.ChildDocument; // packageimport
|
|
23 import dwtx.jface.text.projection.IMinimalMapping; // packageimport
|
|
24 import dwtx.jface.text.projection.ProjectionTextStore; // packageimport
|
|
25 import dwtx.jface.text.projection.ProjectionDocumentManager; // packageimport
|
|
26
|
|
27
|
129
|
28 import dwt.dwthelper.utils;
|
|
29
|
|
30 import dwtx.jface.text.Position;
|
|
31
|
|
32
|
|
33 /**
|
|
34 * Internal class. Do not use. Only public for testing purposes.
|
|
35 * <p>
|
|
36 * A fragment is a range of the master document that has an image, the so called
|
|
37 * segment, in a projection document.</p>
|
|
38 *
|
|
39 * @since 3.0
|
|
40 * @noinstantiate This class is not intended to be instantiated by clients.
|
|
41 * @noextend This class is not intended to be subclassed by clients.
|
|
42 */
|
|
43 public class Fragment : Position {
|
|
44
|
|
45 /**
|
|
46 * The corresponding segment of this fragment.
|
|
47 */
|
|
48 public Segment segment;
|
|
49
|
|
50 /**
|
|
51 * Creates a new fragment covering the given range.
|
|
52 *
|
|
53 * @param offset the offset of the fragment
|
|
54 * @param length the length of the fragment
|
|
55 */
|
|
56 public Fragment(int offset, int length) {
|
|
57 super(offset, length);
|
|
58 }
|
|
59 }
|