rem
stringlengths 0
477k
| add
stringlengths 0
313k
| context
stringlengths 6
599k
|
---|---|---|
piRegistry.loadPlugin(loader, "", "", false); | final PluginDescriptor descr = piRegistry.loadPlugin(loader, "", "", false); descriptors.add(descr); | public void loadPlugins(PluginRegistry piRegistry) { if (jarFile == null) { return; } final InitJarPluginLoader loader = new InitJarPluginLoader(); for (Enumeration e = jarFile.entries(); e.hasMoreElements();) { final JarEntry entry = (JarEntry) e.nextElement(); if (entry.getName().endsWith(".jar")) { try { // Load it loader.setIs(jarFile.getInputStream(entry)); piRegistry.loadPlugin(loader, "", "", false); } catch (IOException ex) { BootLog.error("Cannot load " + entry.getName(), ex); } catch (PluginException ex) { BootLog.error("Cannot load " + entry.getName(), ex); } } } } |
return descriptors; | public void loadPlugins(PluginRegistry piRegistry) { if (jarFile == null) { return; } final InitJarPluginLoader loader = new InitJarPluginLoader(); for (Enumeration e = jarFile.entries(); e.hasMoreElements();) { final JarEntry entry = (JarEntry) e.nextElement(); if (entry.getName().endsWith(".jar")) { try { // Load it loader.setIs(jarFile.getInputStream(entry)); piRegistry.loadPlugin(loader, "", "", false); } catch (IOException ex) { BootLog.error("Cannot load " + entry.getName(), ex); } catch (PluginException ex) { BootLog.error("Cannot load " + entry.getName(), ex); } } } } |
|
return screenIsAttr[pos]; | return screenIsAttr[pos] == '1' ? true : false; | protected final boolean isAttributePlace(int pos) { return screenIsAttr[pos]; } |
jComponent.getContentPane().setLayout(new SwingContainerLayout(this)); | public SwingWindowPeer(SwingToolkit toolkit, Window window) { super(toolkit, window, new SwingWindow(window)); SwingToolkit.copyAwtProperties(window, jComponent); } |
|
System.out.println("User Home = " + System.getProperty("user.home")); | private void checkLegacy() { // we check if the sessions file already exists in the directory // if it does exist we are working with an old install so we // need to set the settings directory to the users directory File ses = new File("sessions"); if(ses.exists()) { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.dir") + File.separator); } else { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.home") + File.separator + ".tn5250j" + File.separator); } } |
|
log.info("reserved triple indirect block: "+tripleIndirectBlockNr); | private final void registerBlockIndex(long i, long blockNr) throws FileSystemException, IOException{ final long blockCount = getSizeInBlocks(); final int indirectCount = getIndirectCount(); long allocatedBlocks = i; if(i != blockCount) throw new FileSystemException( "Trying to register block "+i+" (counts from 0), when"+ " INode contains only "+blockCount+" blocks"); log.debug("registering block #"+blockNr); setDirty(true); //the direct blocks (0; 11) if(i<12) { Ext2Utils.set32(data, 40+(int)i*4, blockNr); return; } //see the indirect blocks (12; indirectCount-1) i-=12; if(i<indirectCount) { long indirectBlockNr; //the 12th index points to the indirect block if(i==0) { //need to reserve the indirect block itself, as this is the //first time it is used indirectBlockNr = findFreeBlock(allocatedBlocks++); Ext2Utils.set32(data, 40+12*4, indirectBlockNr); //log.debug("reserved indirect block: "+indirectBlockNr); //need to blank the block so that e2fsck does not complain byte[] zeroes=new byte[fs.getBlockSize()]; //blank the block Arrays.fill(zeroes, 0, fs.getBlockSize(), (byte)0); fs.writeBlock(indirectBlockNr, zeroes, false); } else //the indirect block has already been used indirectBlockNr = Ext2Utils.get32(data,40+12*4); indirectWrite( indirectBlockNr, i, allocatedBlocks, blockNr, 1 ); return; } //see the double indirect blocks (indirectCount; doubleIndirectCount-1) i-=indirectCount; final int doubleIndirectCount = indirectCount * indirectCount; if(i<doubleIndirectCount) { long doubleIndirectBlockNr; //the 13th index points to the double indirect block if(i==0) { //need to reserve the double indirect block itself doubleIndirectBlockNr = findFreeBlock(allocatedBlocks++); Ext2Utils.set32(data, 40+13*4, doubleIndirectBlockNr); //log.debug("reserved double indirect block: "+doubleIndirectBlockNr); //need to blank the block so that e2fsck does not complain byte[] zeroes=new byte[fs.getBlockSize()]; //blank the block Arrays.fill(zeroes, 0, fs.getBlockSize(), (byte)0); fs.writeBlock(doubleIndirectBlockNr, zeroes, false); } else doubleIndirectBlockNr = Ext2Utils.get32(data, 40+13*4); indirectWrite( doubleIndirectBlockNr, i, allocatedBlocks, blockNr, 2 ); return; } //see the triple indirect blocks (doubleIndirectCount; tripleIndirectCount-1) final int tripleIndirectCount = indirectCount * indirectCount * indirectCount; i-=doubleIndirectCount; if(i<tripleIndirectCount) { long tripleIndirectBlockNr; //the 14th index points to the triple indirect block if(i==0) { //need to reserve the triple indirect block itself tripleIndirectBlockNr = findFreeBlock(allocatedBlocks++); Ext2Utils.set32(data, 40+13*4, tripleIndirectBlockNr);log.info("reserved triple indirect block: "+tripleIndirectBlockNr); //need to blank the block so that e2fsck does not complain byte[] zeroes=new byte[fs.getBlockSize()]; //blank the block Arrays.fill(zeroes, 0, fs.getBlockSize(), (byte)0); fs.writeBlock(tripleIndirectBlockNr, zeroes, false); } else tripleIndirectBlockNr = Ext2Utils.get32(data, 40+14*4); indirectWrite( tripleIndirectBlockNr, i, allocatedBlocks, blockNr, 3 ); return; } //shouldn't get here throw new FileSystemException("Internal FS exception: getDataBlockIndex(i="+i+")"); } |
|
return entry.getCertificates(); | return ((JarEntry) ((JarURLLoader) loader).jarfile.getEntry(name)) .getCertificates(); | Certificate[] getCertificates() { return entry.getCertificates(); } |
return (Class)AccessController.doPrivileged | result = (Class)AccessController.doPrivileged | protected Class findClass(final String className) throws ClassNotFoundException { // Just try to find the resource by the (almost) same name String resourceName = className.replace('.', '/') + ".class"; Resource resource = findURLResource(resourceName); if (resource == null) throw new ClassNotFoundException(className + " not found in " + urls); // Try to read the class data, create the CodeSource, Package and // construct the class (and watch out for those nasty IOExceptions) try { byte[] data; InputStream in = resource.getInputStream(); try { int length = resource.getLength(); if (length != -1) { // We know the length of the data. // Just try to read it in all at once data = new byte[length]; int pos = 0; while (length - pos > 0) { int len = in.read(data, pos, length - pos); if (len == -1) throw new EOFException("Not enough data reading from: " + in); pos += len; } } else { // We don't know the data length. // Have to read it in chunks. ByteArrayOutputStream out = new ByteArrayOutputStream(4096); byte[] b = new byte[4096]; int l = 0; while (l != -1) { l = in.read(b); if (l != -1) out.write(b, 0, l); } data = out.toByteArray(); } } finally { in.close(); } final byte[] classData = data; // Now get the CodeSource final CodeSource source = resource.getCodeSource(); // Find out package name String packageName = null; int lastDot = className.lastIndexOf('.'); if (lastDot != -1) packageName = className.substring(0, lastDot); if (packageName != null && getPackage(packageName) == null) { // define the package Manifest manifest = resource.loader.getManifest(); if (manifest == null) definePackage(packageName, null, null, null, null, null, null, null); else definePackage(packageName, manifest, resource.loader.baseURL); } // And finally construct the class! SecurityManager sm = System.getSecurityManager(); if (sm != null && securityContext != null) { return (Class)AccessController.doPrivileged (new PrivilegedAction() { public Object run() { return defineClass(className, classData, 0, classData.length, source); } }, securityContext); } else return defineClass(className, classData, 0, classData.length, source); } catch (IOException ioe) { throw new ClassNotFoundException(className, ioe); } } |
return defineClass(className, classData, 0, classData.length, source); | result = defineClass(className, classData, 0, classData.length, source); super.setSigners(result, resource.getCertificates()); return result; | protected Class findClass(final String className) throws ClassNotFoundException { // Just try to find the resource by the (almost) same name String resourceName = className.replace('.', '/') + ".class"; Resource resource = findURLResource(resourceName); if (resource == null) throw new ClassNotFoundException(className + " not found in " + urls); // Try to read the class data, create the CodeSource, Package and // construct the class (and watch out for those nasty IOExceptions) try { byte[] data; InputStream in = resource.getInputStream(); try { int length = resource.getLength(); if (length != -1) { // We know the length of the data. // Just try to read it in all at once data = new byte[length]; int pos = 0; while (length - pos > 0) { int len = in.read(data, pos, length - pos); if (len == -1) throw new EOFException("Not enough data reading from: " + in); pos += len; } } else { // We don't know the data length. // Have to read it in chunks. ByteArrayOutputStream out = new ByteArrayOutputStream(4096); byte[] b = new byte[4096]; int l = 0; while (l != -1) { l = in.read(b); if (l != -1) out.write(b, 0, l); } data = out.toByteArray(); } } finally { in.close(); } final byte[] classData = data; // Now get the CodeSource final CodeSource source = resource.getCodeSource(); // Find out package name String packageName = null; int lastDot = className.lastIndexOf('.'); if (lastDot != -1) packageName = className.substring(0, lastDot); if (packageName != null && getPackage(packageName) == null) { // define the package Manifest manifest = resource.loader.getManifest(); if (manifest == null) definePackage(packageName, null, null, null, null, null, null, null); else definePackage(packageName, manifest, resource.loader.baseURL); } // And finally construct the class! SecurityManager sm = System.getSecurityManager(); if (sm != null && securityContext != null) { return (Class)AccessController.doPrivileged (new PrivilegedAction() { public Object run() { return defineClass(className, classData, 0, classData.length, source); } }, securityContext); } else return defineClass(className, classData, 0, classData.length, source); } catch (IOException ioe) { throw new ClassNotFoundException(className, ioe); } } |
"SplitPaneDivider.border", BasicBorders.getSplitPaneDividerBorder(), | protected void initComponentDefaults(UIDefaults defaults) { Object[] uiDefaults; Color highLight = new Color(249, 247, 246); Color light = new Color(239, 235, 231); Color shadow = new Color(139, 136, 134); Color darkShadow = new Color(16, 16, 16); uiDefaults = new Object[] { "AbstractUndoableEdit.undoText", "Undo", "AbstractUndoableEdit.redoText", "Redo", "Button.background", new ColorUIResource(Color.LIGHT_GRAY), "Button.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { return BasicBorders.getButtonBorder(); } }, "Button.darkShadow", new ColorUIResource(Color.BLACK), "Button.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Button.foreground", new ColorUIResource(Color.BLACK), "Button.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("SPACE"), "pressed", KeyStroke.getKeyStroke("released SPACE"), "released" }), "Button.highlight", new ColorUIResource(Color.WHITE), "Button.light", new ColorUIResource(Color.LIGHT_GRAY), "Button.margin", new InsetsUIResource(2, 14, 2, 14), "Button.shadow", new ColorUIResource(Color.GRAY), "Button.textIconGap", new Integer(4), "Button.textShiftOffset", new Integer(0), "CheckBox.background", new ColorUIResource(new Color(204, 204, 204)), "CheckBox.border", new BorderUIResource.CompoundBorderUIResource(null, null), "CheckBox.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("SPACE"), "pressed", KeyStroke.getKeyStroke("released SPACE"), "released" }), "CheckBox.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBox.foreground", new ColorUIResource(darkShadow), "CheckBox.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxIcon(); } }, "CheckBox.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getMenuItemCheckIcon(); } }, "CheckBox.margin",new InsetsUIResource(2, 2, 2, 2), "CheckBox.textIconGap", new Integer(4), "CheckBox.textShiftOffset", new Integer(0), "CheckBoxMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.acceleratorForeground", new ColorUIResource(new Color(16, 16, 16)), "CheckBoxMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "CheckBoxMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "CheckBoxMenuItem.background", new ColorUIResource(light), "CheckBoxMenuItem.border", new BasicBorders.MarginBorder(), "CheckBoxMenuItem.borderPainted", Boolean.FALSE, "CheckBoxMenuItem.checkIcon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getCheckBoxMenuItemIcon(); } }, "CheckBoxMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "CheckBoxMenuItem.foreground", new ColorUIResource(darkShadow), "CheckBoxMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "CheckBoxMenuItem.selectionBackground", new ColorUIResource(Color.black), "CheckBoxMenuItem.selectionForeground", new ColorUIResource(Color.white), "ColorChooser.background", new ColorUIResource(light), "ColorChooser.cancelText", "Cancel", "ColorChooser.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ColorChooser.foreground", new ColorUIResource(darkShadow), "ColorChooser.hsbBlueText", "B", "ColorChooser.hsbBrightnessText", "B", "ColorChooser.hsbGreenText", "G", "ColorChooser.hsbHueText", "H", "ColorChooser.hsbNameText", "HSB", "ColorChooser.hsbRedText", "R", "ColorChooser.hsbSaturationText", "S", "ColorChooser.okText", "OK", "ColorChooser.previewText", "Preview", "ColorChooser.resetText", "Reset", "ColorChooser.rgbBlueMnemonic", "66", "ColorChooser.rgbBlueText", "Blue", "ColorChooser.rgbGreenMnemonic", "78", "ColorChooser.rgbGreenText", "Green", "ColorChooser.rgbNameText", "RGB", "ColorChooser.rgbRedMnemonic", "68", "ColorChooser.rgbRedText", "Red", "ColorChooser.sampleText", "Sample Text Sample Text", "ColorChooser.swatchesDefaultRecentColor", new ColorUIResource(light), "ColorChooser.swatchesNameText", "Swatches", "ColorChooser.swatchesRecentSwatchSize", new Dimension(10, 10), "ColorChooser.swatchesRecentText", "Recent:", "ColorChooser.swatchesSwatchSize", new Dimension(10, 10), "ComboBox.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "hidePopup", "PAGE_UP", "pageUpPassThrough", "PAGE_DOWN", "pageDownPassThrough", "HOME", "homePassThrough", "END", "endPassThrough" }), "ComboBox.background", new ColorUIResource(Color.white), "ComboBox.buttonBackground", new ColorUIResource(light), "ComboBox.buttonDarkShadow", new ColorUIResource(darkShadow), "ComboBox.buttonHighlight", new ColorUIResource(highLight), "ComboBox.buttonShadow", new ColorUIResource(shadow), "ComboBox.disabledBackground", new ColorUIResource(light), "ComboBox.disabledForeground", new ColorUIResource(Color.gray), "ComboBox.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ComboBox.foreground", new ColorUIResource(Color.black), "ComboBox.selectionBackground", new ColorUIResource(0, 0, 128), "ComboBox.selectionForeground", new ColorUIResource(Color.white), "Desktop.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "KP_LEFT", "left", "KP_RIGHT", "right", "ctrl F5", "restore", "LEFT", "left", "ctrl alt F6", "selectNextFrame", "UP", "up", "ctrl F6", "selectNextFrame", "RIGHT", "right", "DOWN", "down", "ctrl F7", "move", "ctrl F8", "resize", "ESCAPE", "escape", "ctrl TAB", "selectNextFrame", "ctrl F9", "minimize", "KP_UP", "up", "ctrl F4", "close", "KP_DOWN", "down", "ctrl F10", "maximize", "ctrl alt shift F6","selectPreviousFrame" }), "DesktopIcon.border", new BorderUIResource.CompoundBorderUIResource(null, null), "EditorPane.background", new ColorUIResource(Color.white), "EditorPane.border", BasicBorders.getMarginBorder(), "EditorPane.caretBlinkRate", new Integer(500), "EditorPane.caretForeground", new ColorUIResource(Color.black), "EditorPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "EditorPane.foreground", new ColorUIResource(Color.black), "EditorPane.inactiveForeground", new ColorUIResource(Color.gray), "EditorPane.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("shift UP"), "selection-up", KeyStroke.getKeyStroke("ctrl RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("shift ctrl LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("shift KP_UP"), "selection-up", KeyStroke.getKeyStroke("DOWN"), "caret-down", KeyStroke.getKeyStroke("shift ctrl T"), "previous-link-action", KeyStroke.getKeyStroke("ctrl LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("CUT"), "cut-to-clipboard", KeyStroke.getKeyStroke("END"), "caret-end-line", KeyStroke.getKeyStroke("shift PAGE_UP"), "selection-page-up", KeyStroke.getKeyStroke("KP_UP"), "caret-up", KeyStroke.getKeyStroke("DELETE"), "delete-next", KeyStroke.getKeyStroke("ctrl HOME"), "caret-begin", KeyStroke.getKeyStroke("shift LEFT"), "selection-backward", KeyStroke.getKeyStroke("ctrl END"), "caret-end", KeyStroke.getKeyStroke("BACK_SPACE"), "delete-previous", KeyStroke.getKeyStroke("shift ctrl RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("LEFT"), "caret-backward", KeyStroke.getKeyStroke("KP_LEFT"), "caret-backward", KeyStroke.getKeyStroke("shift KP_RIGHT"), "selection-forward", KeyStroke.getKeyStroke("ctrl SPACE"), "activate-link-action", KeyStroke.getKeyStroke("ctrl H"), "delete-previous", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "unselect", KeyStroke.getKeyStroke("ENTER"), "insert-break", KeyStroke.getKeyStroke("shift HOME"), "selection-begin-line", KeyStroke.getKeyStroke("RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl PAGE_UP"), "selection-page-left", KeyStroke.getKeyStroke("shift DOWN"), "selection-down", KeyStroke.getKeyStroke("PAGE_DOWN"), "page-down", KeyStroke.getKeyStroke("shift KP_LEFT"), "selection-backward", KeyStroke.getKeyStroke("shift ctrl O"), "toggle-componentOrientation", KeyStroke.getKeyStroke("ctrl X"), "cut-to-clipboard", KeyStroke.getKeyStroke("shift ctrl PAGE_DOWN"), "selection-page-right", KeyStroke.getKeyStroke("ctrl C"), "copy-to-clipboard", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("shift END"), "selection-end-line", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("HOME"), "caret-begin-line", KeyStroke.getKeyStroke("ctrl V"), "paste-from-clipboard", KeyStroke.getKeyStroke("KP_DOWN"), "caret-down", KeyStroke.getKeyStroke("ctrl A"), "select-all", KeyStroke.getKeyStroke("shift RIGHT"), "selection-forward", KeyStroke.getKeyStroke("shift ctrl END"), "selection-end", KeyStroke.getKeyStroke("COPY"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift ctrl KP_LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("ctrl T"), "next-link-action", KeyStroke.getKeyStroke("shift KP_DOWN"), "selection-down", KeyStroke.getKeyStroke("TAB"), "insert-tab", KeyStroke.getKeyStroke("UP"), "caret-up", KeyStroke.getKeyStroke("shift ctrl HOME"), "selection-begin", KeyStroke.getKeyStroke("shift PAGE_DOWN"), "selection-page-down", KeyStroke.getKeyStroke("KP_RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl KP_RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("PAGE_UP"), "page-up", KeyStroke.getKeyStroke("PASTE"), "paste-from-clipboard" }), "EditorPane.margin", new InsetsUIResource(3, 3, 3, 3), "EditorPane.selectionBackground", new ColorUIResource(Color.black), "EditorPane.selectionForeground", new ColorUIResource(Color.white), "FileChooser.acceptAllFileFilterText", "All Files (*.*)", "FileChooser.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancelSelection" }), "FileChooser.cancelButtonMnemonic", "67", "FileChooser.cancelButtonText", "Cancel", "FileChooser.cancelButtonToolTipText", "Abort file chooser dialog", "FileChooser.directoryDescriptionText", "Directory", "FileChooser.fileDescriptionText", "Generic File", "FileChooser.directoryOpenButtonMnemonic", "79", "FileChooser.helpButtonMnemonic", "72", "FileChooser.helpButtonText", "Help", "FileChooser.helpButtonToolTipText", "FileChooser help", "FileChooser.newFolderErrorSeparator", ":", "FileChooser.newFolderErrorText", "Error creating new folder", "FileChooser.openButtonMnemonic", "79", "FileChooser.openButtonText", "Open", "FileChooser.openButtonToolTipText", "Open selected file", "FileChooser.saveButtonMnemonic", "83", "FileChooser.saveButtonText", "Save", "FileChooser.saveButtonToolTipText", "Save selected file", "FileChooser.updateButtonMnemonic", "85", "FileChooser.updateButtonText", "Update", "FileChooser.updateButtonToolTipText", "Update directory listing", "FocusManagerClassName", "TODO", "FormattedTextField.background", new ColorUIResource(light), "FormattedTextField.caretForeground", new ColorUIResource(Color.black), "FormattedTextField.margin", new InsetsUIResource(0, 0, 0, 0), "FormattedTextField.caretBlinkRate", new Integer(500), "FormattedTextField.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "FormattedTextField.foreground", new ColorUIResource(Color.black), "FormattedTextField.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("KP_UP"), "increment", KeyStroke.getKeyStroke("END"), "caret-end-line", KeyStroke.getKeyStroke("shift ctrl O"), "toggle-componentOrientation", KeyStroke.getKeyStroke("shift KP_LEFT"), "selection-backward", KeyStroke.getKeyStroke("shift RIGHT"), "selection-forward", KeyStroke.getKeyStroke("KP_DOWN"), "decrement", KeyStroke.getKeyStroke("HOME"), "caret-begin-line", KeyStroke.getKeyStroke("ctrl V"), "paste-from-clipboard", KeyStroke.getKeyStroke("ctrl H"), "delete-previous", KeyStroke.getKeyStroke("KP_LEFT"), "caret-backward", KeyStroke.getKeyStroke("LEFT"), "caret-backward", KeyStroke.getKeyStroke("ctrl X"), "cut-to-clipboard", KeyStroke.getKeyStroke("KP_RIGHT"), "caret-forward", KeyStroke.getKeyStroke("UP"), "increment", KeyStroke.getKeyStroke("shift ctrl KP_RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("COPY"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift HOME"), "selection-begin-line", KeyStroke.getKeyStroke("ESCAPE"), "reset-field-edit", KeyStroke.getKeyStroke("RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("DOWN"), "decrement", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("PASTE"), "paste-from-clipboard", KeyStroke.getKeyStroke("shift ctrl RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "unselect", KeyStroke.getKeyStroke("ctrl A"), "select-all", KeyStroke.getKeyStroke("shift KP_RIGHT"), "selection-forward", KeyStroke.getKeyStroke("CUT"), "cut-to-clipboard", KeyStroke.getKeyStroke("ctrl LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("BACK_SPACE"), "delete-previous", KeyStroke.getKeyStroke("shift ctrl KP_LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("ctrl C"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift END"), "selection-end-line", KeyStroke.getKeyStroke("ctrl RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("DELETE"), "delete-next", KeyStroke.getKeyStroke("ENTER"), "notify-field-accept", KeyStroke.getKeyStroke("shift LEFT"), "selection-backward" }), "FormattedTextField.inactiveBackground", new ColorUIResource(light), "FormattedTextField.inactiveForeground", new ColorUIResource(Color.gray), "FormattedTextField.selectionBackground", new ColorUIResource(Color.black), "FormattedTextField.selectionForeground", new ColorUIResource(Color.white), "FormView.resetButtonText", "Reset", "FormView.submitButtonText", "Submit Query", "InternalFrame.activeTitleBackground", new ColorUIResource(0, 0, 128), "InternalFrame.activeTitleForeground", new ColorUIResource(Color.white), "InternalFrame.border", new UIDefaults.LazyValue() { public Object createValue(UIDefaults table) { Color lineColor = new Color(238, 238, 238); Border inner = BorderFactory.createLineBorder(lineColor, 1); Color shadowInner = new Color(184, 207, 229); Color shadowOuter = new Color(122, 138, 153); Border outer = BorderFactory.createBevelBorder(BevelBorder.RAISED, Color.WHITE, Color.WHITE, shadowOuter, shadowInner); Border border = new BorderUIResource.CompoundBorderUIResource(outer, inner); return border; } }, "InternalFrame.borderColor", new ColorUIResource(light), "InternalFrame.borderDarkShadow", new ColorUIResource(Color.BLACK), "InternalFrame.borderHighlight", new ColorUIResource(Color.WHITE), "InternalFrame.borderLight", new ColorUIResource(Color.LIGHT_GRAY), "InternalFrame.borderShadow", new ColorUIResource(Color.GRAY), "InternalFrame.closeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return new IconUIResource(BasicIconFactory.createEmptyFrameIcon()); } }, "InternalFrame.iconifyIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.inactiveTitleBackground", new ColorUIResource(Color.gray), "InternalFrame.inactiveTitleForeground", new ColorUIResource(Color.lightGray), "InternalFrame.maximizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.minimizeIcon", BasicIconFactory.createEmptyFrameIcon(), "InternalFrame.titleFont", new FontUIResource("Dialog", Font.BOLD, 12), "InternalFrame.windowBindings", new Object[] { "shift ESCAPE", "showSystemMenu", "ctrl SPACE", "showSystemMenu", "ESCAPE", "showSystemMenu" }, "Label.background", new ColorUIResource(light), "Label.disabledForeground", new ColorUIResource(Color.white), "Label.disabledShadow", new ColorUIResource(shadow), "Label.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Label.foreground", new ColorUIResource(darkShadow), "List.background", new ColorUIResource(Color.white), "List.border", new BasicBorders.MarginBorder(), "List.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("ctrl DOWN"), "selectNextRowChangeLead", KeyStroke.getKeyStroke("shift UP"), "selectPreviousRowExtendSelection", KeyStroke.getKeyStroke("ctrl RIGHT"), "selectNextColumnChangeLead", KeyStroke.getKeyStroke("shift ctrl LEFT"), "selectPreviousColumnExtendSelection", KeyStroke.getKeyStroke("shift KP_UP"), "selectPreviousRowExtendSelection", KeyStroke.getKeyStroke("DOWN"), "selectNextRow", KeyStroke.getKeyStroke("ctrl UP"), "selectPreviousRowChangeLead", KeyStroke.getKeyStroke("ctrl LEFT"), "selectPreviousColumnChangeLead", KeyStroke.getKeyStroke("CUT"), "cut", KeyStroke.getKeyStroke("END"), "selectLastRow", KeyStroke.getKeyStroke("shift PAGE_UP"), "scrollUpExtendSelection", KeyStroke.getKeyStroke("KP_UP"), "selectPreviousRow", KeyStroke.getKeyStroke("shift ctrl UP"), "selectPreviousRowExtendSelection", KeyStroke.getKeyStroke("ctrl HOME"), "selectFirstRowChangeLead", KeyStroke.getKeyStroke("shift LEFT"), "selectPreviousColumnExtendSelection", KeyStroke.getKeyStroke("ctrl END"), "selectLastRowChangeLead", KeyStroke.getKeyStroke("ctrl PAGE_DOWN"), "scrollDownChangeLead", KeyStroke.getKeyStroke("shift ctrl RIGHT"), "selectNextColumnExtendSelection", KeyStroke.getKeyStroke("LEFT"), "selectPreviousColumn", KeyStroke.getKeyStroke("ctrl PAGE_UP"), "scrollUpChangeLead", KeyStroke.getKeyStroke("KP_LEFT"), "selectPreviousColumn", KeyStroke.getKeyStroke("shift KP_RIGHT"), "selectNextColumnExtendSelection", KeyStroke.getKeyStroke("SPACE"), "addToSelection", KeyStroke.getKeyStroke("ctrl SPACE"), "toggleAndAnchor", KeyStroke.getKeyStroke("shift SPACE"), "extendTo", KeyStroke.getKeyStroke("shift ctrl SPACE"), "moveSelectionTo", KeyStroke.getKeyStroke("shift ctrl DOWN"), "selectNextRowExtendSelection", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "clearSelection", KeyStroke.getKeyStroke("shift HOME"), "selectFirstRowExtendSelection", KeyStroke.getKeyStroke("RIGHT"), "selectNextColumn", KeyStroke.getKeyStroke("shift ctrl PAGE_UP"), "scrollUpExtendSelection", KeyStroke.getKeyStroke("shift DOWN"), "selectNextRowExtendSelection", KeyStroke.getKeyStroke("PAGE_DOWN"), "scrollDown", KeyStroke.getKeyStroke("shift ctrl KP_UP"), "selectPreviousRowExtendSelection", KeyStroke.getKeyStroke("shift KP_LEFT"), "selectPreviousColumnExtendSelection", KeyStroke.getKeyStroke("ctrl X"), "cut", KeyStroke.getKeyStroke("shift ctrl PAGE_DOWN"), "scrollDownExtendSelection", KeyStroke.getKeyStroke("ctrl SLASH"), "selectAll", KeyStroke.getKeyStroke("ctrl C"), "copy", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "selectNextColumnChangeLead", KeyStroke.getKeyStroke("shift END"), "selectLastRowExtendSelection", KeyStroke.getKeyStroke("shift ctrl KP_DOWN"), "selectNextRowExtendSelection", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "selectPreviousColumnChangeLead", KeyStroke.getKeyStroke("HOME"), "selectFirstRow", KeyStroke.getKeyStroke("ctrl V"), "paste", KeyStroke.getKeyStroke("KP_DOWN"), "selectNextRow", KeyStroke.getKeyStroke("ctrl KP_DOWN"), "selectNextRowChangeLead", KeyStroke.getKeyStroke("shift RIGHT"), "selectNextColumnExtendSelection", KeyStroke.getKeyStroke("ctrl A"), "selectAll", KeyStroke.getKeyStroke("shift ctrl END"), "selectLastRowExtendSelection", KeyStroke.getKeyStroke("COPY"), "copy", KeyStroke.getKeyStroke("ctrl KP_UP"), "selectPreviousRowChangeLead", KeyStroke.getKeyStroke("shift ctrl KP_LEFT"), "selectPreviousColumnExtendSelection", KeyStroke.getKeyStroke("shift KP_DOWN"), "selectNextRowExtendSelection", KeyStroke.getKeyStroke("UP"), "selectPreviousRow", KeyStroke.getKeyStroke("shift ctrl HOME"), "selectFirstRowExtendSelection", KeyStroke.getKeyStroke("shift PAGE_DOWN"), "scrollDownExtendSelection", KeyStroke.getKeyStroke("KP_RIGHT"), "selectNextColumn", KeyStroke.getKeyStroke("shift ctrl KP_RIGHT"), "selectNextColumnExtendSelection", KeyStroke.getKeyStroke("PAGE_UP"), "scrollUp", KeyStroke.getKeyStroke("PASTE"), "paste" }), "List.font", new FontUIResource("Dialog", Font.PLAIN, 12), "List.foreground", new ColorUIResource(Color.black), "List.selectionBackground", new ColorUIResource(0, 0, 128), "List.selectionForeground", new ColorUIResource(Color.white), "List.focusCellHighlightBorder", new BorderUIResource. LineBorderUIResource(new ColorUIResource(Color.yellow)), "Menu.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.crossMenuMnemonic", Boolean.TRUE, "Menu.acceleratorForeground", new ColorUIResource(darkShadow), "Menu.acceleratorSelectionForeground", new ColorUIResource(Color.white), "Menu.arrowIcon", BasicIconFactory.getMenuArrowIcon(), "Menu.background", new ColorUIResource(light), "Menu.border", new BasicBorders.MarginBorder(), "Menu.borderPainted", Boolean.FALSE, "Menu.checkIcon", BasicIconFactory.getMenuItemCheckIcon(), "Menu.consumesTabs", Boolean.TRUE, "Menu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Menu.foreground", new ColorUIResource(darkShadow), "Menu.margin", new InsetsUIResource(2, 2, 2, 2), "Menu.selectedWindowInputMapBindings", new Object[] { "ESCAPE", "cancel", "DOWN", "selectNext", "KP_DOWN", "selectNext", "UP", "selectPrevious", "KP_UP", "selectPrevious", "LEFT", "selectParent", "KP_LEFT", "selectParent", "RIGHT", "selectChild", "KP_RIGHT", "selectChild", "ENTER", "return", "SPACE", "return" }, "Menu.menuPopupOffsetX", new Integer(0), "Menu.menuPopupOffsetY", new Integer(0), "Menu.submenuPopupOffsetX", new Integer(0), "Menu.submenuPopupOffsetY", new Integer(0), "Menu.selectionBackground", new ColorUIResource(Color.black), "Menu.selectionForeground", new ColorUIResource(Color.white), "MenuBar.background", new ColorUIResource(light), "MenuBar.border", new BasicBorders.MenuBarBorder(null, null), "MenuBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuBar.foreground", new ColorUIResource(darkShadow), "MenuBar.highlight", new ColorUIResource(highLight), "MenuBar.shadow", new ColorUIResource(shadow), "MenuBar.windowBindings", new Object[] { "F10", "takeFocus" }, "MenuItem.acceleratorDelimiter", "+", "MenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "MenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "MenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "MenuItem.background", new ColorUIResource(light), "MenuItem.border", new BasicBorders.MarginBorder(), "MenuItem.borderPainted", Boolean.FALSE, "MenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "MenuItem.foreground", new ColorUIResource(darkShadow), "MenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "MenuItem.selectionBackground", new ColorUIResource(Color.black), "MenuItem.selectionForeground", new ColorUIResource(Color.white), "OptionPane.background", new ColorUIResource(light), "OptionPane.border", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.buttonAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.buttonClickThreshhold", new Integer(500), "OptionPane.cancelButtonText", "Cancel", "OptionPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "OptionPane.foreground", new ColorUIResource(darkShadow), "OptionPane.messageAreaBorder", new BorderUIResource.EmptyBorderUIResource(0, 0, 0, 0), "OptionPane.messageForeground", new ColorUIResource(darkShadow), "OptionPane.minimumSize", new DimensionUIResource(BasicOptionPaneUI.MinimumWidth, BasicOptionPaneUI.MinimumHeight), "OptionPane.noButtonText", "No", "OptionPane.okButtonText", "OK", "OptionPane.windowBindings", new Object[] { "ESCAPE", "close" }, "OptionPane.yesButtonText", "Yes", "Panel.background", new ColorUIResource(light), "Panel.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Panel.foreground", new ColorUIResource(Color.black), "PasswordField.background", new ColorUIResource(light), "PasswordField.border", new BasicBorders.FieldBorder(null, null, null, null), "PasswordField.caretBlinkRate", new Integer(500), "PasswordField.caretForeground", new ColorUIResource(Color.black), "PasswordField.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "PasswordField.foreground", new ColorUIResource(Color.black), "PasswordField.inactiveBackground", new ColorUIResource(light), "PasswordField.inactiveForeground", new ColorUIResource(Color.gray), "PasswordField.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("END"), "caret-end-line", KeyStroke.getKeyStroke("shift ctrl O"), "toggle-componentOrientation", KeyStroke.getKeyStroke("shift KP_LEFT"), "selection-backward", KeyStroke.getKeyStroke("shift RIGHT"), "selection-forward", KeyStroke.getKeyStroke("HOME"), "caret-begin-line", KeyStroke.getKeyStroke("ctrl V"), "paste-from-clipboard", KeyStroke.getKeyStroke("ctrl H"), "delete-previous", KeyStroke.getKeyStroke("KP_LEFT"), "caret-backward", KeyStroke.getKeyStroke("LEFT"), "caret-backward", KeyStroke.getKeyStroke("ctrl X"), "cut-to-clipboard", KeyStroke.getKeyStroke("KP_RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl KP_RIGHT"), "selection-end-line", KeyStroke.getKeyStroke("COPY"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift HOME"), "selection-begin-line", KeyStroke.getKeyStroke("RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl LEFT"), "selection-begin-line", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "caret-begin-line", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "caret-end-line", KeyStroke.getKeyStroke("PASTE"), "paste-from-clipboard", KeyStroke.getKeyStroke("shift ctrl RIGHT"), "selection-end-line", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "unselect", KeyStroke.getKeyStroke("ctrl A"), "select-all", KeyStroke.getKeyStroke("shift KP_RIGHT"), "selection-forward", KeyStroke.getKeyStroke("CUT"), "cut-to-clipboard", KeyStroke.getKeyStroke("ctrl LEFT"), "caret-begin-line", KeyStroke.getKeyStroke("BACK_SPACE"), "delete-previous", KeyStroke.getKeyStroke("shift ctrl KP_LEFT"), "selection-begin-line", KeyStroke.getKeyStroke("ctrl C"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift END"), "selection-end-line", KeyStroke.getKeyStroke("ctrl RIGHT"), "caret-end-line", KeyStroke.getKeyStroke("DELETE"), "delete-next", KeyStroke.getKeyStroke("ENTER"), "notify-field-accept", KeyStroke.getKeyStroke("shift LEFT"), "selection-backward" }), "PasswordField.margin", new InsetsUIResource(0, 0, 0, 0), "PasswordField.selectionBackground", new ColorUIResource(Color.black), "PasswordField.selectionForeground", new ColorUIResource(Color.white), "PopupMenu.background", new ColorUIResource(light), "PopupMenu.border", new BorderUIResource.BevelBorderUIResource(0), "PopupMenu.font", new FontUIResource("Dialog", Font.PLAIN, 12), "PopupMenu.foreground", new ColorUIResource(darkShadow), "ProgressBar.background", new ColorUIResource(Color.LIGHT_GRAY), "ProgressBar.border", new BorderUIResource.LineBorderUIResource(Color.GREEN, 2), "ProgressBar.cellLength", new Integer(1), "ProgressBar.cellSpacing", new Integer(0), "ProgressBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ProgressBar.foreground", new ColorUIResource(0, 0, 128), "ProgressBar.selectionBackground", new ColorUIResource(0, 0, 128), "ProgressBar.selectionForeground", new ColorUIResource(Color.LIGHT_GRAY), "ProgressBar.repaintInterval", new Integer(50), "ProgressBar.cycleTime", new Integer(3000), "RadioButton.background", new ColorUIResource(light), "RadioButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "RadioButton.darkShadow", new ColorUIResource(shadow), "RadioButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("SPACE"), "pressed", KeyStroke.getKeyStroke("released SPACE"), "released" }), "RadioButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButton.foreground", new ColorUIResource(darkShadow), "RadioButton.highlight", new ColorUIResource(highLight), "RadioButton.icon", new UIDefaults.LazyValue() { public Object createValue(UIDefaults def) { return BasicIconFactory.getRadioButtonIcon(); } }, "RadioButton.light", new ColorUIResource(highLight), "RadioButton.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButton.shadow", new ColorUIResource(shadow), "RadioButton.textIconGap", new Integer(4), "RadioButton.textShiftOffset", new Integer(0), "RadioButtonMenuItem.acceleratorFont", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.acceleratorForeground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.acceleratorSelectionForeground", new ColorUIResource(Color.white), "RadioButtonMenuItem.arrowIcon", BasicIconFactory.getMenuItemArrowIcon(), "RadioButtonMenuItem.background", new ColorUIResource(light), "RadioButtonMenuItem.border", new BasicBorders.MarginBorder(), "RadioButtonMenuItem.borderPainted", Boolean.FALSE, "RadioButtonMenuItem.checkIcon", BasicIconFactory.getRadioButtonMenuItemIcon(), "RadioButtonMenuItem.font", new FontUIResource("Dialog", Font.PLAIN, 12), "RadioButtonMenuItem.foreground", new ColorUIResource(darkShadow), "RadioButtonMenuItem.margin", new InsetsUIResource(2, 2, 2, 2), "RadioButtonMenuItem.selectionBackground", new ColorUIResource(Color.black), "RadioButtonMenuItem.selectionForeground", new ColorUIResource(Color.white), "RootPane.defaultButtonWindowKeyBindings", new Object[] { "ENTER", "press", "released ENTER", "release", "ctrl ENTER", "press", "ctrl released ENTER", "release" }, "ScrollBar.background", new ColorUIResource(224, 224, 224), "ScrollBar.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "negativeBlockIncrement", "PAGE_DOWN", "positiveBlockIncrement", "END", "maxScroll", "HOME", "minScroll", "LEFT", "positiveUnitIncrement", "KP_UP", "negativeUnitIncrement", "KP_DOWN", "positiveUnitIncrement", "UP", "negativeUnitIncrement", "RIGHT", "negativeUnitIncrement", "KP_LEFT", "positiveUnitIncrement", "DOWN", "positiveUnitIncrement", "KP_RIGHT", "negativeUnitIncrement" }), "ScrollBar.foreground", new ColorUIResource(light), "ScrollBar.maximumThumbSize", new DimensionUIResource(4096, 4096), "ScrollBar.minimumThumbSize", new DimensionUIResource(8, 8), "ScrollBar.thumb", new ColorUIResource(light), "ScrollBar.thumbDarkShadow", new ColorUIResource(shadow), "ScrollBar.thumbHighlight", new ColorUIResource(highLight), "ScrollBar.thumbShadow", new ColorUIResource(shadow), "ScrollBar.track", new ColorUIResource(light), "ScrollBar.trackHighlight", new ColorUIResource(shadow), "ScrollBar.width", new Integer(16), "ScrollPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "PAGE_UP", "scrollUp", "KP_LEFT", "unitScrollLeft", "ctrl PAGE_DOWN","scrollRight", "PAGE_DOWN", "scrollDown", "KP_RIGHT", "unitScrollRight", "LEFT", "unitScrollLeft", "ctrl END", "scrollEnd", "UP", "unitScrollUp", "RIGHT", "unitScrollRight", "DOWN", "unitScrollDown", "ctrl HOME", "scrollHome", "ctrl PAGE_UP", "scrollLeft", "KP_UP", "unitScrollUp", "KP_DOWN", "unitScrollDown" }), "ScrollPane.background", new ColorUIResource(light), "ScrollPane.border", new BorderUIResource.EtchedBorderUIResource(), "ScrollPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ScrollPane.foreground", new ColorUIResource(darkShadow), "Separator.background", new ColorUIResource(highLight), "Separator.foreground", new ColorUIResource(shadow), "Separator.highlight", new ColorUIResource(highLight), "Separator.shadow", new ColorUIResource(shadow), "Slider.background", new ColorUIResource(light), "Slider.focus", new ColorUIResource(shadow), "Slider.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { "ctrl PAGE_DOWN", "negativeBlockIncrement", "PAGE_DOWN", "negativeBlockIncrement", "PAGE_UP", "positiveBlockIncrement", "ctrl PAGE_UP", "positiveBlockIncrement", "KP_RIGHT", "positiveUnitIncrement", "DOWN", "negativeUnitIncrement", "KP_LEFT", "negativeUnitIncrement", "RIGHT", "positiveUnitIncrement", "KP_DOWN", "negativeUnitIncrement", "UP", "positiveUnitIncrement", "KP_UP", "positiveUnitIncrement", "LEFT", "negativeUnitIncrement", "HOME", "minScroll", "END", "maxScroll" }), "Slider.focusInsets", new InsetsUIResource(2, 2, 2, 2), "Slider.foreground", new ColorUIResource(light), "Slider.highlight", new ColorUIResource(highLight), "Slider.shadow", new ColorUIResource(shadow), "Slider.thumbHeight", new Integer(20), "Slider.thumbWidth", new Integer(11), "Slider.tickHeight", new Integer(12), "Spinner.background", new ColorUIResource(light), "Spinner.foreground", new ColorUIResource(light), "Spinner.arrowButtonSize", new DimensionUIResource(16, 5), "Spinner.editorBorderPainted", Boolean.FALSE, "Spinner.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "SplitPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "F6", "toggleFocus", "F8", "startResize", "END", "selectMax", "HOME", "selectMin", "LEFT", "negativeIncremnent", "KP_UP", "negativeIncrement", "KP_DOWN", "positiveIncrement", "UP", "negativeIncrement", "RIGHT", "positiveIncrement", "KP_LEFT", "negativeIncrement", "DOWN", "positiveIncrement", "KP_RIGHT", "positiveIncrement" }), "SplitPane.background", new ColorUIResource(light), "SplitPane.border", new BasicBorders.SplitPaneBorder(null, null), "SplitPane.darkShadow", new ColorUIResource(shadow), "SplitPane.dividerSize", new Integer(7), "SplitPane.highlight", new ColorUIResource(highLight), "SplitPane.shadow", new ColorUIResource(shadow), "TabbedPane.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ctrl PAGE_DOWN","navigatePageDown", "ctrl PAGE_UP", "navigatePageUp", "ctrl UP", "requestFocus", "ctrl KP_UP", "requestFocus" }), "TabbedPane.background", new ColorUIResource(light), "TabbedPane.contentBorderInsets", new InsetsUIResource(2, 2, 3, 3), "TabbedPane.darkShadow", new ColorUIResource(shadow), "TabbedPane.focus", new ColorUIResource(darkShadow), "TabbedPane.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("ctrl DOWN"), "requestFocusForVisibleComponent", KeyStroke.getKeyStroke("KP_UP"), "navigateUp", KeyStroke.getKeyStroke("LEFT"), "navigateLeft", KeyStroke.getKeyStroke("ctrl KP_DOWN"), "requestFocusForVisibleComponent", KeyStroke.getKeyStroke("UP"), "navigateUp", KeyStroke.getKeyStroke("KP_DOWN"), "navigateDown", KeyStroke.getKeyStroke("KP_LEFT"), "navigateLeft", KeyStroke.getKeyStroke("RIGHT"), "navigateRight", KeyStroke.getKeyStroke("KP_RIGHT"), "navigateRight", KeyStroke.getKeyStroke("DOWN"), "navigateDown" }), "TabbedPane.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TabbedPane.foreground", new ColorUIResource(darkShadow), "TabbedPane.highlight", new ColorUIResource(highLight), "TabbedPane.light", new ColorUIResource(highLight), "TabbedPane.selectedTabPadInsets", new InsetsUIResource(2, 2, 2, 1), "TabbedPane.shadow", new ColorUIResource(shadow), "TabbedPane.tabbedPaneContentBorderInsets", new InsetsUIResource(3, 2, 1, 2), "TabbedPane.tabbedPaneTabPadInsets", new InsetsUIResource(1, 1, 1, 1), "TabbedPane.tabAreaInsets", new InsetsUIResource(3, 2, 0, 2), "TabbedPane.tabInsets", new InsetsUIResource(0, 4, 1, 4), "TabbedPane.tabRunOverlay", new Integer(2), "TabbedPane.textIconGap", new Integer(4), "Table.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ctrl DOWN", "selectNextRowChangeLead", "ctrl RIGHT", "selectNextColumnChangeLead", "ctrl UP", "selectPreviousRowChangeLead", "ctrl LEFT", "selectPreviousColumnChangeLead", "CUT", "cut", "SPACE", "addToSelection", "ctrl SPACE", "toggleAndAnchor", "shift SPACE", "extendTo", "shift ctrl SPACE", "moveSelectionTo", "ctrl X", "cut", "ctrl C", "copy", "ctrl KP_RIGHT", "selectNextColumnChangeLead", "ctrl KP_LEFT", "selectPreviousColumnChangeLead", "ctrl V", "paste", "ctrl KP_DOWN", "selectNextRowChangeLead", "COPY", "copy", "ctrl KP_UP", "selectPreviousRowChangeLead", "PASTE", "paste", "shift PAGE_DOWN","scrollDownExtendSelection", "PAGE_DOWN", "scrollDownChangeSelection", "END", "selectLastColumn", "shift END", "selectLastColumnExtendSelection", "HOME", "selectFirstColumn", "ctrl END", "selectLastRow", "ctrl shift END","selectLastRowExtendSelection", "LEFT", "selectPreviousColumn", "shift HOME", "selectFirstColumnExtendSelection", "UP", "selectPreviousRow", "RIGHT", "selectNextColumn", "ctrl HOME", "selectFirstRow", "shift LEFT", "selectPreviousColumnExtendSelection", "DOWN", "selectNextRow", "ctrl shift HOME","selectFirstRowExtendSelection", "shift UP", "selectPreviousRowExtendSelection", "F2", "startEditing", "shift RIGHT", "selectNextColumnExtendSelection", "TAB", "selectNextColumnCell", "shift DOWN", "selectNextRowExtendSelection", "ENTER", "selectNextRowCell", "KP_UP", "selectPreviousRow", "KP_DOWN", "selectNextRow", "KP_LEFT", "selectPreviousColumn", "KP_RIGHT", "selectNextColumn", "shift TAB", "selectPreviousColumnCell", "ctrl A", "selectAll", "shift ENTER", "selectPreviousRowCell", "shift KP_DOWN", "selectNextRowExtendSelection", "shift KP_LEFT", "selectPreviousColumnExtendSelection", "ESCAPE", "cancel", "ctrl shift PAGE_UP", "scrollLeftExtendSelection", "shift KP_RIGHT", "selectNextColumnExtendSelection", "ctrl PAGE_UP", "scrollLeftChangeSelection", "shift PAGE_UP", "scrollUpExtendSelection", "ctrl shift PAGE_DOWN", "scrollRightExtendSelection", "ctrl PAGE_DOWN", "scrollRightChangeSelection", "PAGE_UP", "scrollUpChangeSelection", "ctrl shift LEFT", "selectPreviousColumnExtendSelection", "shift KP_UP", "selectPreviousRowExtendSelection", "ctrl shift UP", "selectPreviousRowExtendSelection", "ctrl shift RIGHT", "selectNextColumnExtendSelection", "ctrl shift KP_RIGHT", "selectNextColumnExtendSelection", "ctrl shift DOWN", "selectNextRowExtendSelection", "ctrl BACK_SLASH", "clearSelection", "ctrl shift KP_UP", "selectPreviousRowExtendSelection", "ctrl shift KP_LEFT", "selectPreviousColumnExtendSelection", "ctrl SLASH", "selectAll", "ctrl shift KP_DOWN", "selectNextRowExtendSelection", }), "Table.background", new ColorUIResource(new ColorUIResource(255, 255, 255)), "Table.focusCellBackground", new ColorUIResource(new ColorUIResource(255, 255, 255)), "Table.focusCellForeground", new ColorUIResource(new ColorUIResource(0, 0, 0)), "Table.focusCellHighlightBorder", new BorderUIResource.LineBorderUIResource( new ColorUIResource(255, 255, 0)), "Table.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Table.foreground", new ColorUIResource(new ColorUIResource(0, 0, 0)), "Table.gridColor", new ColorUIResource(new ColorUIResource(128, 128, 128)), "Table.scrollPaneBorder", new BorderUIResource.BevelBorderUIResource(0), "Table.selectionBackground", new ColorUIResource(new ColorUIResource(0, 0, 128)), "Table.selectionForeground", new ColorUIResource(new ColorUIResource(255, 255, 255)), "TableHeader.background", new ColorUIResource(new ColorUIResource(192, 192, 192)), "TableHeader.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TableHeader.foreground", new ColorUIResource(new ColorUIResource(0, 0, 0)), "TextArea.background", new ColorUIResource(light), "TextArea.border", new BorderUIResource(BasicBorders.getMarginBorder()), "TextArea.caretBlinkRate", new Integer(500), "TextArea.caretForeground", new ColorUIResource(Color.black), "TextArea.font", new FontUIResource("MonoSpaced", Font.PLAIN, 12), "TextArea.foreground", new ColorUIResource(Color.black), "TextArea.inactiveForeground", new ColorUIResource(Color.gray), "TextArea.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("shift UP"), "selection-up", KeyStroke.getKeyStroke("ctrl RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("shift ctrl LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("shift KP_UP"), "selection-up", KeyStroke.getKeyStroke("DOWN"), "caret-down", KeyStroke.getKeyStroke("shift ctrl T"), "previous-link-action", KeyStroke.getKeyStroke("ctrl LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("CUT"), "cut-to-clipboard", KeyStroke.getKeyStroke("END"), "caret-end-line", KeyStroke.getKeyStroke("shift PAGE_UP"), "selection-page-up", KeyStroke.getKeyStroke("KP_UP"), "caret-up", KeyStroke.getKeyStroke("DELETE"), "delete-next", KeyStroke.getKeyStroke("ctrl HOME"), "caret-begin", KeyStroke.getKeyStroke("shift LEFT"), "selection-backward", KeyStroke.getKeyStroke("ctrl END"), "caret-end", KeyStroke.getKeyStroke("BACK_SPACE"), "delete-previous", KeyStroke.getKeyStroke("shift ctrl RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("LEFT"), "caret-backward", KeyStroke.getKeyStroke("KP_LEFT"), "caret-backward", KeyStroke.getKeyStroke("shift KP_RIGHT"), "selection-forward", KeyStroke.getKeyStroke("ctrl SPACE"), "activate-link-action", KeyStroke.getKeyStroke("ctrl H"), "delete-previous", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "unselect", KeyStroke.getKeyStroke("ENTER"), "insert-break", KeyStroke.getKeyStroke("shift HOME"), "selection-begin-line", KeyStroke.getKeyStroke("RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl PAGE_UP"), "selection-page-left", KeyStroke.getKeyStroke("shift DOWN"), "selection-down", KeyStroke.getKeyStroke("PAGE_DOWN"), "page-down", KeyStroke.getKeyStroke("shift KP_LEFT"), "selection-backward", KeyStroke.getKeyStroke("shift ctrl O"), "toggle-componentOrientation", KeyStroke.getKeyStroke("ctrl X"), "cut-to-clipboard", KeyStroke.getKeyStroke("shift ctrl PAGE_DOWN"), "selection-page-right", KeyStroke.getKeyStroke("ctrl C"), "copy-to-clipboard", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("shift END"), "selection-end-line", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("HOME"), "caret-begin-line", KeyStroke.getKeyStroke("ctrl V"), "paste-from-clipboard", KeyStroke.getKeyStroke("KP_DOWN"), "caret-down", KeyStroke.getKeyStroke("ctrl A"), "select-all", KeyStroke.getKeyStroke("shift RIGHT"), "selection-forward", KeyStroke.getKeyStroke("shift ctrl END"), "selection-end", KeyStroke.getKeyStroke("COPY"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift ctrl KP_LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("ctrl T"), "next-link-action", KeyStroke.getKeyStroke("shift KP_DOWN"), "selection-down", KeyStroke.getKeyStroke("TAB"), "insert-tab", KeyStroke.getKeyStroke("UP"), "caret-up", KeyStroke.getKeyStroke("shift ctrl HOME"), "selection-begin", KeyStroke.getKeyStroke("shift PAGE_DOWN"), "selection-page-down", KeyStroke.getKeyStroke("KP_RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl KP_RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("PAGE_UP"), "page-up", KeyStroke.getKeyStroke("PASTE"), "paste-from-clipboard" }), "TextArea.margin", new InsetsUIResource(0, 0, 0, 0), "TextArea.selectionBackground", new ColorUIResource(Color.black), "TextArea.selectionForeground", new ColorUIResource(Color.white), "TextField.background", new ColorUIResource(light), "TextField.border", new BasicBorders.FieldBorder(null, null, null, null), "TextField.caretBlinkRate", new Integer(500), "TextField.caretForeground", new ColorUIResource(Color.black), "TextField.darkShadow", new ColorUIResource(shadow), "TextField.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "TextField.foreground", new ColorUIResource(Color.black), "TextField.highlight", new ColorUIResource(highLight), "TextField.inactiveBackground", new ColorUIResource(Color.LIGHT_GRAY), "TextField.inactiveForeground", new ColorUIResource(Color.GRAY), "TextField.light", new ColorUIResource(highLight), "TextField.highlight", new ColorUIResource(light), "TextField.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("ENTER"), "notify-field-accept", KeyStroke.getKeyStroke("LEFT"), "caret-backward", KeyStroke.getKeyStroke("RIGHT"), "caret-forward", KeyStroke.getKeyStroke("BACK_SPACE"), "delete-previous", KeyStroke.getKeyStroke("ctrl X"), "cut-to-clipboard", KeyStroke.getKeyStroke("ctrl C"), "copy-to-clipboard", KeyStroke.getKeyStroke("ctrl V"), "paste-from-clipboard", KeyStroke.getKeyStroke("shift LEFT"), "selection-backward", KeyStroke.getKeyStroke("shift RIGHT"), "selection-forward", KeyStroke.getKeyStroke("HOME"), "caret-begin-line", KeyStroke.getKeyStroke("END"), "caret-end-line", KeyStroke.getKeyStroke("DELETE"), "delete-next", KeyStroke.getKeyStroke("shift ctrl O"), "toggle-componentOrientation", KeyStroke.getKeyStroke("shift KP_LEFT"), "selection-backward", KeyStroke.getKeyStroke("ctrl H"), "delete-previous", KeyStroke.getKeyStroke("KP_LEFT"), "caret-backward", KeyStroke.getKeyStroke("KP_RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl KP_RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("COPY"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift HOME"), "selection-begin-line", KeyStroke.getKeyStroke("shift ctrl LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("PASTE"), "paste-from-clipboard", KeyStroke.getKeyStroke("shift ctrl RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "unselect", KeyStroke.getKeyStroke("ctrl A"), "select-all", KeyStroke.getKeyStroke("shift KP_RIGHT"), "selection-forward", KeyStroke.getKeyStroke("CUT"), "cut-to-clipboard", KeyStroke.getKeyStroke("ctrl LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("shift ctrl KP_LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("shift END"), "selection-end-line", KeyStroke.getKeyStroke("ctrl RIGHT"), "caret-next-word" }), "TextField.margin", new InsetsUIResource(0, 0, 0, 0), "TextField.selectionBackground", new ColorUIResource(Color.black), "TextField.selectionForeground", new ColorUIResource(Color.white), "TextPane.background", new ColorUIResource(Color.white), "TextPane.border", BasicBorders.getMarginBorder(), "TextPane.caretBlinkRate", new Integer(500), "TextPane.caretForeground", new ColorUIResource(Color.black), "TextPane.font", new FontUIResource("Serif", Font.PLAIN, 12), "TextPane.foreground", new ColorUIResource(Color.black), "TextPane.inactiveForeground", new ColorUIResource(Color.gray), "TextPane.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("shift UP"), "selection-up", KeyStroke.getKeyStroke("ctrl RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("shift ctrl LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("shift KP_UP"), "selection-up", KeyStroke.getKeyStroke("DOWN"), "caret-down", KeyStroke.getKeyStroke("shift ctrl T"), "previous-link-action", KeyStroke.getKeyStroke("ctrl LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("CUT"), "cut-to-clipboard", KeyStroke.getKeyStroke("END"), "caret-end-line", KeyStroke.getKeyStroke("shift PAGE_UP"), "selection-page-up", KeyStroke.getKeyStroke("KP_UP"), "caret-up", KeyStroke.getKeyStroke("DELETE"), "delete-next", KeyStroke.getKeyStroke("ctrl HOME"), "caret-begin", KeyStroke.getKeyStroke("shift LEFT"), "selection-backward", KeyStroke.getKeyStroke("ctrl END"), "caret-end", KeyStroke.getKeyStroke("BACK_SPACE"), "delete-previous", KeyStroke.getKeyStroke("shift ctrl RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("LEFT"), "caret-backward", KeyStroke.getKeyStroke("KP_LEFT"), "caret-backward", KeyStroke.getKeyStroke("shift KP_RIGHT"), "selection-forward", KeyStroke.getKeyStroke("ctrl SPACE"), "activate-link-action", KeyStroke.getKeyStroke("ctrl H"), "delete-previous", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "unselect", KeyStroke.getKeyStroke("ENTER"), "insert-break", KeyStroke.getKeyStroke("shift HOME"), "selection-begin-line", KeyStroke.getKeyStroke("RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl PAGE_UP"), "selection-page-left", KeyStroke.getKeyStroke("shift DOWN"), "selection-down", KeyStroke.getKeyStroke("PAGE_DOWN"), "page-down", KeyStroke.getKeyStroke("shift KP_LEFT"), "selection-backward", KeyStroke.getKeyStroke("shift ctrl O"), "toggle-componentOrientation", KeyStroke.getKeyStroke("ctrl X"), "cut-to-clipboard", KeyStroke.getKeyStroke("shift ctrl PAGE_DOWN"), "selection-page-right", KeyStroke.getKeyStroke("ctrl C"), "copy-to-clipboard", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "caret-next-word", KeyStroke.getKeyStroke("shift END"), "selection-end-line", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "caret-previous-word", KeyStroke.getKeyStroke("HOME"), "caret-begin-line", KeyStroke.getKeyStroke("ctrl V"), "paste-from-clipboard", KeyStroke.getKeyStroke("KP_DOWN"), "caret-down", KeyStroke.getKeyStroke("ctrl A"), "select-all", KeyStroke.getKeyStroke("shift RIGHT"), "selection-forward", KeyStroke.getKeyStroke("shift ctrl END"), "selection-end", KeyStroke.getKeyStroke("COPY"), "copy-to-clipboard", KeyStroke.getKeyStroke("shift ctrl KP_LEFT"), "selection-previous-word", KeyStroke.getKeyStroke("ctrl T"), "next-link-action", KeyStroke.getKeyStroke("shift KP_DOWN"), "selection-down", KeyStroke.getKeyStroke("TAB"), "insert-tab", KeyStroke.getKeyStroke("UP"), "caret-up", KeyStroke.getKeyStroke("shift ctrl HOME"), "selection-begin", KeyStroke.getKeyStroke("shift PAGE_DOWN"), "selection-page-down", KeyStroke.getKeyStroke("KP_RIGHT"), "caret-forward", KeyStroke.getKeyStroke("shift ctrl KP_RIGHT"), "selection-next-word", KeyStroke.getKeyStroke("PAGE_UP"), "page-up", KeyStroke.getKeyStroke("PASTE"), "paste-from-clipboard" }), "TextPane.margin", new InsetsUIResource(3, 3, 3, 3), "TextPane.selectionBackground", new ColorUIResource(Color.black), "TextPane.selectionForeground", new ColorUIResource(Color.white), "TitledBorder.border", new BorderUIResource.EtchedBorderUIResource(), "TitledBorder.font", new FontUIResource("Dialog", Font.PLAIN, 12), "TitledBorder.titleColor", new ColorUIResource(darkShadow), "ToggleButton.background", new ColorUIResource(light), "ToggleButton.border", new BorderUIResource.CompoundBorderUIResource(null, null), "ToggleButton.darkShadow", new ColorUIResource(shadow), "ToggleButton.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("SPACE"), "pressed", KeyStroke.getKeyStroke("released SPACE"), "released" }), "ToggleButton.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToggleButton.foreground", new ColorUIResource(darkShadow), "ToggleButton.highlight", new ColorUIResource(highLight), "ToggleButton.light", new ColorUIResource(light), "ToggleButton.margin", new InsetsUIResource(2, 14, 2, 14), "ToggleButton.shadow", new ColorUIResource(shadow), "ToggleButton.textIconGap", new Integer(4), "ToggleButton.textShiftOffset", new Integer(0), "ToolBar.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "UP", "navigateUp", "KP_UP", "navigateUp", "DOWN", "navigateDown", "KP_DOWN", "navigateDown", "LEFT", "navigateLeft", "KP_LEFT", "navigateLeft", "RIGHT", "navigateRight", "KP_RIGHT", "navigateRight" }), "ToolBar.background", new ColorUIResource(light), "ToolBar.border", new BorderUIResource.EtchedBorderUIResource(), "ToolBar.darkShadow", new ColorUIResource(shadow), "ToolBar.dockingBackground", new ColorUIResource(light), "ToolBar.dockingForeground", new ColorUIResource(Color.red), "ToolBar.floatingBackground", new ColorUIResource(light), "ToolBar.floatingForeground", new ColorUIResource(Color.darkGray), "ToolBar.font", new FontUIResource("Dialog", Font.PLAIN, 12), "ToolBar.foreground", new ColorUIResource(darkShadow), "ToolBar.highlight", new ColorUIResource(highLight), "ToolBar.light", new ColorUIResource(highLight), "ToolBar.separatorSize", new DimensionUIResource(10, 10), "ToolBar.shadow", new ColorUIResource(shadow), "ToolTip.background", new ColorUIResource(light), "ToolTip.border", new BorderUIResource.LineBorderUIResource(Color.lightGray), "ToolTip.font", new FontUIResource("SansSerif", Font.PLAIN, 12), "ToolTip.foreground", new ColorUIResource(darkShadow), "Tree.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] { "ESCAPE", "cancel" }), "Tree.background", new ColorUIResource(new Color(255, 255, 255)), "Tree.changeSelectionWithFocus", Boolean.TRUE, "Tree.drawsFocusBorderAroundIcon", Boolean.FALSE, "Tree.editorBorder", new BorderUIResource.LineBorderUIResource(Color.lightGray), "Tree.focusInputMap", new UIDefaults.LazyInputMap(new Object[] { KeyStroke.getKeyStroke("ctrl DOWN"), "selectNextChangeLead", KeyStroke.getKeyStroke("shift UP"), "selectPreviousExtendSelection", KeyStroke.getKeyStroke("ctrl RIGHT"), "scrollRight", KeyStroke.getKeyStroke("shift KP_UP"), "selectPreviousExtendSelection", KeyStroke.getKeyStroke("DOWN"), "selectNext", KeyStroke.getKeyStroke("ctrl UP"), "selectPreviousChangeLead", KeyStroke.getKeyStroke("ctrl LEFT"), "scrollLeft", KeyStroke.getKeyStroke("CUT"), "cut", KeyStroke.getKeyStroke("END"), "selectLast", KeyStroke.getKeyStroke("shift PAGE_UP"), "scrollUpExtendSelection", KeyStroke.getKeyStroke("KP_UP"), "selectPrevious", KeyStroke.getKeyStroke("shift ctrl UP"), "selectPreviousExtendSelection", KeyStroke.getKeyStroke("ctrl HOME"), "selectFirstChangeLead", KeyStroke.getKeyStroke("ctrl END"), "selectLastChangeLead", KeyStroke.getKeyStroke("ctrl PAGE_DOWN"), "scrollDownChangeLead", KeyStroke.getKeyStroke("LEFT"), "selectParent", KeyStroke.getKeyStroke("ctrl PAGE_UP"), "scrollUpChangeLead", KeyStroke.getKeyStroke("KP_LEFT"), "selectParent", KeyStroke.getKeyStroke("SPACE"), "addToSelection", KeyStroke.getKeyStroke("ctrl SPACE"), "toggleAndAnchor", KeyStroke.getKeyStroke("shift SPACE"), "extendTo", KeyStroke.getKeyStroke("shift ctrl SPACE"), "moveSelectionTo", KeyStroke.getKeyStroke("ADD"), "expand", KeyStroke.getKeyStroke("ctrl BACK_SLASH"), "clearSelection", KeyStroke.getKeyStroke("shift ctrl DOWN"), "selectNextExtendSelection", KeyStroke.getKeyStroke("shift HOME"), "selectFirstExtendSelection", KeyStroke.getKeyStroke("RIGHT"), "selectChild", KeyStroke.getKeyStroke("shift ctrl PAGE_UP"), "scrollUpExtendSelection", KeyStroke.getKeyStroke("shift DOWN"), "selectNextExtendSelection", KeyStroke.getKeyStroke("PAGE_DOWN"), "scrollDownChangeSelection", KeyStroke.getKeyStroke("shift ctrl KP_UP"), "selectPreviousExtendSelection", KeyStroke.getKeyStroke("SUBTRACT"), "collapse", KeyStroke.getKeyStroke("ctrl X"), "cut", KeyStroke.getKeyStroke("shift ctrl PAGE_DOWN"), "scrollDownExtendSelection", KeyStroke.getKeyStroke("ctrl SLASH"), "selectAll", KeyStroke.getKeyStroke("ctrl C"), "copy", KeyStroke.getKeyStroke("ctrl KP_RIGHT"), "scrollRight", KeyStroke.getKeyStroke("shift END"), "selectLastExtendSelection", KeyStroke.getKeyStroke("shift ctrl KP_DOWN"), "selectNextExtendSelection", KeyStroke.getKeyStroke("ctrl KP_LEFT"), "scrollLeft", KeyStroke.getKeyStroke("HOME"), "selectFirst", KeyStroke.getKeyStroke("ctrl V"), "paste", KeyStroke.getKeyStroke("KP_DOWN"), "selectNext", KeyStroke.getKeyStroke("ctrl A"), "selectAll", KeyStroke.getKeyStroke("ctrl KP_DOWN"), "selectNextChangeLead", KeyStroke.getKeyStroke("shift ctrl END"), "selectLastExtendSelection", KeyStroke.getKeyStroke("COPY"), "copy", KeyStroke.getKeyStroke("ctrl KP_UP"), "selectPreviousChangeLead", KeyStroke.getKeyStroke("shift KP_DOWN"), "selectNextExtendSelection", KeyStroke.getKeyStroke("UP"), "selectPrevious", KeyStroke.getKeyStroke("shift ctrl HOME"), "selectFirstExtendSelection", KeyStroke.getKeyStroke("shift PAGE_DOWN"), "scrollDownExtendSelection", KeyStroke.getKeyStroke("KP_RIGHT"), "selectChild", KeyStroke.getKeyStroke("F2"), "startEditing", KeyStroke.getKeyStroke("PAGE_UP"), "scrollUpChangeSelection", KeyStroke.getKeyStroke("PASTE"), "paste" }), "Tree.font", new FontUIResource("Dialog", Font.PLAIN, 12), "Tree.foreground", new ColorUIResource(Color.black), "Tree.hash", new ColorUIResource(new Color(128, 128, 128)), "Tree.leftChildIndent", new Integer(7), "Tree.rightChildIndent", new Integer(13), "Tree.rowHeight", new Integer(16), "Tree.scrollsOnExpand", Boolean.TRUE, "Tree.selectionBackground", new ColorUIResource(Color.black), "Tree.nonSelectionBackground", new ColorUIResource(new Color(255, 255, 255)), "Tree.selectionBorderColor", new ColorUIResource(Color.black), "Tree.selectionBorder", new BorderUIResource.LineBorderUIResource(Color.black), "Tree.selectionForeground", new ColorUIResource(new Color(255, 255, 255)), "Viewport.background", new ColorUIResource(light), "Viewport.foreground", new ColorUIResource(Color.black), "Viewport.font", new FontUIResource("Dialog", Font.PLAIN, 12) }; defaults.putDefaults(uiDefaults); } |
|
return new DummyIcon(); | return new Icon() { public int getIconHeight() { return 13; } public int getIconWidth() { return 13; } public void paintIcon(Component c, Graphics g, int x, int y) { Color saved = g.getColor(); g.setColor(Color.BLACK); g.drawLine(3 + x, 5 + y, 3 + x, 9 + y); g.drawLine(4 + x, 5 + y, 4 + x, 9 + y); g.drawLine(5 + x, 7 + y, 9 + x, 3 + y); g.drawLine(5 + x, 8 + y, 9 + x, 4 + y); g.setColor(saved); } }; | public static Icon getMenuItemCheckIcon() { return new DummyIcon(); } |
throw new BAD_OPERATION("CORBA object expected"); | BAD_OPERATION bad = new BAD_OPERATION("CORBA object expected"); bad.minor = Minor.Any; throw bad; | public static org.omg.CORBA.Object extract(Any a) { try { return ((ObjectHolder) a.extract_Streamable()).value; } catch (ClassCastException ex) { throw new BAD_OPERATION("CORBA object expected"); } } |
File ses = new File("sessions"); if(ses.exists()) { | private void checkLegacy() { // we check if the sessions file already exists in the directory // if it does exist we are working with an old install so we // need to set the settings directory to the users directory File ses = new File("sessions"); if(ses.exists()) { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.dir") + File.separator); } else { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.home") + File.separator + ".tn5250j" + File.separator); } } |
|
settings.setProperty("emulator.settingsDirectory", System.getProperty("user.dir") + File.separator); } else { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.home") + File.separator + ".tn5250j" + File.separator); | File ses = new File("sessions"); | private void checkLegacy() { // we check if the sessions file already exists in the directory // if it does exist we are working with an old install so we // need to set the settings directory to the users directory File ses = new File("sessions"); if(ses.exists()) { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.dir") + File.separator); } else { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.home") + File.separator + ".tn5250j" + File.separator); } } |
} } | if(ses.exists()) { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.dir") + File.separator); } else { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.home") + File.separator + ".tn5250j" + File.separator); } } | private void checkLegacy() { // we check if the sessions file already exists in the directory // if it does exist we are working with an old install so we // need to set the settings directory to the users directory File ses = new File("sessions"); if(ses.exists()) { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.dir") + File.separator); } else { settings.setProperty("emulator.settingsDirectory", System.getProperty("user.home") + File.separator + ".tn5250j" + File.separator); } } |
getProperties(KEYMAP,KEYMAP,true,"",true); | setProperties(KEYMAP,KEYMAP, "------ Key Map key=keycode,isShiftDown,isControlDown,isAltDown,isAltGrDown --------", true); | private void loadKeyStrokes() {// FileInputStream in = null;// Properties keystrokes = new Properties();//// try {// in = new FileInputStream(settingssDirectory()// + KEYMAP);// keystrokes.load(in);// }// catch (FileNotFoundException fnfe) {System.out.println(fnfe.getMessage());}// catch (IOException ioe) {System.out.println(ioe.getMessage());}// catch (SecurityException se) {// System.out.println(se.getMessage());// }//// if (keystrokes != null) {// registry.put(KEYMAP,keystrokes);// } getProperties(KEYMAP,KEYMAP,true,"",true); } |
getProperties(MACROS,MACROS,true,"",true); | setProperties(MACROS,MACROS,"------ Macros --------",true); | private void loadMacros() {// FileInputStream in = null;// Properties macs = new Properties();//// try {// in = new FileInputStream(settingssDirectory()// + MACROS);// macs.load(in);// }// catch (FileNotFoundException fnfe) {System.out.println(fnfe.getMessage());}// catch (IOException ioe) {System.out.println(ioe.getMessage());}// catch (SecurityException se) {// System.out.println(se.getMessage());// }//// if (macs != null) {// registry.put(MACROS,macs);// } getProperties(MACROS,MACROS,true,"",true); } |
getProperties(SESSIONS,SESSIONS,true,"",true); | setProperties(SESSIONS,SESSIONS,"------ Sessions --------",true); | private void loadSessions() {// FileInputStream in = null;// Properties sessions = new Properties();//// try {// in = new FileInputStream(settingssDirectory() + SESSIONS);// sessions.load(in);//// }// catch (FileNotFoundException fnfe) {// System.out.println(" Information Message: " + fnfe.getMessage()// + ". Default sessions file will"// + " be created for first time use.");// }// catch (IOException ioe) {System.out.println(ioe.getMessage());}//// if (sessions != null) {//// registry.put(SESSIONS,sessions);// } getProperties(SESSIONS,SESSIONS,true,"",true); } |
in = new FileInputStream("tn5250jsettings.cfg"); | in = new FileInputStream(settingsFile); | private void loadSettings() { FileInputStream in = null; settings = new Properties(); try { in = new FileInputStream("tn5250jsettings.cfg"); settings.load(in); } catch (FileNotFoundException fnfe) { System.out.println(" Information Message: " + fnfe.getMessage() + ". The file tn5250jsettings.cfg will" + " be created for first time use."); checkLegacy(); saveSettings(); } catch (IOException ioe) { System.out.println("IO Exception accessing File tn5250jsettings.cfg for the following reason : " + ioe.getMessage()); } catch (SecurityException se) { System.out.println("Security Exception for file tn5250jsettings.cfg. This file can not be " + "accessed because : " + se.getMessage()); } // we now check to see if the settings directory is a directory. If not then we create it File sd = new File(settings.getProperty("emulator.settingsDirectory")); if (!sd.isDirectory()) sd.mkdirs(); } |
System.out.println(" Information Message: " + fnfe.getMessage() + ". The file tn5250jsettings.cfg will" + " be created for first time use."); checkLegacy(); saveSettings(); | System.out.println(" Information Message: " + fnfe.getMessage() + ". The file " + settingsFile + " will" + " be created for first time use."); checkLegacy(); saveSettings(); | private void loadSettings() { FileInputStream in = null; settings = new Properties(); try { in = new FileInputStream("tn5250jsettings.cfg"); settings.load(in); } catch (FileNotFoundException fnfe) { System.out.println(" Information Message: " + fnfe.getMessage() + ". The file tn5250jsettings.cfg will" + " be created for first time use."); checkLegacy(); saveSettings(); } catch (IOException ioe) { System.out.println("IO Exception accessing File tn5250jsettings.cfg for the following reason : " + ioe.getMessage()); } catch (SecurityException se) { System.out.println("Security Exception for file tn5250jsettings.cfg. This file can not be " + "accessed because : " + se.getMessage()); } // we now check to see if the settings directory is a directory. If not then we create it File sd = new File(settings.getProperty("emulator.settingsDirectory")); if (!sd.isDirectory()) sd.mkdirs(); } |
System.out.println("IO Exception accessing File tn5250jsettings.cfg for the following reason : " | System.out.println("IO Exception accessing File " + settingsFile + " for the following reason : " | private void loadSettings() { FileInputStream in = null; settings = new Properties(); try { in = new FileInputStream("tn5250jsettings.cfg"); settings.load(in); } catch (FileNotFoundException fnfe) { System.out.println(" Information Message: " + fnfe.getMessage() + ". The file tn5250jsettings.cfg will" + " be created for first time use."); checkLegacy(); saveSettings(); } catch (IOException ioe) { System.out.println("IO Exception accessing File tn5250jsettings.cfg for the following reason : " + ioe.getMessage()); } catch (SecurityException se) { System.out.println("Security Exception for file tn5250jsettings.cfg. This file can not be " + "accessed because : " + se.getMessage()); } // we now check to see if the settings directory is a directory. If not then we create it File sd = new File(settings.getProperty("emulator.settingsDirectory")); if (!sd.isDirectory()) sd.mkdirs(); } |
System.out.println("Security Exception for file tn5250jsettings.cfg. This file can not be " + "accessed because : " + se.getMessage()); | System.out.println("Security Exception for file " + settingsFile + " This file can not be " + "accessed because : " + se.getMessage()); | private void loadSettings() { FileInputStream in = null; settings = new Properties(); try { in = new FileInputStream("tn5250jsettings.cfg"); settings.load(in); } catch (FileNotFoundException fnfe) { System.out.println(" Information Message: " + fnfe.getMessage() + ". The file tn5250jsettings.cfg will" + " be created for first time use."); checkLegacy(); saveSettings(); } catch (IOException ioe) { System.out.println("IO Exception accessing File tn5250jsettings.cfg for the following reason : " + ioe.getMessage()); } catch (SecurityException se) { System.out.println("Security Exception for file tn5250jsettings.cfg. This file can not be " + "accessed because : " + se.getMessage()); } // we now check to see if the settings directory is a directory. If not then we create it File sd = new File(settings.getProperty("emulator.settingsDirectory")); if (!sd.isDirectory()) sd.mkdirs(); } |
try { FileOutputStream out = new FileOutputStream("tn5250jsettings.cfg"); settings.store(out,"----------------- tn5250j Global Settings --------------"); } catch (FileNotFoundException fnfe) {} catch (IOException ioe) {} | try { FileOutputStream out = new FileOutputStream(settingsFile); settings.store(out,"----------------- tn5250j Global Settings --------------"); } catch (FileNotFoundException fnfe) {} catch (IOException ioe) {} | public void saveSettings() { try { FileOutputStream out = new FileOutputStream("tn5250jsettings.cfg"); settings.store(out,"----------------- tn5250j Global Settings --------------"); } catch (FileNotFoundException fnfe) {} catch (IOException ioe) {} } |
public void drawString(String text, int x, int y) { System.out.println("drawText():" + text); if(this.font != null) ((JNodeToolkit)Toolkit.getDefaultToolkit()).getFontManager().drawText(this,text,font,x,y); | public void drawString(AttributedCharacterIterator iterator, float x, float y) { | public void drawString(String text, int x, int y) { System.out.println("drawText():" + text); if(this.font != null) ((JNodeToolkit)Toolkit.getDefaultToolkit()).getFontManager().drawText(this,text,font,x,y); } |
return (cObject) objects.get(key); | return (cObject) objects.get(key); } | public cObject get(byte[] key) { synchronized (objects) { return (cObject) objects.get(key); } } |
} | public cObject get(byte[] key) { synchronized (objects) { return (cObject) objects.get(key); } } |
|
cObject ref = getKey(object); if (ref != null) objects.remove(ref.key); | cObject ref = getKey(object); if (ref != null) objects.remove(ref.key); } | public void remove(org.omg.CORBA.Object object) { synchronized (objects) { cObject ref = getKey(object); if (ref != null) objects.remove(ref.key); } } |
} | public void remove(org.omg.CORBA.Object object) { synchronized (objects) { cObject ref = getKey(object); if (ref != null) objects.remove(ref.key); } } |
|
public static Constant getInstance(Object value) { return new ReferenceConstant(value); | public static Constant getInstance(int value) { return new IntConstant(value); | public static Constant getInstance(Object value) { return new ReferenceConstant(value); } |
Ext2Debugger.debug("CACHE HIT, size:"+size(),4); | log.debug("CACHE HIT, size:"+size()); | public boolean containsKey(Integer key) { boolean result = super.containsKey(key); if(result) Ext2Debugger.debug("CACHE HIT, size:"+size(),4); else Ext2Debugger.debug("CACHE MISS",4); return result; } |
Ext2Debugger.debug("CACHE MISS",4); | log.debug("CACHE MISS"); | public boolean containsKey(Integer key) { boolean result = super.containsKey(key); if(result) Ext2Debugger.debug("CACHE HIT, size:"+size(),4); else Ext2Debugger.debug("CACHE MISS",4); return result; } |
throws NotImplementedException | public boolean getDragEnabled() throws NotImplementedException { // FIXME: Implement return false; } |
|
return false; | return dragEnabled; | public boolean getDragEnabled() throws NotImplementedException { // FIXME: Implement return false; } |
return "JFileChooser"; | StringBuffer sb = new StringBuffer(super.paramString()); sb.append(",approveButtonText="); if (approveButtonText != null) sb.append(approveButtonText); sb.append(",currentDirectory="); if (currentDir != null) sb.append(currentDir); sb.append(",dialogTitle="); if (dialogTitle != null) sb.append(dialogTitle); sb.append(",dialogType="); if (dialogType == OPEN_DIALOG) sb.append("OPEN_DIALOG"); if (dialogType == SAVE_DIALOG) sb.append("SAVE_DIALOG"); if (dialogType == CUSTOM_DIALOG) sb.append("CUSTOM_DIALOG"); sb.append(",fileSelectionMode="); if (fileSelectionMode == FILES_ONLY) sb.append("FILES_ONLY"); if (fileSelectionMode == DIRECTORIES_ONLY) sb.append("DIRECTORIES_ONLY"); if (fileSelectionMode == FILES_AND_DIRECTORIES) sb.append("FILES_AND_DIRECTORIES"); sb.append(",returnValue="); if (retval == APPROVE_OPTION) sb.append("APPROVE_OPTION"); if (retval == CANCEL_OPTION) sb.append("CANCEL_OPTION"); if (retval == ERROR_OPTION) sb.append("ERROR_OPTION"); sb.append(",selectedFile="); if (selectedFile != null) sb.append(selectedFile); sb.append(",useFileHiding=").append(fileHiding); return sb.toString(); | protected String paramString() { return "JFileChooser"; } |
throws NotImplementedException | public void setDragEnabled(boolean b) throws NotImplementedException { // FIXME: Implement } |
|
if (b && GraphicsEnvironment.isHeadless()) throw new HeadlessException(); dragEnabled = b; | public void setDragEnabled(boolean b) throws NotImplementedException { // FIXME: Implement } |
|
editor.addActionListener(l); | public void addActionListener(ActionListener l) { // FIXME: Need to implement } |
|
editor.removeActionListener(l); | public void removeActionListener(ActionListener l) { // FIXME: Need to implement } |
|
super(CS_sRGB, profile.getNumComponents()); | super(profile.getColorSpaceType(), profile.getNumComponents()); converter = getConverter(profile); | public ICC_ColorSpace(ICC_Profile profile) { super(CS_sRGB, profile.getNumComponents()); thisProfile = profile; } |
nComponents = profile.getNumComponents(); type = profile.getColorSpaceType(); makeArrays(); | public ICC_ColorSpace(ICC_Profile profile) { super(CS_sRGB, profile.getNumComponents()); thisProfile = profile; } |
|
throw new UnsupportedOperationException(); | return converter.fromCIEXYZ(colorvalue); | public float[] fromCIEXYZ(float[] colorvalue) { // FIXME: Not implemented throw new UnsupportedOperationException(); } |
if (rgbvalue.length < 3) throw new IllegalArgumentException (); return rgbvalue; | return converter.fromRGB(rgbvalue); | public float[] fromRGB(float[] rgbvalue) { if (rgbvalue.length < 3) throw new IllegalArgumentException (); // FIXME: Always assumes sRGB: return rgbvalue; } |
if (type == TYPE_XYZ && idx >= 0 && idx <= 2) | if (type == ColorSpace.TYPE_XYZ && idx >= 0 && idx <= 2) | public float getMaxValue(int idx) { if (type == TYPE_XYZ && idx >= 0 && idx <= 2) return 1 + 32767 / 32768f; else if (type == TYPE_Lab) { if (idx == 0) return 100; if (idx == 1 || idx == 2) return 127; } if (idx < 0 || idx >= numComponents) throw new IllegalArgumentException(); return 1; } |
else if (type == TYPE_Lab) | else if (type == ColorSpace.TYPE_Lab) | public float getMaxValue(int idx) { if (type == TYPE_XYZ && idx >= 0 && idx <= 2) return 1 + 32767 / 32768f; else if (type == TYPE_Lab) { if (idx == 0) return 100; if (idx == 1 || idx == 2) return 127; } if (idx < 0 || idx >= numComponents) throw new IllegalArgumentException(); return 1; } |
if (idx < 0 || idx >= numComponents) | if (idx < 0 || idx >= nComponents) | public float getMaxValue(int idx) { if (type == TYPE_XYZ && idx >= 0 && idx <= 2) return 1 + 32767 / 32768f; else if (type == TYPE_Lab) { if (idx == 0) return 100; if (idx == 1 || idx == 2) return 127; } if (idx < 0 || idx >= numComponents) throw new IllegalArgumentException(); return 1; } |
if (type == TYPE_Lab && (idx == 1 || idx == 2)) return -128; if (idx < 0 || idx >= numComponents) | if (type == ColorSpace.TYPE_Lab && (idx == 1 || idx == 2)) return -128f; if (idx < 0 || idx >= nComponents) | public float getMinValue(int idx) { if (type == TYPE_Lab && (idx == 1 || idx == 2)) return -128; if (idx < 0 || idx >= numComponents) throw new IllegalArgumentException(); return 0; } |
throw new UnsupportedOperationException(); | return converter.toCIEXYZ(colorvalue); | public float[] toCIEXYZ(float[] colorvalue) { // FIXME: Not implemented throw new UnsupportedOperationException(); } |
if (colorvalue.length < numComponents) throw new IllegalArgumentException (); return colorvalue; | return converter.toRGB(colorvalue); | public float[] toRGB(float[] colorvalue) { if (colorvalue.length < numComponents) throw new IllegalArgumentException (); // FIXME: Always assumes sRGB: return colorvalue; } |
throw new Error("not implemented"); | return header.getColorSpace(); | public int getColorSpaceType() { throw new Error("not implemented"); } |
switch (profileID) { case ColorSpace.CS_sRGB: case ColorSpace.CS_LINEAR_RGB: case ColorSpace.CS_CIEXYZ: return 3; case ColorSpace.CS_GRAY: return 1; case ColorSpace.CS_PYCC: default: throw new UnsupportedOperationException("profile not implemented"); } | int[] lookup = { ColorSpace.TYPE_RGB, 3, ColorSpace.TYPE_CMY, 3, ColorSpace.TYPE_CMYK, 4, ColorSpace.TYPE_GRAY, 1, ColorSpace.TYPE_YCbCr, 3, ColorSpace.TYPE_XYZ, 3, ColorSpace.TYPE_Lab, 3, ColorSpace.TYPE_HSV, 3, ColorSpace.TYPE_2CLR, 2, ColorSpace.TYPE_Luv, 3, ColorSpace.TYPE_Yxy, 3, ColorSpace.TYPE_HLS, 3, ColorSpace.TYPE_3CLR, 3, ColorSpace.TYPE_4CLR, 4, ColorSpace.TYPE_5CLR, 5, ColorSpace.TYPE_6CLR, 6, ColorSpace.TYPE_7CLR, 7, ColorSpace.TYPE_8CLR, 8, ColorSpace.TYPE_9CLR, 9, ColorSpace.TYPE_ACLR, 10, ColorSpace.TYPE_BCLR, 11, ColorSpace.TYPE_CCLR, 12, ColorSpace.TYPE_DCLR, 13, ColorSpace.TYPE_ECLR, 14, ColorSpace.TYPE_FCLR, 15 }; for (int i = 0; i < lookup.length; i += 2) if (header.getColorSpace() == lookup[i]) return lookup[i + 1]; return 3; | public int getNumComponents() { switch (profileID) { case ColorSpace.CS_sRGB: case ColorSpace.CS_LINEAR_RGB: case ColorSpace.CS_CIEXYZ: return 3; case ColorSpace.CS_GRAY: return 1; case ColorSpace.CS_PYCC: // have no clue about this one default: throw new UnsupportedOperationException("profile not implemented"); } } |
public ArrayIndexOutOfBoundsException(String s) | public ArrayIndexOutOfBoundsException() | public ArrayIndexOutOfBoundsException(String s) { super(s); } |
super(s); | public ArrayIndexOutOfBoundsException(String s) { super(s); } |
|
throws MidiUnavailableException, IllegalArgumentException | throws MidiUnavailableException | public static MidiDevice getMidiDevice(MidiDevice.Info info) throws MidiUnavailableException, IllegalArgumentException { Iterator deviceProviders = ServiceFactory.lookupProviders(MidiDeviceProvider.class); if (! deviceProviders.hasNext()) throw new MidiUnavailableException("No MIDI device providers available."); do { MidiDeviceProvider provider = (MidiDeviceProvider) deviceProviders.next(); if (provider.isDeviceSupported(info)) return provider.getDevice(info); } while (deviceProviders.hasNext()); throw new IllegalArgumentException("MIDI device " + info + " not available."); } |
throw new InvalidMidiDataException("Cannot read MidiFileFormat from stream"); | throw new InvalidMidiDataException("Can't read MidiFileFormat from stream"); | public static MidiFileFormat getMidiFileFormat(InputStream stream) throws InvalidMidiDataException, IOException { Iterator readers = ServiceFactory.lookupProviders(MidiFileReader.class); while (readers.hasNext()) { MidiFileReader sr = (MidiFileReader) readers.next(); MidiFileFormat sb = sr.getMidiFileFormat(stream); if (sb != null) return sb; } throw new InvalidMidiDataException("Cannot read MidiFileFormat from stream"); } |
throws IOException, IllegalArgumentException | throws IOException | public static int write(Sequence in, int fileType, OutputStream out) throws IOException, IllegalArgumentException { Iterator writers = ServiceFactory.lookupProviders(MidiFileWriter.class); while (writers.hasNext()) { MidiFileWriter fw = (MidiFileWriter) writers.next(); if (fw.isFileTypeSupported(fileType, in)) return fw.write(in, fileType, out); } throw new IllegalArgumentException("File type " + fileType + " is not supported"); } |
this.impl = new VMPlainSocketImpl(); | public PlainSocketImpl() { } |
|
protected NIOSocket (PlainSocketImpl impl, SocketChannelImpl channel) | protected NIOSocket (SocketChannelImpl channel) | protected NIOSocket (PlainSocketImpl impl, SocketChannelImpl channel) throws IOException { super (impl); this.impl = impl; this.channel = channel; } |
super (impl); this.impl = impl; | super (new NIOSocketImpl(channel)); | protected NIOSocket (PlainSocketImpl impl, SocketChannelImpl channel) throws IOException { super (impl); this.impl = impl; this.channel = channel; } |
if (event.isPopupTrigger ()) | if (SwingUtilities.isRightMouseButton(event)) | private void jbInit() throws Exception { this.setTitle(LangTool.getString("spool.title")); this.setIconImage(My5250.tnicon.getImage()); this.getContentPane().add(createFilterPanel(), BorderLayout.NORTH); // get an instance of our table model stm = new SpoolTableModel(); // create a table using our custom table model spools = new JSortTable(stm); TableColumn column = null; for (int x = 0;x < stm.getColumnCount(); x++) { column = spools.getColumnModel().getColumn(x); column.setPreferredWidth(stm.getColumnPreferredSize(x)); } spools.setAutoResizeMode(JTable.AUTO_RESIZE_OFF); // create our mouse listener on the table spools.addMouseListener(new java.awt.event.MouseAdapter() { public void mouseClicked(MouseEvent e) { spools_mouseClicked(e); } public void mousePressed (MouseEvent event) { if (event.isPopupTrigger ()) showPopupMenu(event); } public void mouseReleased (MouseEvent event) { if (event.isPopupTrigger ()) showPopupMenu(event); } }); spools.setShowGrid(false); //Create the scroll pane and add the table to it. scrollPane = new JScrollPane(spools); scrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED); scrollPane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED); // setup the number of rows we should be working with spools.setPreferredScrollableViewportSize( new Dimension( spools.getPreferredScrollableViewportSize().width, spools.getFontMetrics(spools.getFont()).getHeight() * 8) ); scrollPane.getViewport().setBackground(spools.getBackground()); scrollPane.setBackground(spools.getBackground()); //Setup our selection model listener rowSM = spools.getSelectionModel(); rowSM.addListSelectionListener(new ListSelectionListener() { public void valueChanged(ListSelectionEvent e) { //Ignore extra messages. if (e.getValueIsAdjusting()) return; ListSelectionModel lsm = (ListSelectionModel)e.getSource(); } }); rowSM.setSelectionMode(rowSM.SINGLE_SELECTION); this.getContentPane().add(scrollPane, BorderLayout.CENTER); status = new JLabel("0 " + LangTool.getString("spool.count")); status.setBorder(BorderFactory.createEtchedBorder()); this.getContentPane().add(status, BorderLayout.SOUTH); pack(); //Center the window Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); Dimension frameSize = getSize(); if (frameSize.height > screenSize.height) frameSize.height = screenSize.height; if (frameSize.width > screenSize.width) frameSize.width = screenSize.width; setLocation((screenSize.width - frameSize.width) / 2, (screenSize.height - frameSize.height) / 2); addWindowListener(new WindowAdapter() { public void windowClosing(WindowEvent event) { // close the spool file list// if (splfList != null)// splfList.close(); // close the system connection if (system != null) system.disconnectAllServices(); setVisible(false); dispose(); } }); } |
if (event.isPopupTrigger ()) | if (SwingUtilities.isRightMouseButton(event)) | public void mousePressed (MouseEvent event) { if (event.isPopupTrigger ()) showPopupMenu(event); } |
if (event.isPopupTrigger ()) | if (SwingUtilities.isRightMouseButton(event)) | public void mouseReleased (MouseEvent event) { if (event.isPopupTrigger ()) showPopupMenu(event); } |
CurrentArray = CurrentStructure.addArray(newarray); | if (newarray != null) { String arrayId = newarray.getArrayId(); if ( arrayId != null) ArrayObj.put(arrayId, newarray); } | public Object action (SaxDocumentHandler handler, AttributeList attrs) { // create new object appropriately Array newarray = new Array(); newarray.setXMLAttributes(attrs); // set XML attributes from passed list // set current array and add this array to current structure CurrentArray = CurrentStructure.addArray(newarray); setCurrentDatatypeObject(CurrentArray); return newarray; } |
CurrentArray = newarray; | public Object action (SaxDocumentHandler handler, AttributeList attrs) { // create new object appropriately Array newarray = new Array(); newarray.setXMLAttributes(attrs); // set XML attributes from passed list // set current array and add this array to current structure CurrentArray = CurrentStructure.addArray(newarray); setCurrentDatatypeObject(CurrentArray); return newarray; } |
|
addDataToCurrentArray(TaggedLocatorObj, thisString, CurrentDataFormat); | addDataToCurrentArray(TaggedLocatorObj, thisString, CurrentDataFormat, IntRadix[CurrentDataFormatIndex]); | public void action (SaxDocumentHandler handler, char buf [], int offset, int len) { XMLDataIOStyle readObj = CurrentArray.getXMLDataIOStyle(); String thisString = new String(buf,offset,len); if ( readObj instanceof TaggedXMLDataIOStyle ) { // dont add this data unless it has more than just whitespace if (!IgnoreWhitespaceOnlyData || stringIsNotAllWhitespace(thisString) ) { Log.debugln("ADDING TAGGED DATA to ("+TaggedLocatorObj+") : ["+thisString+"]"); DataTagLevel = CurrentDataTagLevel; DataFormat CurrentDataFormat = DataFormatList[CurrentDataFormatIndex]; // adding data based on what type.. addDataToCurrentArray(TaggedLocatorObj, thisString, CurrentDataFormat); } } else if ( readObj instanceof DelimitedXMLDataIOStyle || readObj instanceof FormattedXMLDataIOStyle ) { // add it to the datablock if it isnt all whitespace ?? if (!IgnoreWhitespaceOnlyData || stringIsNotAllWhitespace(thisString) ) DATABLOCK.append(thisString); } else { Log.errorln("UNSUPPORTED Data Node CharData style:"+readObj.toString()+", Aborting!\n"); System.exit(-1); } } |
addDataToCurrentArray(myLocator, thisData, CurrentDataFormat); | addDataToCurrentArray(myLocator, thisData, CurrentDataFormat, IntRadix[CurrentDataFormatIndex]); | public void action (SaxDocumentHandler handler) { // we stopped reading datanode, lower count by one DataNodeLevel--; // we might still be nested within a data node // if so, return now to accumulate more data within the DATABLOCK if(DataNodeLevel != 0) return; // now we are ready to read in untagged data (both delimited/formmatted styles) // from the DATABLOCK // Note: unfortunately we are reduced to using regex style matching // instead of a buffer read in formatted reads. Come back and // improve this later if possible. XMLDataIOStyle formatObj = CurrentArray.getXMLDataIOStyle(); if ( formatObj instanceof DelimitedXMLDataIOStyle || formatObj instanceof FormattedXMLDataIOStyle ) { // determine the size of the dataFormat (s) in our dataCube if (CurrentArray.hasFieldAxis()) { // if there is a field axis, then its set to the number of fields FieldAxis fieldAxis = CurrentArray.getFieldAxis(); MaxDataFormatIndex = (fieldAxis.getLength()-1); } else { // its homogeneous MaxDataFormatIndex = 0; } Locator myLocator = CurrentArray.createLocator(); myLocator.setIterationOrder(AxisReadOrder); // CurrentIOCmdIndex = 0; CurrentDataFormatIndex = 0; ArrayList strValueList;// boolean dataHasSpecialIntegers = false; // set up appropriate instructions for reading if ( formatObj instanceof FormattedXMLDataIOStyle ) {/* $template = $formatObj->_templateNotation(1); $recordSize = $formatObj->bytes(); $data_has_special_integers = $formatObj->hasSpecialIntegers;*/ // snag the string representation of the values strValueList = formattedSplitStringIntoStringObjects( DATABLOCK.toString(), ((FormattedXMLDataIOStyle) formatObj) ); if (strValueList.size() == 0) { Log.errorln("Error: XDF Reader is unable to acquire formatted data, bad format?"); System.exit(-1); } } else { // snag the string representation of the values strValueList = splitStringIntoStringObjects( DATABLOCK.toString(), ((DelimitedXMLDataIOStyle) formatObj).getDelimiter(), ((DelimitedXMLDataIOStyle) formatObj).getRepeatable(), ((DelimitedXMLDataIOStyle) formatObj).getRecordTerminator() ); } // fire data into dataCube Iterator iter = strValueList.iterator(); while (iter.hasNext()) { DataFormat CurrentDataFormat = DataFormatList[CurrentDataFormatIndex]; // adding data based on what type.. String thisData = (String) iter.next(); addDataToCurrentArray(myLocator, thisData, CurrentDataFormat); // bump up DataFormat appropriately if (MaxDataFormatIndex > 0) { int currentFastAxisCoordinate = myLocator.getAxisLocation(FastestAxis); if ( currentFastAxisCoordinate != LastFastAxisCoordinate ) { LastFastAxisCoordinate = currentFastAxisCoordinate; if (CurrentDataFormatIndex == MaxDataFormatIndex) CurrentDataFormatIndex = 0; else CurrentDataFormatIndex++; } } myLocator.next(); } } else if ( formatObj instanceof TaggedXMLDataIOStyle ) { // Tagged case: do nothing } else { Log.errorln("ERROR: Completely unknown DATA IO style:"+formatObj.toString() +" aborting read!"); System.exit(-1); } } |
int currentFastAxisCoordinate = myLocator.getAxisLocation(FastestAxis); | int currentFastAxisCoordinate = myLocator.getAxisIndex(FastestAxis); | public void action (SaxDocumentHandler handler) { // we stopped reading datanode, lower count by one DataNodeLevel--; // we might still be nested within a data node // if so, return now to accumulate more data within the DATABLOCK if(DataNodeLevel != 0) return; // now we are ready to read in untagged data (both delimited/formmatted styles) // from the DATABLOCK // Note: unfortunately we are reduced to using regex style matching // instead of a buffer read in formatted reads. Come back and // improve this later if possible. XMLDataIOStyle formatObj = CurrentArray.getXMLDataIOStyle(); if ( formatObj instanceof DelimitedXMLDataIOStyle || formatObj instanceof FormattedXMLDataIOStyle ) { // determine the size of the dataFormat (s) in our dataCube if (CurrentArray.hasFieldAxis()) { // if there is a field axis, then its set to the number of fields FieldAxis fieldAxis = CurrentArray.getFieldAxis(); MaxDataFormatIndex = (fieldAxis.getLength()-1); } else { // its homogeneous MaxDataFormatIndex = 0; } Locator myLocator = CurrentArray.createLocator(); myLocator.setIterationOrder(AxisReadOrder); // CurrentIOCmdIndex = 0; CurrentDataFormatIndex = 0; ArrayList strValueList;// boolean dataHasSpecialIntegers = false; // set up appropriate instructions for reading if ( formatObj instanceof FormattedXMLDataIOStyle ) {/* $template = $formatObj->_templateNotation(1); $recordSize = $formatObj->bytes(); $data_has_special_integers = $formatObj->hasSpecialIntegers;*/ // snag the string representation of the values strValueList = formattedSplitStringIntoStringObjects( DATABLOCK.toString(), ((FormattedXMLDataIOStyle) formatObj) ); if (strValueList.size() == 0) { Log.errorln("Error: XDF Reader is unable to acquire formatted data, bad format?"); System.exit(-1); } } else { // snag the string representation of the values strValueList = splitStringIntoStringObjects( DATABLOCK.toString(), ((DelimitedXMLDataIOStyle) formatObj).getDelimiter(), ((DelimitedXMLDataIOStyle) formatObj).getRepeatable(), ((DelimitedXMLDataIOStyle) formatObj).getRecordTerminator() ); } // fire data into dataCube Iterator iter = strValueList.iterator(); while (iter.hasNext()) { DataFormat CurrentDataFormat = DataFormatList[CurrentDataFormatIndex]; // adding data based on what type.. String thisData = (String) iter.next(); addDataToCurrentArray(myLocator, thisData, CurrentDataFormat); // bump up DataFormat appropriately if (MaxDataFormatIndex > 0) { int currentFastAxisCoordinate = myLocator.getAxisLocation(FastestAxis); if ( currentFastAxisCoordinate != LastFastAxisCoordinate ) { LastFastAxisCoordinate = currentFastAxisCoordinate; if (CurrentDataFormatIndex == MaxDataFormatIndex) CurrentDataFormatIndex = 0; else CurrentDataFormatIndex++; } } myLocator.next(); } } else if ( formatObj instanceof TaggedXMLDataIOStyle ) { // Tagged case: do nothing } else { Log.errorln("ERROR: Completely unknown DATA IO style:"+formatObj.toString() +" aborting read!"); System.exit(-1); } } |
NrofDataFormats = DataFormatList.length; IntRadix = new int [NrofDataFormats]; for (int i=0; i < NrofDataFormats; i++) { if (DataFormatList[i] instanceof IntegerDataFormat) { String type = ((IntegerDataFormat) DataFormatList[i]).getType(); if (type.equals(Constants.INTEGER_TYPE_DECIMAL)) IntRadix[i] = 10; else if (type.equals(Constants.INTEGER_TYPE_HEX)) IntRadix[i] = 16; else if (type.equals(Constants.INTEGER_TYPE_OCTAL)) IntRadix[i] = 8; else IntRadix[i] = 10; } else if (DataFormatList[i] instanceof BinaryIntegerDataFormat) { IntRadix[i] = 10; } } | public Object action (SaxDocumentHandler handler, AttributeList attrs) { // we only need to do these things for the first time we enter // a data node if (DataNodeLevel == 0) { // A little 'pre-handling' as href is a specialattribute // that will hold an (Href) object rather than string value Href hrefObj = null; String hrefValue = getAttributeListValueByName(attrs,"href"); if (hrefValue != null ) { // now we look up the href from the entity list gathered by // the parser and transfer relevant info to our Href object hrefObj = new Href(); Hashtable hrefInfo = (Hashtable) UnParsedEntity.get(hrefValue); if (UnParsedEntity.containsKey(hrefValue)) { hrefObj.setName((String) hrefInfo.get("name")); if (hrefInfo.containsKey("base")) hrefObj.setBase((String) hrefInfo.get("base")); if (hrefInfo.containsKey("sysId")) hrefObj.setSysId((String) hrefInfo.get("sysId")); if (hrefInfo.containsKey("pubId")) hrefObj.setPubId((String) hrefInfo.get("pubId")); if (hrefInfo.containsKey("ndata")) hrefObj.setNdata((String) hrefInfo.get("ndata")); } else { // bizarre. It usually means that the unparsed entity handler // isnt working like it should Log.error("Error: UnParsedEntity list lacks entry for :"+hrefValue); Log.errorln(" ignoring request to read data."); } } // update the array dataCube with passed attributes CurrentArray.getDataCube().setXMLAttributes(attrs); // Clean up. We override the string value of Href and set it as // the Href object , if we created it (yeh, sloppy). if (hrefObj != null) CurrentArray.getDataCube().setHref(hrefObj); // determine the size of the dataFormat (s) in our dataCube if (CurrentArray.hasFieldAxis()) { // if there is a field axis, then its set to the number of fields FieldAxis fieldAxis = CurrentArray.getFieldAxis(); MaxDataFormatIndex = (fieldAxis.getLength()-1); } else { // its homogeneous MaxDataFormatIndex = 0; } // reset to start of which dataformat type we currently are reading CurrentDataFormatIndex = 0; // reset to start of which IOCmd we currently are reading CurrentIOCmdIndex = 0; // reset the list of dataformats we are reading DataFormatList = CurrentArray.getDataFormatList(); } XMLDataIOStyle readObj = CurrentArray.getXMLDataIOStyle(); FastestAxis = (AxisInterface) CurrentArray.getAxisList().get(0); LastFastAxisCoordinate = -1; if ( readObj instanceof TaggedXMLDataIOStyle) { TaggedLocatorObj = CurrentArray.createLocator(); } else { // A safety. We clear datablock when this is the first datanode we // have entered DATABLOCK is used in cases where we read in untagged data if (DataNodeLevel == 0) DATABLOCK = new StringBuffer (); } // tack in href data if (CurrentArray.getDataCube().getHref() != null) DATABLOCK.append(getHrefData(CurrentArray.getDataCube().getHref())); //loadHrefDataIntoCurrentArray(); // entered a datanode, raise the count // this (partially helps) declare we are now reading data, DataNodeLevel++; return readObj; } |
|
int currentFastAxisCoordinate = TaggedLocatorObj.getAxisLocation(FastestAxis); | int currentFastAxisCoordinate = TaggedLocatorObj.getAxisIndex(FastestAxis); | public void action (SaxDocumentHandler handler) { if (CurrentDataTagLevel == DataTagLevel) TaggedLocatorObj.next(); // bump up DataFormat appropriately if (MaxDataFormatIndex > 0) { int currentFastAxisCoordinate = TaggedLocatorObj.getAxisLocation(FastestAxis); if ( currentFastAxisCoordinate != LastFastAxisCoordinate ) { LastFastAxisCoordinate = currentFastAxisCoordinate; if (CurrentDataFormatIndex == MaxDataFormatIndex) CurrentDataFormatIndex = 0; else CurrentDataFormatIndex++; } } CurrentDataTagLevel--; } |
private void addByteDataToCurrentArray (byte[] data, int amount, String endian, int nrofDataFormat) { | private void addByteDataToCurrentArray (byte[] data, int amount, String endian) { | private void addByteDataToCurrentArray (byte[] data, int amount, String endian, int nrofDataFormat) { ArrayList commandList = (ArrayList) ((FormattedXMLDataIOStyle) CurrentArray.getXMLDataIOStyle()).getCommands(); int nrofIOCmd = commandList.size(); int bytes_added = 0;Log.errorln("Adding "+amount+" bytes of data to current array"); while (bytes_added < amount) { FormattedIOCmd currentIOCmd = (FormattedIOCmd) commandList.get(CurrentIOCmdIndex); // readCell if (currentIOCmd instanceof ReadCellFormattedIOCmd) { DataFormat currentDataFormat = DataFormatList[CurrentDataFormatIndex]; int bytes_to_add = currentDataFormat.numOfBytes();Log.errorln("Adding "+bytes_to_add+" bytes of data to current array");//Object objectToAdd = null; if ( currentDataFormat instanceof IntegerDataFormat) { } else if (currentDataFormat instanceof FloatDataFormat) {Log.errorln("Got Href Data Float:["+new String(data,bytes_added,bytes_added+bytes_to_add)+ "]["+bytes_added+"]["+bytes_to_add+"]"); } else if (currentDataFormat instanceof BinaryFloatDataFormat) { if (bytes_to_add == 4) { Float myValue = convert4bytesToFloat(endian, data, bytes_added);Log.errorln("Got Href Data BFloatSingle:["+myValue.toString()+"]["+bytes_added+"]["+bytes_to_add+"]"); } else if (bytes_to_add == 8) { Double myValue = convert8bytesToDouble(endian, data, bytes_added);Log.errorln("Got Href Data BFloatDouble:["+myValue.toString()+"]["+bytes_added+"]["+bytes_to_add+"]"); } else { Log.errorln("Error: got floating point with bit size != (32|64). Ignoring data."); } } else if (currentDataFormat instanceof BinaryIntegerDataFormat) { Integer myValue = convert2bytesToInteger (endian, data, bytes_added);Log.errorln("Got Href Data Integer:["+myValue.toString()+ "]["+bytes_added+"]["+bytes_to_add+"]"); } else if (currentDataFormat instanceof StringDataFormat) {// char[] charList = bytesTo8BitChars(data,bytes_added,bytes_added+bytes_to_add);Log.errorln("String byte range is :"+bytes_added+" to "+(bytes_added+bytes_to_add));Log.errorln("Got Href Data String:["+new String(data,bytes_added,(bytes_added+bytes_to_add))+ "]["+bytes_added+"]["+bytes_to_add+"]"); } // advance our global pointer to the current DataFormat if (nrofDataFormat > 1) if (CurrentDataFormatIndex == (nrofDataFormat - 1)) CurrentDataFormatIndex = 0; else CurrentDataFormatIndex++; bytes_added += bytes_to_add; } else if (currentIOCmd instanceof SkipCharFormattedIOCmd) { Integer bytes_to_skip = ((SkipCharFormattedIOCmd) currentIOCmd).getCount(); bytes_added += bytes_to_skip.intValue(); } else if (currentIOCmd instanceof RepeatFormattedIOCmd) { // shouldnt happen Log.errorln("Argh getCommands not working right, got repeat command in addByteData!!!"); System.exit(-1); } // advance our global pointer to the current IOCmd if (nrofIOCmd> 1) if (CurrentIOCmdIndex == (nrofIOCmd - 1)) CurrentIOCmdIndex = 0; else CurrentIOCmdIndex++; } } |
if (nrofDataFormat > 1) if (CurrentDataFormatIndex == (nrofDataFormat - 1)) | if (NrofDataFormats > 1) if (CurrentDataFormatIndex == (NrofDataFormats - 1)) | private void addByteDataToCurrentArray (byte[] data, int amount, String endian, int nrofDataFormat) { ArrayList commandList = (ArrayList) ((FormattedXMLDataIOStyle) CurrentArray.getXMLDataIOStyle()).getCommands(); int nrofIOCmd = commandList.size(); int bytes_added = 0;Log.errorln("Adding "+amount+" bytes of data to current array"); while (bytes_added < amount) { FormattedIOCmd currentIOCmd = (FormattedIOCmd) commandList.get(CurrentIOCmdIndex); // readCell if (currentIOCmd instanceof ReadCellFormattedIOCmd) { DataFormat currentDataFormat = DataFormatList[CurrentDataFormatIndex]; int bytes_to_add = currentDataFormat.numOfBytes();Log.errorln("Adding "+bytes_to_add+" bytes of data to current array");//Object objectToAdd = null; if ( currentDataFormat instanceof IntegerDataFormat) { } else if (currentDataFormat instanceof FloatDataFormat) {Log.errorln("Got Href Data Float:["+new String(data,bytes_added,bytes_added+bytes_to_add)+ "]["+bytes_added+"]["+bytes_to_add+"]"); } else if (currentDataFormat instanceof BinaryFloatDataFormat) { if (bytes_to_add == 4) { Float myValue = convert4bytesToFloat(endian, data, bytes_added);Log.errorln("Got Href Data BFloatSingle:["+myValue.toString()+"]["+bytes_added+"]["+bytes_to_add+"]"); } else if (bytes_to_add == 8) { Double myValue = convert8bytesToDouble(endian, data, bytes_added);Log.errorln("Got Href Data BFloatDouble:["+myValue.toString()+"]["+bytes_added+"]["+bytes_to_add+"]"); } else { Log.errorln("Error: got floating point with bit size != (32|64). Ignoring data."); } } else if (currentDataFormat instanceof BinaryIntegerDataFormat) { Integer myValue = convert2bytesToInteger (endian, data, bytes_added);Log.errorln("Got Href Data Integer:["+myValue.toString()+ "]["+bytes_added+"]["+bytes_to_add+"]"); } else if (currentDataFormat instanceof StringDataFormat) {// char[] charList = bytesTo8BitChars(data,bytes_added,bytes_added+bytes_to_add);Log.errorln("String byte range is :"+bytes_added+" to "+(bytes_added+bytes_to_add));Log.errorln("Got Href Data String:["+new String(data,bytes_added,(bytes_added+bytes_to_add))+ "]["+bytes_added+"]["+bytes_to_add+"]"); } // advance our global pointer to the current DataFormat if (nrofDataFormat > 1) if (CurrentDataFormatIndex == (nrofDataFormat - 1)) CurrentDataFormatIndex = 0; else CurrentDataFormatIndex++; bytes_added += bytes_to_add; } else if (currentIOCmd instanceof SkipCharFormattedIOCmd) { Integer bytes_to_skip = ((SkipCharFormattedIOCmd) currentIOCmd).getCount(); bytes_added += bytes_to_skip.intValue(); } else if (currentIOCmd instanceof RepeatFormattedIOCmd) { // shouldnt happen Log.errorln("Argh getCommands not working right, got repeat command in addByteData!!!"); System.exit(-1); } // advance our global pointer to the current IOCmd if (nrofIOCmd> 1) if (CurrentIOCmdIndex == (nrofIOCmd - 1)) CurrentIOCmdIndex = 0; else CurrentIOCmdIndex++; } } |
DataFormat CurrentDataFormat | DataFormat CurrentDataFormat, int intRadix | private void addDataToCurrentArray ( Locator dataLocator, String thisString, DataFormat CurrentDataFormat ) {// Log.error("addDatatoArray:["+thisString+"]"); // Note that we dont treat binary data at all here try { if ( CurrentDataFormat instanceof StringDataFormat) {// Log.errorln(" StringDataFormat"); CurrentArray.setData(dataLocator, thisString); } else if ( CurrentDataFormat instanceof FloatDataFormat || CurrentDataFormat instanceof BinaryFloatDataFormat) {// Log.errorln(" FloatDataFormat"); Double number = new Double (thisString); CurrentArray.setData(dataLocator, number.doubleValue()); } else if ( CurrentDataFormat instanceof IntegerDataFormat || CurrentDataFormat instanceof BinaryIntegerDataFormat) {// Log.errorln(" IntegerDataFormat"); Integer number = new Integer (thisString); CurrentArray.setData(dataLocator, number.intValue()); } else { Log.warnln("Unknown data format, unable to setData:["+thisString+"], ignoring request"); } } catch (SetDataException e) { // bizarre error. Cant add data (out of memory??) :P Log.errorln("Unable to setData:["+thisString+"], ignoring request"); Log.printStackTrace(e); } } |
Integer number = new Integer (thisString); CurrentArray.setData(dataLocator, number.intValue()); | if (intRadix == 16) thisString = thisString.substring(2); int thisInt = Integer.parseInt(thisString, intRadix); CurrentArray.setData(dataLocator, thisInt); | private void addDataToCurrentArray ( Locator dataLocator, String thisString, DataFormat CurrentDataFormat ) {// Log.error("addDatatoArray:["+thisString+"]"); // Note that we dont treat binary data at all here try { if ( CurrentDataFormat instanceof StringDataFormat) {// Log.errorln(" StringDataFormat"); CurrentArray.setData(dataLocator, thisString); } else if ( CurrentDataFormat instanceof FloatDataFormat || CurrentDataFormat instanceof BinaryFloatDataFormat) {// Log.errorln(" FloatDataFormat"); Double number = new Double (thisString); CurrentArray.setData(dataLocator, number.doubleValue()); } else if ( CurrentDataFormat instanceof IntegerDataFormat || CurrentDataFormat instanceof BinaryIntegerDataFormat) {// Log.errorln(" IntegerDataFormat"); Integer number = new Integer (thisString); CurrentArray.setData(dataLocator, number.intValue()); } else { Log.warnln("Unknown data format, unable to setData:["+thisString+"], ignoring request"); } } catch (SetDataException e) { // bizarre error. Cant add data (out of memory??) :P Log.errorln("Unable to setData:["+thisString+"], ignoring request"); Log.printStackTrace(e); } } |
if(endianStyle.equals("BigEndian")) | if(endianStyle.equals(Constants.BIG_ENDIAN)) | private Integer convert2bytesToInteger (String endianStyle, byte[] bb, int sbyte) { int i; if(endianStyle.equals("BigEndian")) i = (bb[sbyte]&0xFF) << 8 | (bb[sbyte+1]&0xFF); else i = (bb[sbyte+1]&0xFF) << 8 | (bb[sbyte]&0xFF); return new Integer(i); } |
if(endianStyle.equals("BigEndian")) | if(endianStyle.equals(Constants.BIG_ENDIAN)) | private Float convert4bytesToFloat (String endianStyle, byte[] bb, int sbyte) { int i; if(endianStyle.equals("BigEndian")) i = (bb[sbyte]&0xFF) << 24 | (bb[sbyte+1]&0xFF) << 16 | (bb[sbyte+2]&0xFF) << 8 | (bb[sbyte+3]&0xFF); else i = (bb[sbyte+3]&0xFF) << 24 | (bb[sbyte+2]&0xFF) << 16 | (bb[sbyte+1]&0xFF) << 8 | (bb[sbyte]&0xFF);/*Log.error("Float bits are: ");for (int j=sbyte; j<sbyte+4; j++) { for(int k=7; k >=0; k--) { int newvalue = (bb[j] >> k)&0x01; Log.error(""+newvalue); } Log.error(" ");}Log.errorln("");*/ return new Float(Float.intBitsToFloat(i)); } |
if(endianStyle.equals("BigEndian")) | if(endianStyle.equals(Constants.BIG_ENDIAN)) | private Integer convert4bytesToInteger (String endianStyle, byte[] bb, int sbyte) { int i; if(endianStyle.equals("BigEndian")) i = (bb[sbyte]&0xFF) << 24 | (bb[sbyte+1]&0xFF) << 16 | (bb[sbyte+2]&0xFF) << 8 | (bb[sbyte+3]&0xFF); else i = (bb[sbyte+3]&0xFF) << 24 | (bb[sbyte+2]&0xFF) << 16 | (bb[sbyte+1]&0xFF) << 8 | (bb[sbyte]&0xFF); return new Integer(i); } |
if(endianStyle.equals("BigEndian")) | if(endianStyle.equals(Constants.BIG_ENDIAN)) | private Double convert8bytesToDouble (String endianStyle, byte[] bb, int sbyte) { int i1; int i2; if(endianStyle.equals("BigEndian")) { i1 = (bb[sbyte]&0xFF) << 24 | (bb[sbyte+1]&0xFF) << 16 | (bb[sbyte+2]&0xFF) << 8 | (bb[sbyte+3]&0xFF); i2 = (bb[sbyte+4]&0xFF) << 24 | (bb[sbyte+5]&0xFF) << 16 | (bb[sbyte+6]&0xFF) << 8 | (bb[sbyte+7]&0xFF); } else { i2 = (bb[sbyte+7]&0xFF) << 24 | (bb[sbyte+6]&0xFF) << 16 | (bb[sbyte+5]&0xFF) << 8 | (bb[sbyte+4]&0xFF); i1 = (bb[sbyte+3]&0xFF) << 24 | (bb[sbyte+2]&0xFF) << 16 | (bb[sbyte+1]&0xFF) << 8 | (bb[sbyte]&0xFF); } return new Double(Double.longBitsToDouble( ((long) i1) << 32 | ((long)i2&0x00000000ffffffffL) )); } |
if(endianStyle.equals("BigEndian")) | if(endianStyle.equals(Constants.BIG_ENDIAN)) | private String convertBinaryDataToString (String endianStyle, DataFormat binaryFormatObj, String strDataRep ) { byte[] bb = strDataRep.getBytes(); if (binaryFormatObj instanceof BinaryIntegerDataFormat) { int i; if(((BinaryIntegerDataFormat) binaryFormatObj).numOfBytes() == 2) { // 16 bit if(endianStyle.equals("BigEndian")) i = (bb[0]&0xFF) << 8 | (bb[1]&0xFF); else i = (bb[1]&0xFF) << 8 | (bb[0]&0xFF);/*Log.error("integer bits are: ");int sbyte = 0;for (int j=sbyte; j<sbyte+2; j++) { for(int k=7; k >=0; k--) { int newvalue = (bb[j] >> k)&0x01; Log.error(""+newvalue); } Log.error(" ");}Log.errorln("");*/ strDataRep = new Integer(i).toString(); } else if(((BinaryIntegerDataFormat) binaryFormatObj).numOfBytes() == 4) { // 32 bit (long) if(endianStyle.equals("BigEndian")) i = (bb[0]&0xFF) << 24 | (bb[1]&0xFF) << 16 | (bb[2]&0xFF) << 8 | (bb[3]&0xFF); else i = (bb[3]&0xFF) << 24 | (bb[2]&0xFF) << 16 | (bb[1]&0xFF) << 8 | (bb[0]&0xFF); strDataRep = new Integer(i).toString(); } else { Log.errorln("Cant treat binaryIntegers that arent either 16 or 32 bit. Ignoring value."); } } else if (binaryFormatObj instanceof BinaryFloatDataFormat) { int i; if(((BinaryFloatDataFormat) binaryFormatObj).numOfBytes() == 4) { // 32 bit float if(endianStyle.equals("BigEndian")) i = bb[0] << 24 | (bb[1]&0xFF) << 16 | (bb[2]&0xFF) << 8 | (bb[3]&0xFF); else i = bb[3] << 24 | (bb[2]&0xFF) << 16 | (bb[1]&0xFF) << 8 | (bb[0]&0xFF); float myfloat = Float.intBitsToFloat(i); strDataRep = new Float(myfloat).toString(); } else if(((BinaryFloatDataFormat) binaryFormatObj).numOfBytes() == 8) { // 64 bit float strDataRep = new String(""); } else { Log.warnln("Got Floating point number with neither 32 or 64 bits, ignoring."); strDataRep = new String(""); } } return strDataRep; } |
endElementHandlerHashtable.put(XDFNodeName.ARRAY, new arrayEndElementHandlerFunc()); | private void initEndHandlerHashtable () { endElementHandlerHashtable.put(XDFNodeName.DATA, new dataEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.FIELDGROUP, new fieldGroupEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.NOTES, new notesEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.PARAMETERGROUP, new parameterGroupEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.READ, new readEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.REPEAT, new repeatEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD0, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD1, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD2, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD3, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD4, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD5, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD6, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD7, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.TD8, new dataTagEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.VALUEGROUP, new valueGroupEndElementHandlerFunc()); endElementHandlerHashtable.put(XDFNodeName.VALUELIST, new valueListEndElementHandlerFunc()); } |
|
int nrofDataFormat = DataFormatList.length; | private void loadHrefDataIntoCurrentArray () { Href hrefObj = CurrentArray.getDataCube().getHref(); // well, we should be doing something with base here, // but arent because it isnt captured by this API. feh. // $file = $href->getBase() if $href->getBase(); if (hrefObj.getSysId() != null) { try { InputStream in = null; try { InputSource inputSource = resolveEntity(hrefObj.getPubId(), hrefObj.getSysId()); in = inputSource.getByteStream(); } catch (SAXException e) { Log.printStackTrace(e); } catch (NullPointerException e) { // in this case the InputSource object is null to request that // the parser open a regular URI connection to the system identifier. // In our case, the sysId IS the filename. File f = new File(hrefObj.getSysId()); in = (InputStream) new FileInputStream(new File(hrefObj.getSysId())); } // ok, got a bytestream, now read the info // Need to use a buffered reader here!!! if (in != null) { // probably could treat endian/nrofDataFormat as a globals too, since thats // how we treat the rest of the array parameters int nrofDataFormat = DataFormatList.length; String endian = CurrentArray.getXMLDataIOStyle().getEndian(); byte[] data = new byte[INPUTREADSIZE]; int bytes_read = 0; while ( true ) { int readAmount = in.read(data, bytes_read, INPUTREADSIZE-bytes_read); if ( readAmount == -1 ) { // pour out remaining buffer into the current array addByteDataToCurrentArray(data, bytes_read, endian, nrofDataFormat);Log.errorln("Dumping buffer after reading in "+bytes_read+" bytes"); break; // EOF reached } bytes_read += readAmount; // we exceeded the size of the buffer, dump to list if ( bytes_read == INPUTREADSIZE) { Log.errorln("Dumping buffer after reading in "+bytes_read+" bytes"); // pour out buffer into array addByteDataToCurrentArray(data, bytes_read, endian, nrofDataFormat); bytes_read = 0; } } } } catch (java.io.IOException e) { Log.printStackTrace(e); } } else { Log.warnln("Can't read Href data, undefined sysId!"); } } |
|
addByteDataToCurrentArray(data, bytes_read, endian, nrofDataFormat); | addByteDataToCurrentArray(data, bytes_read, endian ); | private void loadHrefDataIntoCurrentArray () { Href hrefObj = CurrentArray.getDataCube().getHref(); // well, we should be doing something with base here, // but arent because it isnt captured by this API. feh. // $file = $href->getBase() if $href->getBase(); if (hrefObj.getSysId() != null) { try { InputStream in = null; try { InputSource inputSource = resolveEntity(hrefObj.getPubId(), hrefObj.getSysId()); in = inputSource.getByteStream(); } catch (SAXException e) { Log.printStackTrace(e); } catch (NullPointerException e) { // in this case the InputSource object is null to request that // the parser open a regular URI connection to the system identifier. // In our case, the sysId IS the filename. File f = new File(hrefObj.getSysId()); in = (InputStream) new FileInputStream(new File(hrefObj.getSysId())); } // ok, got a bytestream, now read the info // Need to use a buffered reader here!!! if (in != null) { // probably could treat endian/nrofDataFormat as a globals too, since thats // how we treat the rest of the array parameters int nrofDataFormat = DataFormatList.length; String endian = CurrentArray.getXMLDataIOStyle().getEndian(); byte[] data = new byte[INPUTREADSIZE]; int bytes_read = 0; while ( true ) { int readAmount = in.read(data, bytes_read, INPUTREADSIZE-bytes_read); if ( readAmount == -1 ) { // pour out remaining buffer into the current array addByteDataToCurrentArray(data, bytes_read, endian, nrofDataFormat);Log.errorln("Dumping buffer after reading in "+bytes_read+" bytes"); break; // EOF reached } bytes_read += readAmount; // we exceeded the size of the buffer, dump to list if ( bytes_read == INPUTREADSIZE) { Log.errorln("Dumping buffer after reading in "+bytes_read+" bytes"); // pour out buffer into array addByteDataToCurrentArray(data, bytes_read, endian, nrofDataFormat); bytes_read = 0; } } } } catch (java.io.IOException e) { Log.printStackTrace(e); } } else { Log.warnln("Can't read Href data, undefined sysId!"); } } |
for (int i = start - 1; i < end; i++) | for (int i = start; i < end; i++) | public void intervalAdded(ListDataEvent e) { // must determine if the size of the combo box should change int start = e.getIndex0(); int end = e.getIndex1(); ComboBoxModel model = comboBox.getModel(); ListCellRenderer renderer = comboBox.getRenderer(); if (largestItemSize == null) largestItemSize = new Dimension(0, 0); for (int i = start - 1; i < end; i++) { Object item = model.getElementAt(i); Component comp = renderer.getListCellRendererComponent(new JList(), item, -1, false, false); if (comp.getPreferredSize().getWidth() > largestItemSize.getWidth()) largestItemSize = comp.getPreferredSize(); } } |
{ if (index < (list.size() - 1)) { return list.get(index + 1); } else { return null; } | { if (index < (list.size() - 1)) return list.get(index + 1); else return null; | public Object getNextValue() { /* Check for a next value */ if (index < (list.size() - 1)) { /* Return the element at the next index */ return list.get(index + 1); } else { /* Return null as this is the end of the list */ return null; } } |
{ if (index > 0) { return list.get(index - 1); } | { if (index > 0) return list.get(index - 1); | public Object getPreviousValue() { /* Check for a previous value. */ if (index > 0) { /* Return the element at the previous position */ return list.get(index - 1); } else { /* Return null as this is the start of the list */ return null; } } |
{ return null; } | return null; | public Object getPreviousValue() { /* Check for a previous value. */ if (index > 0) { /* Return the element at the previous position */ return list.get(index - 1); } else { /* Return null as this is the start of the list */ return null; } } |
{ if (list == null || list.size() == 0) { throw new IllegalArgumentException("The supplied list was invalid."); } if (this.list != list) { this.list = list; fireStateChanged(); } index = 0; } | { if (list == null || list.size() == 0) throw new IllegalArgumentException("The supplied list was invalid."); if (this.list != list) { this.list = list; fireStateChanged(); } index = 0; } | public void setList(List list) { /* Check for null or zero size list */ if (list == null || list.size() == 0) { throw new IllegalArgumentException("The supplied list was invalid."); } /* Check for a change of referenced list */ if (this.list != list) { /* Store the new list */ this.list = list; /* Notify listeners of a change */ fireStateChanged(); } /* We reset the other values in either case */ /* Set the index to 0 */ index = 0; } |
valueIndex = list.indexOf(value); if (valueIndex == -1) { throw new IllegalArgumentException("The supplied value does not " + "exist in this list"); } index = valueIndex; fireStateChanged(); } | valueIndex = list.indexOf(value); if (valueIndex == -1) throw new IllegalArgumentException("The supplied value does not " + "exist in this list"); index = valueIndex; fireStateChanged(); } | public void setValue(Object value) { int valueIndex; /* Search for the value in the list */ valueIndex = list.indexOf(value); /* Check for the value being found */ if (valueIndex == -1) { throw new IllegalArgumentException("The supplied value does not " + "exist in this list"); } /* Make the indices match */ index = valueIndex; /* Notify the listeners */ fireStateChanged(); } |
if (!(kpgSpi instanceof Cloneable)) throw new CloneNotSupportedException(); | public Object clone() throws CloneNotSupportedException { if (!(kpgSpi instanceof Cloneable)) throw new CloneNotSupportedException(); KeyPairGenerator result = new DummyKeyPairGenerator ((KeyPairGeneratorSpi) kpgSpi.clone(), this.getAlgorithm()); result.provider = this.getProvider(); return result; } |
|
JPanel kp = new JPanel(); | private void mapIt() { Object[] message = new Object[1]; JPanel kgp = new JPanel(); final KeyGetter kg = new KeyGetter(); kg.setForeground(Color.blue); message[0] = kgp; String function; if (functions.getSelectedValue() instanceof String) function = (String)functions.getSelectedValue(); else if (functions.getSelectedValue() instanceof Macro) { function = ((Macro)functions.getSelectedValue()).toString(); } else function = ((KeyDescription)functions.getSelectedValue()).toString(); kg.setText(LangTool.getString("key.labelMessage") + function); kgp.add(kg); String[] options = new String[1]; options[0] = LangTool.getString("key.labelClose"); JPanel kp = new JPanel(); JOptionPane opain = new JOptionPane(message, JOptionPane.PLAIN_MESSAGE, JOptionPane.DEFAULT_OPTION, // option type null, options, options[0]); dialog = opain.createDialog(this, getTitle()); // add window listener to the dialog so that we can place focus on the // key getter label instead of default and set the new key value when // the window is closed. dialog.addWindowListener(new WindowAdapter() { boolean gotFocus = false; public void windowClosed(WindowEvent we) { setNewKeyStrokes(kg.keyevent); } public void windowActivated(WindowEvent we) { // Once window gets focus, set initial focus to our KeyGetter // component if (!gotFocus) { kg.grabFocus(); gotFocus = true; } } }); dialog.setVisible(true); } |
|
public PluginDescriptorModel(PluginJar jarFile, XMLElement e) throws PluginException { this.jarFile = jarFile; id = getAttribute(e, "id", true); name = getAttribute(e, "name", true); providerName = getAttribute(e, "provider-name", false); version = getAttribute(e, "version", true); className = getAttribute(e, "class", false); system = getBooleanAttribute(e, "system", false); autoStart = getBooleanAttribute(e, "auto-start", false); configClassName = getAttribute(e, "configuration-class", false); final ArrayList epList = new ArrayList(); final ArrayList exList = new ArrayList(); final ArrayList reqList = new ArrayList(); RuntimeModel runtime = null; for (Iterator ci = e.getChildren().iterator(); ci.hasNext();) { final XMLElement childE = (XMLElement) ci.next(); final String tag = childE.getName(); if (tag.equals("extension-point")) { final ExtensionPoint ep = new ExtensionPointModel(this, childE); epList.add(ep); } else if (tag.equals("requires")) { for (Iterator i = childE.getChildren().iterator(); i.hasNext();) { final XMLElement impE = (XMLElement) i.next(); if (impE.getName().equals("import")) { reqList.add(new PluginPrerequisiteModel(this, impE)); } else { throw new PluginException("Unknown element " + impE.getName()); } } } else if (tag.equals("extension")) { exList.add(new ExtensionModel(this, childE)); } else if (tag.equals("runtime")) { if (runtime == null) { runtime = new RuntimeModel(this, childE); } else { throw new PluginException("duplicate runtime element"); } } else { throw new PluginException("Unknown element " + tag); } } if (!epList.isEmpty()) { extensionPoints = (ExtensionPointModel[]) epList.toArray(new ExtensionPointModel[epList.size()]); } else { extensionPoints = new ExtensionPointModel[0]; } if (!reqList.isEmpty()) { requires = (PluginPrerequisiteModel[]) reqList.toArray(new PluginPrerequisiteModel[reqList.size()]); } else { requires = new PluginPrerequisiteModel[0]; } if (!exList.isEmpty()) { extensions = (ExtensionModel[]) exList.toArray(new ExtensionModel[exList.size()]); } else { extensions = new ExtensionModel[0]; } this.runtime = runtime; | public PluginDescriptorModel(XMLElement e) throws PluginException { this(null, e); | public PluginDescriptorModel(PluginJar jarFile, XMLElement e) throws PluginException { this.jarFile = jarFile; id = getAttribute(e, "id", true); name = getAttribute(e, "name", true); providerName = getAttribute(e, "provider-name", false); version = getAttribute(e, "version", true); className = getAttribute(e, "class", false); system = getBooleanAttribute(e, "system", false); autoStart = getBooleanAttribute(e, "auto-start", false); configClassName = getAttribute(e, "configuration-class", false); //if (registry != null) {// registry.registerPlugin(this); //} final ArrayList epList = new ArrayList(); final ArrayList exList = new ArrayList(); final ArrayList reqList = new ArrayList(); RuntimeModel runtime = null; for (Iterator ci = e.getChildren().iterator(); ci.hasNext();) { final XMLElement childE = (XMLElement) ci.next(); final String tag = childE.getName(); if (tag.equals("extension-point")) { final ExtensionPoint ep = new ExtensionPointModel(this, childE); epList.add(ep); //if (registry != null) {// registry.registerExtensionPoint(ep); //} } else if (tag.equals("requires")) { for (Iterator i = childE.getChildren().iterator(); i.hasNext();) { final XMLElement impE = (XMLElement) i.next(); if (impE.getName().equals("import")) { reqList.add(new PluginPrerequisiteModel(this, impE)); } else { throw new PluginException("Unknown element " + impE.getName()); } } } else if (tag.equals("extension")) { exList.add(new ExtensionModel(this, childE)); } else if (tag.equals("runtime")) { if (runtime == null) { runtime = new RuntimeModel(this, childE); } else { throw new PluginException("duplicate runtime element"); } } else { throw new PluginException("Unknown element " + tag); } } if (!epList.isEmpty()) { extensionPoints = (ExtensionPointModel[]) epList.toArray(new ExtensionPointModel[epList.size()]); } else { extensionPoints = new ExtensionPointModel[0]; } if (!reqList.isEmpty()) { requires = (PluginPrerequisiteModel[]) reqList.toArray(new PluginPrerequisiteModel[reqList.size()]); } else { requires = new PluginPrerequisiteModel[0]; } if (!exList.isEmpty()) { extensions = (ExtensionModel[]) exList.toArray(new ExtensionModel[exList.size()]); } else { extensions = new ExtensionModel[0]; } this.runtime = runtime; } |
writeOut(outputstream, " "+ item.get("name") + "=\"" + item.get("value") + "\""); | writeOut(outputstream, " "+ item.get("name") + "=\""); writeOutAttribute(outputstream, (String)item.get("value")); writeOut(outputstream, "\""); | public void toXMLOutputStream ( OutputStream outputstream, Hashtable XMLDeclAttribs, String indent, boolean dontCloseNode, String newNodeNameString, String noChildObjectNodeName ) { String nodeNameString = classXDFNodeName; // 1. open this node, print its simple XML attributes if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired writeOut(outputstream,"<" + nodeNameString + ">"); // print opening statement //writeOut the body of DataFormat writeOut(outputstream, "<" + specificDataFormatName); // gather info about XMLAttributes in this object/node Hashtable xmlInfo = getXMLInfo(); // 2. Print out string object XML attributes EXCEPT for the one that // matches PCDATAAttribute. ArrayList attribs = (ArrayList) xmlInfo.get("attribList"); synchronized(attribs) { int stop = attribs.size(); for (int i = 0; i < stop; i++) { Hashtable item = (Hashtable) attribs.get(i); writeOut(outputstream, " "+ item.get("name") + "=\"" + item.get("value") + "\""); } } //writeout end of the boby writeOut(outputstream, "/>"); //writeout closing node writeOut(outputstream, "</" + nodeNameString+ ">"); if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, Constants.NEW_LINE); } |
setRequestFocusEnabled(true); | public JComponent() { super(); super.setLayout(new FlowLayout()); setDropTarget(new DropTarget()); defaultLocale = Locale.getDefault(); debugGraphicsOptions = DebugGraphics.NONE_OPTION; } |
|
e.consume(); | protected void processMouseMotionEvent(MouseEvent e) { if (mouseMotionListener == null) return; switch (e.id) { case MouseEvent.MOUSE_DRAGGED: mouseMotionListener.mouseDragged(e); break; case MouseEvent.MOUSE_MOVED: mouseMotionListener.mouseMoved(e); break; } } |
|
throw new NO_IMPLEMENT(); | if (orb instanceof OrbFunctional) { ((OrbFunctional) orb).ensureRunning(); } gnuRequest g = new gnuRequest(); g.setORB(orb); g.setOperation(operation); g.setIor(ior); g.m_target = target; g.ctx(context); g.set_args(parameters); if (returns != null) g.set_result(returns); return g; | public Request create_request(org.omg.CORBA.Object target, Context context, String operation, NVList parameters, NamedValue returns ) { throw new NO_IMPLEMENT(); } |
Component parent = component.getParent(); | public void addDirtyRegion(JComponent component, int x, int y, int w, int h) { if (w <= 0 || h <= 0 || !component.isShowing()) return; component.computeVisibleRect(rectCache); SwingUtilities.computeIntersection(x, y, w, h, rectCache); if (! rectCache.isEmpty()) { if (dirtyComponents.containsKey(component)) { SwingUtilities.computeUnion(rectCache.x, rectCache.y, rectCache.width, rectCache.height, (Rectangle) dirtyComponents.get(component)); } else { synchronized (dirtyComponents) { dirtyComponents.put(component, rectCache.getBounds()); } } if (! repaintWorker.isLive()) { repaintWorker.setLive(true); SwingUtilities.invokeLater(repaintWorker); } } } |
|
if (! dirtyComponents.containsKey(component)) return false; return component.isCompletelyDirty; | boolean retVal = false; if (dirtyComponents.containsKey(component)) { Rectangle dirtyRegion = (Rectangle) dirtyComponents.get(component); retVal = dirtyRegion.equals(SwingUtilities.getLocalBounds(component)); } return retVal; | public boolean isCompletelyDirty(JComponent component) { if (! dirtyComponents.containsKey(component)) return false; return component.isCompletelyDirty; } |
component.isCompletelyDirty = false; | public void markCompletelyClean(JComponent component) { synchronized (dirtyComponents) { dirtyComponents.remove(component); } component.isCompletelyDirty = false; } |
|
addDirtyRegion(component, r.x, r.y, r.width, r.height); component.isCompletelyDirty = true; | addDirtyRegion(component, 0, 0, r.width, r.height); | public void markCompletelyDirty(JComponent component) { Rectangle r = component.getBounds(); addDirtyRegion(component, r.x, r.y, r.width, r.height); component.isCompletelyDirty = true; } |
ArrayList repaintOrder = new ArrayList(dirtyComponentsWork.size());; repaintOrder.addAll(dirtyComponentsWork.keySet()); | HashSet repaintRoots = new HashSet(); Set components = dirtyComponentsWork.keySet(); for (Iterator i = components.iterator(); i.hasNext();) { JComponent dirty = (JComponent) i.next(); compileRepaintRoots(dirtyComponentsWork, dirty, repaintRoots); } | public void paintDirtyRegions() { // Short cicuit if there is nothing to paint. if (dirtyComponents.size() == 0) return; // Swap dirtyRegions with dirtyRegionsWork to avoid locking. synchronized (dirtyComponents) { HashMap swap = dirtyComponents; dirtyComponents = dirtyComponentsWork; dirtyComponentsWork = swap; } ArrayList repaintOrder = new ArrayList(dirtyComponentsWork.size());; // We sort the components by their size here. This way we have a good // chance that painting the bigger components also paints the smaller // components and we don't need to paint them twice. repaintOrder.addAll(dirtyComponentsWork.keySet()); if (comparator == null) comparator = new ComponentComparator(); Collections.sort(repaintOrder, comparator); repaintUnderway = true; for (Iterator i = repaintOrder.iterator(); i.hasNext();) { JComponent comp = (JComponent) i.next(); // If a component is marked completely clean in the meantime, then skip // it. Rectangle damaged = (Rectangle) dirtyComponentsWork.remove(comp); if (damaged == null || damaged.isEmpty()) continue; comp.paintImmediately(damaged); } repaintUnderway = false; commitRemainingBuffers(); } |
if (comparator == null) comparator = new ComponentComparator(); Collections.sort(repaintOrder, comparator); | public void paintDirtyRegions() { // Short cicuit if there is nothing to paint. if (dirtyComponents.size() == 0) return; // Swap dirtyRegions with dirtyRegionsWork to avoid locking. synchronized (dirtyComponents) { HashMap swap = dirtyComponents; dirtyComponents = dirtyComponentsWork; dirtyComponentsWork = swap; } ArrayList repaintOrder = new ArrayList(dirtyComponentsWork.size());; // We sort the components by their size here. This way we have a good // chance that painting the bigger components also paints the smaller // components and we don't need to paint them twice. repaintOrder.addAll(dirtyComponentsWork.keySet()); if (comparator == null) comparator = new ComponentComparator(); Collections.sort(repaintOrder, comparator); repaintUnderway = true; for (Iterator i = repaintOrder.iterator(); i.hasNext();) { JComponent comp = (JComponent) i.next(); // If a component is marked completely clean in the meantime, then skip // it. Rectangle damaged = (Rectangle) dirtyComponentsWork.remove(comp); if (damaged == null || damaged.isEmpty()) continue; comp.paintImmediately(damaged); } repaintUnderway = false; commitRemainingBuffers(); } |
|
for (Iterator i = repaintOrder.iterator(); i.hasNext();) | for (Iterator i = repaintRoots.iterator(); i.hasNext();) | public void paintDirtyRegions() { // Short cicuit if there is nothing to paint. if (dirtyComponents.size() == 0) return; // Swap dirtyRegions with dirtyRegionsWork to avoid locking. synchronized (dirtyComponents) { HashMap swap = dirtyComponents; dirtyComponents = dirtyComponentsWork; dirtyComponentsWork = swap; } ArrayList repaintOrder = new ArrayList(dirtyComponentsWork.size());; // We sort the components by their size here. This way we have a good // chance that painting the bigger components also paints the smaller // components and we don't need to paint them twice. repaintOrder.addAll(dirtyComponentsWork.keySet()); if (comparator == null) comparator = new ComponentComparator(); Collections.sort(repaintOrder, comparator); repaintUnderway = true; for (Iterator i = repaintOrder.iterator(); i.hasNext();) { JComponent comp = (JComponent) i.next(); // If a component is marked completely clean in the meantime, then skip // it. Rectangle damaged = (Rectangle) dirtyComponentsWork.remove(comp); if (damaged == null || damaged.isEmpty()) continue; comp.paintImmediately(damaged); } repaintUnderway = false; commitRemainingBuffers(); } |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.