1 19 package org.netbeans.modules.xml.tax.beans.editor; 20 21 import org.netbeans.tax.TreeUtilities; 22 23 29 public class EncodingEditor extends NullChoicePropertyEditor { 30 31 32 private static String [] items; 33 34 35 39 40 public EncodingEditor () { 41 super (getItems()); 42 } 43 44 45 49 51 public boolean supportsEditingTaggedValues () { 52 return true; 53 } 54 55 56 60 62 public static String [] getItems () { 63 if ( items == null ) { 64 String [] engs = (String []) TreeUtilities.getSupportedEncodings().toArray (new String [0]); 65 items = new String [engs.length + 1]; 66 67 items[0] = DEFAULT_NULL; 68 for (int i = 0; i < engs.length; i++) { 69 items[i + 1] = engs[i]; 70 } 71 } 72 return items; 73 } 74 75 } 76 | Popular Tags |