rem
stringlengths
0
477k
add
stringlengths
0
313k
context
stringlengths
6
599k
public abstract int write(ByteBuffer src) throws IOException;
public final long write(ByteBuffer[] srcs) throws IOException { long b = 0; for (int i = 0; i < srcs.length; i++) b += write(srcs[i]); return b; }
public abstract int write(ByteBuffer src) throws IOException;
Level.toLevel(Level.OFF_INT);
log.setLevel((Level)Level.OFF);
public void setLevel(int newLevel) { switch (newLevel) { case OFF: Level.toLevel(Level.OFF_INT); break; case DEBUG: Level.toLevel(org.apache.log4j.Level.DEBUG_INT); break; case INFO: Level.toLevel(org.apache.log4j.Level.INFO_INT); ...
Level.toLevel(org.apache.log4j.Level.DEBUG_INT);
log.setLevel((Level)Level.DEBUG);
public void setLevel(int newLevel) { switch (newLevel) { case OFF: Level.toLevel(Level.OFF_INT); break; case DEBUG: Level.toLevel(org.apache.log4j.Level.DEBUG_INT); break; case INFO: Level.toLevel(org.apache.log4j.Level.INFO_INT); ...
Level.toLevel(org.apache.log4j.Level.INFO_INT);
log.setLevel((Level)Level.INFO);
public void setLevel(int newLevel) { switch (newLevel) { case OFF: Level.toLevel(Level.OFF_INT); break; case DEBUG: Level.toLevel(org.apache.log4j.Level.DEBUG_INT); break; case INFO: Level.toLevel(org.apache.log4j.Level.INFO_INT); ...
Level.toLevel(org.apache.log4j.Level.WARN_INT);
log.setLevel((Level)Level.WARN);
public void setLevel(int newLevel) { switch (newLevel) { case OFF: Level.toLevel(Level.OFF_INT); break; case DEBUG: Level.toLevel(org.apache.log4j.Level.DEBUG_INT); break; case INFO: Level.toLevel(org.apache.log4j.Level.INFO_INT); ...
Level.toLevel(org.apache.log4j.Level.ERROR_INT);
log.setLevel((Level)Level.ERROR);
public void setLevel(int newLevel) { switch (newLevel) { case OFF: Level.toLevel(Level.OFF_INT); break; case DEBUG: Level.toLevel(org.apache.log4j.Level.DEBUG_INT); break; case INFO: Level.toLevel(org.apache.log4j.Level.INFO_INT); ...
Level.toLevel(org.apache.log4j.Level.FATAL_INT);
log.setLevel((Level)Level.FATAL);
public void setLevel(int newLevel) { switch (newLevel) { case OFF: Level.toLevel(Level.OFF_INT); break; case DEBUG: Level.toLevel(org.apache.log4j.Level.DEBUG_INT); break; case INFO: Level.toLevel(org.apache.log4j.Level.INFO_INT); ...
if ((mY % 2) == 0)
if (((mY - y) % 2) == 0)
static void fillMetalPattern(Graphics g, int x, int y, int w, int h, Color light, Color dark) { int xOff = 0; for (int mY = y; mY < (y + h); mY++) { // set color alternating with every line if ((mY % 2) == 0) g.setColor(light); else g.s...
for (i = lo; i < hi; ++i)
for (i = lo; i <= hi; ++i)
public int[] getSelectedIndices() { int lo, hi, n, i, j; if (selectionModel.isSelectionEmpty()) return new int[0]; lo = selectionModel.getMinSelectionIndex(); hi = selectionModel.getMaxSelectionIndex(); n = 0; for (i = lo; i <= hi; ++i) if (selectionModel.isSelectedIndex(i)) n++; ...
.getSelectionMode() == treeSelectionModel.SINGLE_TREE_SELECTION)
.getSelectionMode() == TreeSelectionModel.SINGLE_TREE_SELECTION)
public void mouseClicked(MouseEvent e) { Point click = e.getPoint(); int row = ((int) click.getY() / getRowHeight()) - 1; if (BasicTreeUI.this.tree.isRowSelected(row)) BasicTreeUI.this.tree.removeSelectionRow(row); else if (BasicTreeUI.this.tree.getSelectionModel() .getSelectionMode() == tree...
.getSelectionMode() == treeSelectionModel.CONTIGUOUS_TREE_SELECTION)
.getSelectionMode() == TreeSelectionModel.CONTIGUOUS_TREE_SELECTION)
public void mouseClicked(MouseEvent e) { Point click = e.getPoint(); int row = ((int) click.getY() / getRowHeight()) - 1; if (BasicTreeUI.this.tree.isRowSelected(row)) BasicTreeUI.this.tree.removeSelectionRow(row); else if (BasicTreeUI.this.tree.getSelectionModel() .getSelectionMode() == tree...
BasicTreeUI.this.tree.getSelectionModel() .setSelectionMode( treeSelectionModel.DISCONTIGUOUS_TREE_SELECTION);
BasicTreeUI.this.tree.getSelectionModel().setSelectionMode( TreeSelectionModel.DISCONTIGUOUS_TREE_SELECTION);
public void mouseClicked(MouseEvent e) { Point click = e.getPoint(); int row = ((int) click.getY() / getRowHeight()) - 1; if (BasicTreeUI.this.tree.isRowSelected(row)) BasicTreeUI.this.tree.removeSelectionRow(row); else if (BasicTreeUI.this.tree.getSelectionModel() .getSelectionMode() == tree...
}
public void mouseClicked(MouseEvent e) { Point click = e.getPoint(); int row = ((int) click.getY() / getRowHeight()) - 1; if (BasicTreeUI.this.tree.isRowSelected(row)) BasicTreeUI.this.tree.removeSelectionRow(row); else if (BasicTreeUI.this.tree.getSelectionModel() .getSelectionMode() == tree...
BasicTreeUI.this.tree.repaint();
public void treeCollapsed(TreeExpansionEvent event) { }
BasicTreeUI.this.tree.repaint();
public void treeExpanded(TreeExpansionEvent event) { }
return new Rectangle(x, y, SwingUtilities.computeStringWidth(fm, s), fm .getHeight());
return new Rectangle(x, y, SwingUtilities.computeStringWidth(fm, s), fm.getHeight()); } return null;
private Rectangle getCellBounds(int x, int y, Object cell) { String s = cell.toString(); Font f = tree.getFont(); FontMetrics fm = tree.getToolkit().getFontMetrics(tree.getFont()); return new Rectangle(x, y, SwingUtilities.computeStringWidth(fm, s), fm .getHeight()); }
return new Dimension(200, 900);
return getPreferredSize(c);
public Dimension getMaximumSize(JComponent c) { // FIXME: not implemented return new Dimension(200, 900); }
return new Dimension(200, 900);
return getPreferredSize(c);
public Dimension getMinimumSize(JComponent c) { // FIXME: not implemented return new Dimension(200, 900); }
DefaultMutableTreeNode pathForRow = ((DefaultMutableTreeNode) (tree .getModel()).getRoot());
DefaultMutableTreeNode node = ((DefaultMutableTreeNode) (tree.getModel()) .getRoot());
public TreePath getPathForRow(JTree tree, int row) { // FIXME: check visibility when expand/collapse is implemented DefaultMutableTreeNode pathForRow = ((DefaultMutableTreeNode) (tree .getModel()).getRoot()); for (int i = 0; i < row; i++) { if (pathForRow != null) pathForRow = pathForRow.getNextNode(); } ...
{ if (pathForRow != null) pathForRow = pathForRow.getNextNode(); } if (pathForRow == null) return null; return new TreePath(pathForRow.getPath()); }
node = getNextVisibleNode(node); if (node == null) return null; return new TreePath(node.getPath()); }
public TreePath getPathForRow(JTree tree, int row) { // FIXME: check visibility when expand/collapse is implemented DefaultMutableTreeNode pathForRow = ((DefaultMutableTreeNode) (tree .getModel()).getRoot()); for (int i = 0; i < row; i++) { if (pathForRow != null) pathForRow = pathForRow.getNextNode(); } ...
return treeState.getRowCount();
DefaultMutableTreeNode node = ((DefaultMutableTreeNode) (tree.getModel()) .getRoot()); int count = 0; while (node != null) { count++; node = getNextVisibleNode(node); } return count;
public int getRowCount(JTree tree) { return treeState.getRowCount(); }
return false;
TreePath pathForRow = getPathForRow(tree, row); if (pathForRow == null) return true; Object node = pathForRow.getLastPathComponent(); if (node instanceof TreeNode) return ((TreeNode) node).isLeaf(); else return true;
protected boolean isLeaf(int row) { return false; // FIXME: not implemented }
TreePath tp = new TreePath(((DefaultMutableTreeNode) leaf).getPath()); boolean selected = tree.isPathSelected(tp);
TreePath curr = new TreePath(((DefaultMutableTreeNode) leaf).getPath()); boolean selected = tree.isPathSelected(curr);
private void paintLeaf(Graphics g, int x, int y, JTree tree, Object leaf) { TreePath tp = new TreePath(((DefaultMutableTreeNode) leaf).getPath()); boolean selected = tree.isPathSelected(tp); if (selected) { Component comp = tree.getCellRenderer() .getTreeCellRendererComponent(tree, leaf, true, false, ...
TreePath tp = new TreePath(((DefaultMutableTreeNode) nonLeaf).getPath()); boolean selected = tree.isPathSelected(tp);
TreePath curr = new TreePath(((DefaultMutableTreeNode) nonLeaf).getPath()); boolean selected = tree.isPathSelected(curr); boolean expanded = tree.isExpanded(curr);
private void paintNonLeaf(Graphics g, int x, int y, JTree tree, Object nonLeaf) { TreePath tp = new TreePath(((DefaultMutableTreeNode) nonLeaf).getPath()); boolean selected = tree.isPathSelected(tp); if (selected) { Component comp = tree.getCellRenderer() .getTreeCellRendererComponent(tree, nonLeaf, true, ...
.getTreeCellRendererComponent(tree, nonLeaf, true, false, true, 0, false); rendererPane.paintComponent(g, comp, tree, getCellBounds(x, y, nonLeaf));
.getTreeCellRendererComponent(tree, nonLeaf, true, expanded, false, 0, false); rendererPane.paintComponent(g, comp, tree, getCellBounds(x, y, nonLeaf));
private void paintNonLeaf(Graphics g, int x, int y, JTree tree, Object nonLeaf) { TreePath tp = new TreePath(((DefaultMutableTreeNode) nonLeaf).getPath()); boolean selected = tree.isPathSelected(tp); if (selected) { Component comp = tree.getCellRenderer() .getTreeCellRendererComponent(tree, nonLeaf, true, ...
Component c = tree.getCellRenderer().getTreeCellRendererComponent(tree, nonLeaf, false, false, false, 0, false);
Component c = tree.getCellRenderer().getTreeCellRendererComponent( tree, nonLeaf, false, expanded, false, 0, false);
private void paintNonLeaf(Graphics g, int x, int y, JTree tree, Object nonLeaf) { TreePath tp = new TreePath(((DefaultMutableTreeNode) nonLeaf).getPath()); boolean selected = tree.isPathSelected(tp); if (selected) { Component comp = tree.getCellRenderer() .getTreeCellRendererComponent(tree, nonLeaf, true, ...
g.drawLine(indentation + halfWidth, descent + halfHeight, indentation + rightChildIndent, descent + halfHeight);
heightOfLine = descent + halfHeight; g.drawLine(indentation + halfWidth, heightOfLine, indentation + rightChildIndent, heightOfLine);
private int paintRecursive(Graphics g, int indentation, int descent, int childNumber, int depth, JTree tree, TreeModel mod, Object curr) { Rectangle clip = g.getClipBounds(); if (indentation > clip.x + clip.width + rightChildIndent || descent > clip.y + clip.height + getRowHeight()) return descent; int...
int y1 = descent - halfHeight; if (y0 != y1)
if (tree.isExpanded(new TreePath(((DefaultMutableTreeNode) curr) .getPath()))) if (y0 != heightOfLine)
private int paintRecursive(Graphics g, int indentation, int descent, int childNumber, int depth, JTree tree, TreeModel mod, Object curr) { Rectangle clip = g.getClipBounds(); if (indentation > clip.x + clip.width + rightChildIndent || descent > clip.y + clip.height + getRowHeight()) return descent; int...
g .drawLine(indentation + halfWidth, y0, indentation + halfWidth, y1);
g.drawLine(indentation + halfWidth, y0, indentation + halfWidth, heightOfLine);
private int paintRecursive(Graphics g, int indentation, int descent, int childNumber, int depth, JTree tree, TreeModel mod, Object curr) { Rectangle clip = g.getClipBounds(); if (indentation > clip.x + clip.width + rightChildIndent || descent > clip.y + clip.height + getRowHeight()) return descent; int...
final Point screen = new Point(location); final Component parent = component.getParent(); if (parent != null) { final Point parentScreen = parent.getLocationOnScreen(); screen.translate(parentScreen.x, parentScreen.y); } return screen; }
return computeLocationOnScreen(component); }
public Point getLocationOnScreen() { final Point screen = new Point(location); final Component parent = component.getParent(); if (parent != null) { final Point parentScreen = parent.getLocationOnScreen(); screen.translate(parentScreen.x, parentScreen.y); } r...
public Image createImage(ImageProducer producer) { return new JNodeImage(producer);
public Image createImage(byte[] data, int offset, int len) { if (len >= 4 && data[offset + 0] == 'G' && data[offset + 1] == 'I' && data[offset + 2] == 'F' && data[offset + 3] == '8') { try { return createImage(new GIFDecoder(new ByteArrayInputStream( data, offset, len))); } catch (LinkageError err) { } } return new Er...
public Image createImage(ImageProducer producer) { return new JNodeImage(producer); }
else string = getClass ().getName () + "[" + paramString () + "] on " + source;
public String toString () { String string = null; if (source instanceof Component) string = getClass ().getName () + "[" + paramString () + "] on " + ((Component) source).getName (); else if (source instanceof MenuComponent) string = getClass ().getName () + "[" + paramString () + "] on " ...
s1.setMacroRunning(false);
public void executeScriptFile(Session session, String scriptFile) throws InterpreterDriver.InterpreterException { try { final Session s1 = session; final String s2 = scriptFile; s1.setMacroRunning(true); Runnable interpretIt = new Runnable() { public v...
s1.setMacroRunning(false);
public void run() { _interpreter = new PythonInterpreter(); _interpreter.set("_session",s1); _interpreter.execfile(s2); }
assertEquals( "Unable to retrieve localized text for locale: default", s0, "value1" );
assertEquals( "Unable to retrieve localized text for locale: default", s0, "[] value1" );
public void testLocalization() { String s0 = i18n.getString( null, null, "key1" ); assertEquals( "Unable to retrieve localized text for locale: default", s0, "value1" ); String s1 = i18n.getString( null, new Locale( "en", "US" ), "key2" ); assertEquals( "Unable to retrieve localized t...
assertEquals( "Unable to retrieve localized text for locale: en-US", s1, "value2" );
assertEquals( "Unable to retrieve localized text for locale: en-US", s1, "[en_US] value2" );
public void testLocalization() { String s0 = i18n.getString( null, null, "key1" ); assertEquals( "Unable to retrieve localized text for locale: default", s0, "value1" ); String s1 = i18n.getString( null, new Locale( "en", "US" ), "key2" ); assertEquals( "Unable to retrieve localized t...
assertEquals( "Unable to retrieve localized text for locale: fr-US", s4, "[fr] value3" );
assertEquals( "Unable to retrieve localized text for locale: fr", s4, "[fr] value3" );
public void testLocalization() { String s0 = i18n.getString( null, null, "key1" ); assertEquals( "Unable to retrieve localized text for locale: default", s0, "value1" ); String s1 = i18n.getString( null, new Locale( "en", "US" ), "key2" ); assertEquals( "Unable to retrieve localized t...
String s5 = i18n.getString( "org.codehaus.plexus.i18n.i18n", null, "key1" );
String s5 = i18n.getString( "org.codehaus.plexus.i18n.FooBundle", new Locale( "fr", "FR" ), "key3" );
public void testLocalization() { String s0 = i18n.getString( null, null, "key1" ); assertEquals( "Unable to retrieve localized text for locale: default", s0, "value1" ); String s1 = i18n.getString( null, new Locale( "en", "US" ), "key2" ); assertEquals( "Unable to retrieve localized t...
assertEquals( "value1", s5 );
assertEquals( "Unable to retrieve localized text for locale: fr-FR", s5, "[fr] value3" ); String s6 = i18n.getString( "org.codehaus.plexus.i18n.i18n", null, "key1" ); assertEquals( "Unable to retrieve localized properties for locale: default", "[] value1", s6 ); Locale old = Locale.getDefault(); Locale.setDefault(Lo...
public void testLocalization() { String s0 = i18n.getString( null, null, "key1" ); assertEquals( "Unable to retrieve localized text for locale: default", s0, "value1" ); String s1 = i18n.getString( null, new Locale( "en", "US" ), "key2" ); assertEquals( "Unable to retrieve localized t...
sew.show();
sew.setVisible(true);
private void showPopupMenu(MouseEvent me) { JPopupMenu jpm = new JPopupMenu(); JMenuItem menuItem; Action action; final int row = spools.rowAtPoint(me.getPoint()); final int col = spools.convertColumnIndexToModel( spools.columnAtPoint(me.getPoint()));// System.out...
sew.show();
sew.setVisible(true);
public void actionPerformed(ActionEvent e) { SpoolExportWizard sew = new SpoolExportWizard(getSpooledFile(row), session); sew.show(); }
public NoSuchMethodException() { super();
public NoSuchMethodException() {
public NoSuchMethodException() { super(); }
public NoSuchAlgorithmException(String msg)
public NoSuchAlgorithmException()
public NoSuchAlgorithmException(String msg) { super(msg); }
super(msg);
public NoSuchAlgorithmException(String msg) { super(msg); }
SecureSet (final Subject subject, final int type, final Collection elements)
SecureSet (final Subject subject, final int type, final Collection inElements)
SecureSet (final Subject subject, final int type, final Collection elements) { this (subject, type); for (Iterator it = elements.iterator(); it.hasNext(); ) { Object o = it.next(); if (type == PRINCIPALS && !(o instanceof Principal)) { throw new IllegalA...
for (Iterator it = elements.iterator(); it.hasNext(); )
for (Iterator it = inElements.iterator(); it.hasNext(); )
SecureSet (final Subject subject, final int type, final Collection elements) { this (subject, type); for (Iterator it = elements.iterator(); it.hasNext(); ) { Object o = it.next(); if (type == PRINCIPALS && !(o instanceof Principal)) { throw new IllegalA...
if (!elements.contains (o))
if (!this.elements.contains (o))
SecureSet (final Subject subject, final int type, final Collection elements) { this (subject, type); for (Iterator it = elements.iterator(); it.hasNext(); ) { Object o = it.next(); if (type == PRINCIPALS && !(o instanceof Principal)) { throw new IllegalA...
elements.add (o);
this.elements.add (o);
SecureSet (final Subject subject, final int type, final Collection elements) { this (subject, type); for (Iterator it = elements.iterator(); it.hasNext(); ) { Object o = it.next(); if (type == PRINCIPALS && !(o instanceof Principal)) { throw new IllegalA...
return elements.remove (element);
return elements.contains (element);
public synchronized boolean contains (final Object element) { return elements.remove (element); }
g.setColor(Color.black);
y = y + getShift(); g.setColor(MetalLookAndFeel.getBlack());
public void paintIcon(Component c, Graphics g, int x, int y) { // TODO: pick up appropriate UI colors g.setColor(Color.black); g.drawLine(x, y, x + 9, y); g.drawLine(x, y + 1, x, y + 15); g.drawLine(x, y + 15, x + 12, y + 15); g.drawLine(x + 12, ...
g.setColor(new Color(204, 204, 255));
g.setColor(MetalLookAndFeel.getPrimaryControl());
public void paintIcon(Component c, Graphics g, int x, int y) { // TODO: pick up appropriate UI colors g.setColor(Color.black); g.drawLine(x, y, x + 9, y); g.drawLine(x, y + 1, x, y + 15); g.drawLine(x, y + 15, x + 12, y + 15); g.drawLine(x + 12, ...
g.setColor(Color.black); g.drawLine(x, y + 3, x, y + 12); g.drawLine(x, y + 12, x + 15, y + 12); g.drawLine(x + 15, y + 12, x + 15, y + 2); g.drawLine(x + 14, y + 3, x + 9, y + 3); g.drawLine(x + 8, y + 2, x + 1, y + 2); g.setColor(new Color(204, 204, 255)); g.fillRect(x + 2, y + 4, 7, 8); g.fillRect(x + 9, y + 5, 6, 7...
y = y + getShift(); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y + 6, x, y + 15); g.drawLine(x, y + 15, x + 15, y + 15); g.drawLine(x + 15, y + 15, x + 15, y + 5); g.drawLine(x + 14, y + 6, x + 9, y + 6); g.drawLine(x + 8, y + 5, x + 1, y + 5); g.setColor(MetalLookAndFeel.getPrimaryControl()); g.fillRect(x ...
public void paintIcon(Component c, Graphics g, int x, int y) { // TODO: pick up appropriate UI colors g.setColor(Color.black); g.drawLine(x, y + 3, x, y + 12); g.drawLine(x, y + 12, x + 15, y + 12); g.drawLine(x + 15, y + 12, x + 15, y + 2); g.drawLine(x + 14, y + 3, x + 9, y + 3);...
g.setColor(new Color(102, 102, 153));
g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow());
public void paintIcon(Component c, Graphics g, int x, int y) { g.setColor(new Color(102, 102, 153)); g.fillRect(x + 1, y, 14, 2); g.fillRect(x, y + 1, 2, 14); g.fillRect(x + 1, y + 14, 14, 2); g.fillRect(x + 14, y + 1, 2, 14); g.drawLine(x + 2, y + 5, x + 14, y + 5); g.s...
g.setColor(new Color(204, 204, 255));
g.setColor(MetalLookAndFeel.getPrimaryControl());
public void paintIcon(Component c, Graphics g, int x, int y) { g.setColor(new Color(102, 102, 153)); g.fillRect(x + 1, y, 14, 2); g.fillRect(x, y + 1, 2, 14); g.fillRect(x + 1, y + 14, 14, 2); g.fillRect(x + 14, y + 1, 2, 14); g.drawLine(x + 2, y + 5, x + 14, y + 5); g.s...
g.setColor(Color.white);
g.setColor(MetalLookAndFeel.getWhite());
public void paintIcon(Component c, Graphics g, int x, int y) { g.setColor(new Color(102, 102, 153)); g.fillRect(x + 1, y, 14, 2); g.fillRect(x, y + 1, 2, 14); g.fillRect(x + 1, y + 14, 14, 2); g.fillRect(x + 14, y + 1, 2, 14); g.drawLine(x + 2, y + 5, x + 14, y + 5); g.s...
(obj instanceof SmallAttributeSet)
(obj instanceof AttributeSet)
public boolean equals(Object obj) { return (obj instanceof SmallAttributeSet) && this.isEqual((AttributeSet)obj); }
while (getMacroByNumber(++x) != null) {} macros.put("macro" + x + "." + name,keyStrokes); macrosExist = true;
if (macrosExist && getMacroByName(name) != null) { Set macroSet = macros.keySet(); Iterator macroIterator = macroSet.iterator(); String byName = null; String prefix = null; while (macroIterator.hasNext()) { byName = (String)macroIterator.next(); if (byName.endsWith(name)) { prefix = byName.substring(0,byName.indexOf...
public final static void setMacro(String name, String keyStrokes) { int x = 0; while (getMacroByNumber(++x) != null) {} macros.put("macro" + x + "." + name,keyStrokes); macrosExist = true; saveMacros(); }
if (txt != null) {
public void getChars(int where, int len, Segment txt) throws BadLocationException { checkLocation(where, len); if (txt != null) { txt.array = this.content; txt.offset = where; txt.count = len; } }
}
public void getChars(int where, int len, Segment txt) throws BadLocationException { checkLocation(where, len); if (txt != null) { txt.array = this.content; txt.offset = where; txt.count = len; } }
checkLocation(where, nitems);
checkLocation(where, nitems + 1);
public UndoableEdit remove(int where, int nitems) throws BadLocationException { checkLocation(where, nitems); char[] temp = new char[(this.content.length - nitems)]; this.count = this.count - nitems; RemoveUndo rundo = new RemoveUndo(where, new String(this.content, where, nitems)); // Copy array. S...
super();
public CannotRedoException() { }
super();
public CannotUndoException() { }
public DatagramSocket(SocketAddress address) throws SocketException
protected DatagramSocket(DatagramSocketImpl impl)
public DatagramSocket(SocketAddress address) throws SocketException { // @classpath-bugfix Security String propVal = (String)AccessController.doPrivileged(new GetPropertyAction("impl.prefix")); if (factory != null) { // @classpath-bugfix Use factory impl = factory.createDatagramSocketImpl();...
String propVal = (String)AccessController.doPrivileged(new GetPropertyAction("impl.prefix")); if (factory != null) { impl = factory.createDatagramSocketImpl(); } else if (propVal == null || propVal.equals("")) impl = new PlainDatagramSocketImpl(); else try { impl = (DatagramSocketImpl) Class.forName("java.net." + prop...
if (impl == null) throw new NullPointerException("impl may not be null");
public DatagramSocket(SocketAddress address) throws SocketException { // @classpath-bugfix Security String propVal = (String)AccessController.doPrivileged(new GetPropertyAction("impl.prefix")); if (factory != null) { // @classpath-bugfix Use factory impl = factory.createDatagramSocketImpl();...
if (address != null) bind(address);
this.impl = impl; this.remoteAddress = null; this.remotePort = -1;
public DatagramSocket(SocketAddress address) throws SocketException { // @classpath-bugfix Security String propVal = (String)AccessController.doPrivileged(new GetPropertyAction("impl.prefix")); if (factory != null) { // @classpath-bugfix Use factory impl = factory.createDatagramSocketImpl();...
public AccessibleJWindow()
protected AccessibleJWindow()
public AccessibleJWindow() { super(); // Nothing to do here. }
break;
private void parseConditionalSect(char[] saved) throws Exception { skipWhitespace(); if (tryRead("INCLUDE")) { skipWhitespace(); require('['); // VC: Proper Conditional Section/PE Nesting if (readBuffer != saved) { handler.verror("Illegal Conditional Section/...
XDF.setDefaultDataArraySize(value);
Specification.getInstance().setDefaultDataArraySize(value);
public Object action (SaxDocumentHandler handler, AttributeList attrs) { // The root node is just a "structure" node, // but is always the first one. XDF.setXMLAttributes(attrs); // set XML attributes from passed list CurrentStructure = XDF; // current working structure...
protected synchronized void create(boolean stream) throws IOException { throw new SocketException("Not implemented");
protected synchronized void create(boolean stream) throws IOException { channel = new SocketChannelImpl(false); VMChannel vmchannel = channel.getVMChannel(); vmchannel.initSocket(stream); channel.configureBlocking(true); impl.getState().setChannelFD(vmchannel.getState());
protected synchronized void create(boolean stream) throws IOException { // @vm-specific no natives //TODO implement me throw new SocketException("Not implemented"); }
super("bdf");
public BDFFontProvider() { log.debug("new BDFFontProvider"); }
{ final BDFFont bdfFont = (BDFFont) font;
{ final BDFFont bdfFont = getBDFFont(font);
protected FontMetrics createFontMetrics(Font font) throws IOException { final BDFFont bdfFont = (BDFFont) font; return bdfFont.getFontMetrics(); }
final BDFFont bdfFont = (BDFFont) font;
final BDFFont bdfFont = getBDFFont(font);
protected TextRenderer createTextRenderer(RenderCache renderCache, Font font) { final BDFFont bdfFont = (BDFFont) font; final TextRenderer renderer = new BDFTextRenderer(bdfFont.getContainer()); log.debug("created TextRenderer for BDF"); return renderer; }
protected GnuRSAKey(final BigInteger n, final BigInteger e)
protected GnuRSAKey(int defaultFormat, BigInteger n, BigInteger e)
protected GnuRSAKey(final BigInteger n, final BigInteger e) { super(); this.n = n; this.e = e; }
this.defaultFormat = defaultFormat <= 0 ? Registry.RAW_ENCODING_ID : defaultFormat;
protected GnuRSAKey(final BigInteger n, final BigInteger e) { super(); this.n = n; this.e = e; }
return null;
return KeyPairCodecFactory.getEncodingShortName(defaultFormat);
public String getFormat() { return null; }
input.mark(2000);
private void p_invoke() throws SystemException { binaryReply response = submit(); ReplyHeader rh = response.header.create_reply_header(); cdrBufInput input = response.getStream(); input.setOrb(orb); rh.read(input); // The stream must be aligned sinve v1.2, but only once. boolean ...
String uxId = input.read_string(); input.reset();
gnuAny exc = new gnuAny();
private void p_invoke() throws SystemException { binaryReply response = submit(); ReplyHeader rh = response.header.create_reply_header(); cdrBufInput input = response.getStream(); input.setOrb(orb); rh.read(input); // The stream must be aligned sinve v1.2, but only once. boolean ...
UserException uex = ObjectCreator.readUserException(uxId, input);
exc.insert_Streamable(new streamReadyHolder(input));
private void p_invoke() throws SystemException { binaryReply response = submit(); ReplyHeader rh = response.header.create_reply_header(); cdrBufInput input = response.getStream(); input.setOrb(orb); rh.read(input); // The stream must be aligned sinve v1.2, but only once. boolean ...
if (uex == null) m_environment.exception(new UserException(uxId)); else m_environment.exception(uex);
UnknownUserException unuex = new UnknownUserException(exc); m_environment.exception(unuex);
private void p_invoke() throws SystemException { binaryReply response = submit(); ReplyHeader rh = response.header.create_reply_header(); cdrBufInput input = response.getStream(); input.setOrb(orb); rh.read(input); // The stream must be aligned sinve v1.2, but only once. boolean ...
setBigEndian(ior.Big_Endian);
public void setIor(IOR an_ior) { ior = an_ior; }
Socket socket = new Socket(ior.Internet.host, ior.Internet.port);
long pause = PAUSE_INITIAL; if (socket == null) { Open: for (int i = 0; i < PAUSE_STEPS; i++) { try { socket = new Socket(ior.Internet.host, ior.Internet.port); break Open; } catch (BindException ex) { try { System.gc(); Thread.sleep(pause); pause = pause * 2; if (pause > PAUSE_MAX) pause = PAUSE_MAX; } catch (Inte...
public synchronized binaryReply submit() { gnu.CORBA.GIOP.MessageHeader header = new gnu.CORBA.GIOP.MessageHeader(); // The byte order will be Big Endian by default. header.message_type = gnu.CORBA.GIOP.MessageHeader.REQUEST; header.version = useVersion(ior.Internet.version); RequestHeader rh = header...
n = socketInput.read(r, n, r.length - n);
n += socketInput.read(r, n, r.length - n);
public synchronized binaryReply submit() { gnu.CORBA.GIOP.MessageHeader header = new gnu.CORBA.GIOP.MessageHeader(); // The byte order will be Big Endian by default. header.message_type = gnu.CORBA.GIOP.MessageHeader.REQUEST; header.version = useVersion(ior.Internet.version); RequestHeader rh = header...
socketInput.close();
public synchronized binaryReply submit() { gnu.CORBA.GIOP.MessageHeader header = new gnu.CORBA.GIOP.MessageHeader(); // The byte order will be Big Endian by default. header.message_type = gnu.CORBA.GIOP.MessageHeader.REQUEST; header.version = useVersion(ior.Internet.version); RequestHeader rh = header...
catch (IOException ex1)
catch (IOException io_ex)
public synchronized binaryReply submit() { gnu.CORBA.GIOP.MessageHeader header = new gnu.CORBA.GIOP.MessageHeader(); // The byte order will be Big Endian by default. header.message_type = gnu.CORBA.GIOP.MessageHeader.REQUEST; header.version = useVersion(ior.Internet.version); RequestHeader rh = header...
ex1.printStackTrace();
public synchronized binaryReply submit() { gnu.CORBA.GIOP.MessageHeader header = new gnu.CORBA.GIOP.MessageHeader(); // The byte order will be Big Endian by default. header.message_type = gnu.CORBA.GIOP.MessageHeader.REQUEST; header.version = useVersion(ior.Internet.version); RequestHeader rh = header...
finally { try { if (socket != null && !socket.isClosed()) { socket.setSoTimeout(Functional_ORB.TANDEM_REQUESTS); SocketRepository.put_socket(key, socket ); } } catch (IOException scx) { InternalError ierr = new InternalError(); ierr.initCause(scx); throw ierr; } }
public synchronized binaryReply submit() { gnu.CORBA.GIOP.MessageHeader header = new gnu.CORBA.GIOP.MessageHeader(); // The byte order will be Big Endian by default. header.message_type = gnu.CORBA.GIOP.MessageHeader.REQUEST; header.version = useVersion(ior.Internet.version); RequestHeader rh = header...
public static SystemException readSystemException(InputStream input)
public static SystemException readSystemException(InputStream input, ServiceContext[] contexts)
public static SystemException readSystemException(InputStream input) { String idl = input.read_string(); int minor = input.read_ulong(); CompletionStatus status = CompletionStatusHelper.read(input); SystemException exception = ObjectCreator.createSystemException(idl, minor, status); return except...
CompletionStatus status = CompletionStatusHelper.read(input);
CompletionStatus completed = CompletionStatusHelper.read(input);
public static SystemException readSystemException(InputStream input) { String idl = input.read_string(); int minor = input.read_ulong(); CompletionStatus status = CompletionStatusHelper.read(input); SystemException exception = ObjectCreator.createSystemException(idl, minor, status); return except...
SystemException exception = ObjectCreator.createSystemException(idl, minor, status);
try { exception = (SystemException) createObject(idl, null); exception.minor = minor; exception.completed = completed; } catch (Exception ex) { UNKNOWN u = new UNKNOWN("Unsupported system exception " + idl, minor, completed); u.initCause(ex); throw u; } try { ServiceContext uEx = ServiceContext.find( ServiceContext....
public static SystemException readSystemException(InputStream input) { String idl = input.read_string(); int minor = input.read_ulong(); CompletionStatus status = CompletionStatusHelper.read(input); SystemException exception = ObjectCreator.createSystemException(idl, minor, status); return except...
String helper = toHelperName(idl); Class helperClass = Class.forName(helper);
Class helperClass = findHelper(idl);
public static UserException readUserException(String idl, InputStream input) { try { String helper = toHelperName(idl); Class helperClass = Class.forName(helper); Method read = helperClass.getMethod("read", new Class[] { org.omg.CORBA.portable.InputStream.class } ...
t.minor = Minor.Header;
public void write(java.io.OutputStream out) { try { abstractDataOutputStream dout; if (isBigEndian()) dout = new BigEndianOutputStream(out); else dout = new LittleEndianOutputStream(out); // Write magic sequence. dout.write(MAGIC); // Write version ...
throw new MARSHAL("Not a GIOP message");
{ MARSHAL m = new MARSHAL("Not a GIOP message"); m.minor = Minor.Giop; throw m; }
public void read(java.io.InputStream istream) throws MARSHAL { try { byte[] xMagic = new byte[ MAGIC.length ]; istream.read(xMagic); if (!Arrays.equals(xMagic, MAGIC)) throw new MARSHAL("Not a GIOP message"); version = Version.read_version(istream); abst...
t.minor = Minor.Header;
public void read(java.io.InputStream istream) throws MARSHAL { try { byte[] xMagic = new byte[ MAGIC.length ]; istream.read(xMagic); if (!Arrays.equals(xMagic, MAGIC)) throw new MARSHAL("Not a GIOP message"); version = Version.read_version(istream); abst...
public UnsatisfiedLinkError(String s) { super(s);
public UnsatisfiedLinkError() {
public UnsatisfiedLinkError(String s) { super(s); }
public void checkRead(String filename)
public void checkRead(FileDescriptor desc)
public void checkRead(String filename) { checkPermission(new FilePermission(filename, "read")); }
checkPermission(new FilePermission(filename, "read"));
if (desc == null) throw new NullPointerException(); checkPermission(new RuntimePermission("readFileDescriptor"));
public void checkRead(String filename) { checkPermission(new FilePermission(filename, "read")); }
for (Iterator i = provider ().charsets (); i.hasNext (); )
CharsetProvider[] providers = providers(); for (int j = 0; j < providers.length; j++)
public static SortedMap availableCharsets () { TreeMap charsets = new TreeMap (String.CASE_INSENSITIVE_ORDER); for (Iterator i = provider ().charsets (); i.hasNext (); ) { Charset cs = (Charset) i.next (); charsets.put (cs.name (), cs); } return Collections.unmodifiableSortedMap (charset...
Charset cs = (Charset) i.next (); charsets.put (cs.name (), cs); }
for (Iterator i = providers[j].charsets(); i.hasNext(); ) { Charset cs = (Charset) i.next(); charsets.put(cs.name(), cs); } }
public static SortedMap availableCharsets () { TreeMap charsets = new TreeMap (String.CASE_INSENSITIVE_ORDER); for (Iterator i = provider ().charsets (); i.hasNext (); ) { Charset cs = (Charset) i.next (); charsets.put (cs.name (), cs); } return Collections.unmodifiableSortedMap (charset...
return provider ().charsetForName (charsetName);
Charset cs = null; CharsetProvider[] providers = providers(); for (int i = 0; i < providers.length; i++) { cs = providers[i].charsetForName(charsetName); if (cs != null) break;
private static Charset charsetForName (String charsetName) { checkName (charsetName); return provider ().charsetForName (charsetName); }
return cs; }
private static Charset charsetForName (String charsetName) { checkName (charsetName); return provider ().charsetForName (charsetName); }