replaced a lot of deprecated code; if someone runs into a commit conflict afterwards...
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / ui / text / SingleTokenPHPScanner.java
1 /*
2  * (c) Copyright IBM Corp. 2000, 2001.
3  * All Rights Reserved.
4  */
5
6 package net.sourceforge.phpdt.ui.text;
7
8
9 import java.util.List;
10
11 import net.sourceforge.phpdt.internal.ui.text.AbstractJavaScanner;
12
13 import org.eclipse.jface.preference.IPreferenceStore;
14
15
16 /**
17  * 
18  */
19 public final class SingleTokenPHPScanner extends AbstractJavaScanner{
20         
21         
22         private String[] fProperty;
23         
24         public SingleTokenPHPScanner(IColorManager manager, IPreferenceStore store, String property) {
25                 super(manager, store);
26                 fProperty= new String[] { property };
27                 initialize();
28         }
29
30         /*
31          * @see AbstractJavaScanner#getTokenProperties()
32          */
33         protected String[] getTokenProperties() {
34                 return fProperty;
35         }
36
37         /*
38          * @see AbstractJavaScanner#createRules()
39          */
40         protected List createRules() {
41                 setDefaultReturnToken(getToken(fProperty[0]));
42                 return null;
43         }
44 }
45