rem
stringlengths
0
477k
add
stringlengths
0
313k
context
stringlengths
6
599k
{ 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); }
{ Color saved = g.getColor(); g.setColor(Color.BLACK); for (int i = 0; i < 4; i++) g.drawLine(x + i, y + i, x + i, y + 7 - i); g.setColor(saved); }
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,...
block.width - margin.left - margin.right - border.left - border.right, block.height - margin.top - border.top - border.bottom - margin.bottom);
width - margin.left - margin.right - border.left - border.right, height - margin.top - border.top - border.bottom - margin.bottom);
public static void paint(Context c, Box block) { // don't draw if the backgrounds are turned off if (!Configuration.isTrue("xr.renderer.draw.backgrounds", true)) { return; } int width = block.getWidth(); int height = block.getHeight(); Border border = c.getCurren...
if ( weight != null && weight == IdentValue.BOLD ) {
if ( weight != null && ( weight == IdentValue.BOLD || weight == IdentValue.FONT_WEIGHT_700 || weight == IdentValue.FONT_WEIGHT_800 || weight == IdentValue.FONT_WEIGHT_900 )) {
protected Font createFont( Context c, Font root_font, float size, IdentValue weight, IdentValue style, IdentValue variant ) { //Uu.p("creating font: " + root_font + " size = " + size + // " weight = " + weight + " style = " + style + " variant = " + variant); int font_const = Font.PLAIN; ...
{
public static CertPathValidator getInstance(String algorithm) throws NoSuchAlgorithmException { Provider[] p = Security.getProviders(); for (int i = 0; i < p.length; i++) { try { return getInstance(algorithm, p[i]); } catch (NoSuchAlgorithmException e) ...
catch (NoSuchAlgorithmException e)
catch (NoSuchAlgorithmException x)
public static CertPathValidator getInstance(String algorithm) throws NoSuchAlgorithmException { Provider[] p = Security.getProviders(); for (int i = 0; i < p.length; i++) { try { return getInstance(algorithm, p[i]); } catch (NoSuchAlgorithmException e) ...
}
lastException = x;
public static CertPathValidator getInstance(String algorithm) throws NoSuchAlgorithmException { Provider[] p = Security.getProviders(); for (int i = 0; i < p.length; i++) { try { return getInstance(algorithm, p[i]); } catch (NoSuchAlgorithmException e) ...
if (lastException != null) throw lastException;
public static CertPathValidator getInstance(String algorithm) throws NoSuchAlgorithmException { Provider[] p = Security.getProviders(); for (int i = 0; i < p.length; i++) { try { return getInstance(algorithm, p[i]); } catch (NoSuchAlgorithmException e) ...
DocumentBuilder db = null;
DocumentBuilder db;
public void load(URL url) throws FactoryException { InputStream is = getInputStream(url); try { DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); dbf.setNamespaceAware(true); DocumentBuilder db = null; try { db = dbf.newDocume...
if (resolver != null) { String resolverClass = resolver.getAttribute("class"); if (resolverClass != null) { variableResolver = (VariableResolver) ClassLoaderUtil.loadClass(resolverClass, getClass()).newInstance(); } }
public void load(URL url) throws FactoryException { InputStream is = getInputStream(url); try { DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); dbf.setNamespaceAware(true); DocumentBuilder db = null; try { db = dbf.newDocume...
public ConnectionDelegate createConnectionDelegate(String username, String password, String clientConnectionId) throws JMSException
public ConnectionDelegate createConnectionDelegate(String username, String password) throws JMSException
public ConnectionDelegate createConnectionDelegate(String username, String password, String clientConnectionId) throws JMSException { log.debug("creating a new connection for user " + username); // authenticate the user serverPeer.getSecurit...
new ServerConnectionEndpoint(serverPeer, clientID, username, password, clientConnectionId);
new ServerConnectionEndpoint(serverPeer, clientID, username, password);
public ConnectionDelegate createConnectionDelegate(String username, String password, String clientConnectionId) throws JMSException { log.debug("creating a new connection for user " + username); // authenticate the user serverPeer.getSecurit...
serverPeer.registerConnection(clientConnectionId, endpoint);
public ConnectionDelegate createConnectionDelegate(String username, String password, String clientConnectionId) throws JMSException { log.debug("creating a new connection for user " + username); // authenticate the user serverPeer.getSecurit...
log.error("Caught JMSException", e);
public Object invoke(Invocation invocation) throws Throwable { if (log.isTraceEnabled()) { log.trace("handling " + ((MethodInvocation)invocation).getMethod().getName()); } try { return invocation.invokeNext(); } catch(NotYetImplementedException e) { // TODO get rid of ...
public Class getCategory()
public final Class getCategory()
public Class getCategory() { return JobSheets.class; }
public String getName()
public final String getName()
public String getName() { return "job-sheets"; }
int mxw = root.getSharedContext().getMaxWidth();
private void startLayoutLoop() throws InterruptedException { while (true) { //Uu.p("waiting for a layout event"); ReflowEvent evt = root.queue.waitForNextLayoutEvent(); if (evt == null) { return; } Uu.p("got a layout event: " + evt); ...
producerConnection.close(); consumerConnection.close();
public void tearDown() throws Exception { // TODO uncomment these// producerConnection.close();// consumerConnection.close(); ServerManagement.undeployQueue("Queue"); ServerManagement.stopInVMServer(); super.tearDown(); }
verifyCache();
public GraphicsDevice getDefaultScreenDevice() { final String devId = (String)AccessController.doPrivileged(new GetPropertyAction("jnode.awt.device", "fb0")); if ((defaultDevice == null) || !devId.equals(defaultDevice.getIDstring())){ final GraphicsDevice[] devs = getScreenDevices(); for (int i = 0;(defaultDevic...
devices = new GraphicsDevice[devs.size()];
devices = new JNodeFrameBufferDevice[devs.size()];
public GraphicsDevice[] getScreenDevices() { if (devices == null) { final Collection devs = DeviceUtils.getDevicesByAPI(FrameBufferAPI.class); devices = new GraphicsDevice[devs.size()]; int idx = 0; for (Iterator i = devs.iterator(); i.hasNext(); idx++) { devices[idx] = new JNodeFrameBufferDevice((Device) ...
return Collections.EMPTY_LIST;
return Collections.emptyList();
public static Collection<Device> getDevicesByAPI(Class<? extends DeviceAPI> apiClass) { try { return getDeviceManager().getDevicesByAPI(apiClass); } catch (NameNotFoundException ex) { return Collections.EMPTY_LIST; } }
cancelMessageMethod = consumerDelegate.getMethod("cancelMessage", new Class[] { Long.TYPE });
cancelDeliveryMethod = consumerDelegate.getMethod("cancelDelivery", new Class[] { Long.TYPE });
public void setUp() throws Exception { super.setUp(); wf = new TestWireFormat(); Class sessionDelegate = SessionDelegate.class; Class consumerDelegate = ConsumerDelegate.class; Class connectionDelegate = ConnectionDelegate.class; sendMethod = sessionDeleg...
cancelMessagesMethod = consumerDelegate.getMethod("cancelMessages", new Class[] { List.class });
cancelDeliveriesMethod = consumerDelegate.getMethod("cancelDeliveries", new Class[] { List.class });
public void setUp() throws Exception { super.setUp(); wf = new TestWireFormat(); Class sessionDelegate = SessionDelegate.class; Class consumerDelegate = ConsumerDelegate.class; Class connectionDelegate = ConnectionDelegate.class; sendMethod = sessionDeleg...
return 0;
return delegate.getIconHeight();
public int getIconHeight() { return 0; }
return 0;
return delegate.getIconWidth();
public int getIconWidth() { return 0; }
delegate.paintIcon(c, g, x, y);
public void paintIcon(Component c, Graphics g, int x, int y) { }
public BigInteger getX();
BigInteger getX();
public BigInteger getX();
stmt = prepareStatementWithKeys(conn, sql, entryId);
if (generatedKeys) { stmt = conn.prepareStatement(sql, new String[] {entryId}); } else { stmt = conn.prepareStatement(sql); }
public WorkflowEntry createEntry(String workflowName) throws StoreException { boolean generatedKeys = GENERATED.equals(entrySequence); Connection conn = null; PreparedStatement stmt = null; try { conn = getConnection(); String sql = "INSERT INTO " + entryTable + " (...
private static PreparedStatement prepareStatementWithKeys(Connection conn, String sql, String pkColumnName) throws SQLException, StoreException {
private static PreparedStatement prepareStatementWithKeys(Connection conn, String sql, String pkColumnName) throws SQLException {
private static PreparedStatement prepareStatementWithKeys(Connection conn, String sql, String pkColumnName) throws SQLException, StoreException { return conn.prepareStatement(sql, new String[] {pkColumnName}); }
{ JLabel b = (JLabel)c; Dimension d = BasicGraphicsUtils.getPreferredSize(b, gap, b.getText(), b.getIcon(), b.getVerticalAlignment(), b.getHorizontalAlignment(), b.getHorizontalTextPosition(), b.getVerticalTextPosition()); System.out.println("JLABEL->^^^^^^^^^^^^^^^^^^^^^^ BASIC-PREF="+d + ",T="+b.getText()); return ...
{ JLabel lab = (JLabel)c; Rectangle vr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle tr = new Rectangle(); Insets insets = lab.getInsets(); FontMetrics fm = lab.getToolkit().getFontMetrics(lab.getFont()); layoutCL(lab, fm, lab.getText(), lab.getIcon(), vr, ir, tr); Rectangle cr = tr.union(ir); return new...
public Dimension getPreferredSize(JComponent c) { JLabel b = (JLabel)c; Dimension d = BasicGraphicsUtils.getPreferredSize(b, gap, b.getText(), b.getIcon(), b.getVerticalAlignment(), b.getHorizontalAlignment(), b.getHorizontalTextPosition(), b.getVerticalT...
public void installUI(final JComponent c) { super.installUI(c); foreground = new Color(0,0,250); }
public void installUI(JComponent c) { super.installUI(c); if (c instanceof JLabel) { JLabel l = (JLabel) c; installComponents(l); installDefaults(l); installListeners(l); installKeyboardActions(l); } }
public void installUI(final JComponent c) { super.installUI(c); foreground = new Color(0,0,250); }
Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle();
Font saved_font = g.getFont();
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
Font f = c.getFont();
Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle();
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
g.setFont(f);
Font f = c.getFont();
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
FontMetrics fm = SwingUtilities.getFontMetrics(f);
g.setFont(f); FontMetrics fm = g.getFontMetrics(f);
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
Insets i = c.getInsets();
vr = SwingUtilities.calculateInnerArea(c, vr);
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
Rectangle bound = c.getBounds(); System.out.println("BOUND=" + bound + ", insets = " + i + ", " + b.getText()); if (bound == null) { vr.x = i.left; vr.y = i.top; vr.width = b.getWidth() - (i.right + i.left); vr.height = b.getHeight() - (i.bottom + i.top); } else { vr.x = bound.x + i.left; vr.y =...
if (vr.width < 0) vr.width = 0; if (vr.height < 0) vr.height = 0;
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
System.out.println(" VIEW-RECT-JLABEL="+vr+", insets="+i+", FONTM="+fm);
Icon icon = (b.isEnabled()) ? b.getIcon() : b.getDisabledIcon();
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
String text = SwingUtilities.layoutCompoundLabel(c, fm, b.getText(), b.getIcon(), b.getVerticalAlignment(), b.getHorizontalAlignment(), b.getVerticalTextPosition(), b.getHorizontalTextPosition(), vr, ir, tr, gap);
String text = layoutCL(b, fm, b.getText(), icon, vr, ir, tr); if (b.isOpaque()) { g.setColor(b.getBackground()); g.fillRect(vr.x, vr.y, vr.width, vr.height); }
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
paintIcon(g, c, ir); paintText(g, c, tr, b.getText()); paintFocus(g, c, vr, tr, ir); }
if (icon != null) icon.paintIcon(b, g, ir.x, ir.y); if (b.isEnabled()) paintEnabledText(b, g, text, tr.x, tr.y + fm.getAscent()); else paintDisabledText(b, g, text, tr.x, tr.y + fm.getAscent()); g.setFont(saved_font); }
public void paint(Graphics g, JComponent c) { JLabel b = (JLabel) c; Rectangle tr = new Rectangle(); Rectangle ir = new Rectangle(); Rectangle vr = new Rectangle(); Font f = c.getFont(); g.setFont(f); FontMetrics fm = SwingUtilities.getFontMetrics(f); Insets i = c.getInsets(); R...
private Object invokeCommon(Remote obj, Method method, Object[] params,
protected Object invokeCommon(Remote obj, Method method, Object[] params,
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " ...
ObjectOutputStream out; DataOutputStream dout; try { dout = conn.getDataOutputStream(); dout.writeByte(MESSAGE_CALL); out = conn.startObjectOutputStream(); objid.write(out); out.writeInt(opnum); out.writeLong(hash); Class clss[] = method.getParameterTypes(); for (int i = 0; i < clss.length; i++) ((RMIObjectOutputSt...
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " ...
0,
protected Message createMessage(byte i, boolean reliable) throws Exception { HashMap coreHeaders = generateFilledMap(true); HashMap jmsProperties = generateFilledMap(false); JBossBytesMessage m = new JBossBytesMessage(i, reliable, System.current...
ms = new PagingMessageStore("test-memory-store");
ms = new SimpleMessageStore("test-memory-store");
public void setUp() throws Exception { super.setUp(); ms = new PagingMessageStore("test-memory-store"); log.debug("setup done"); }
InputMap input = getInputMap(); ActionMap actions = getActionMap(); Container parent = getParent(); while ((parent != null) && (parent instanceof JComponent)) { JComponent jParent = (JComponent) parent; InputMap parentInput = jParent.getInputMap(); ActionMap parentAction = jParent.getActionMap(); KeyStroke[] ikeys = ...
public void addNotify() { super.addNotify(); // let parents inherit the keybord mapping InputMap input = getInputMap(); ActionMap actions = getActionMap(); Container parent = getParent(); while ((parent != null) && (parent instanceof JComponent)) { JComponent jParent = (JComponent) pare...
firePropertyChange("ancestor", null, parent);
firePropertyChange("ancestor", null, getParent());
public void addNotify() { super.addNotify(); // let parents inherit the keybord mapping InputMap input = getInputMap(); ActionMap actions = getActionMap(); Container parent = getParent(); while ((parent != null) && (parent instanceof JComponent)) { JComponent jParent = (JComponent) pare...
inputMap_whenInFocusedWindow = new InputMap();
inputMap_whenInFocusedWindow = new ComponentInputMap(this);
public final InputMap getInputMap(int condition) { enableEvents(AWTEvent.KEY_EVENT_MASK); switch (condition) { case WHEN_FOCUSED: if (inputMap_whenFocused == null) inputMap_whenFocused = new InputMap(); return inputMap_whenFocused; case WHEN_ANCESTOR_OF_FOCUSED_COMPONENT: ...
return false;
return paintingTile;
public boolean isPaintingTile() { return false; }
paintComponent(g); paintBorder(g); paintChildren(g); Rectangle clip = g.getClipBounds();
Graphics g2 = getComponentGraphics(g); paintComponent(g2); paintBorder(g2); paintChildren(g2); Rectangle clip = g2.getClipBounds();
public void paint(Graphics g) { RepaintManager rm = RepaintManager.currentManager(this); // We do a little stunt act here to switch on double buffering if it's // not already on. If we are not already doublebuffered, then we jump // into the method paintDoubleBuffered, which turns on the double buffer ...
for (int i = children.length - 1; i >= 0; --i)
int startIndex = children.length - 1; if (! isOptimizedDrawingEnabled())
protected void paintChildren(Graphics g) { Shape originalClip = g.getClip(); Rectangle inner = SwingUtilities.calculateInnerArea(this, rectCache); g.clipRect(inner.x, inner.y, inner.width, inner.height); Component[] children = getComponents(); for (int i = children.length - 1; i >= 0; --i) { ...
Rectangle clip = g.getClipBounds(); for (int i = 0; i < children.length; i++) { Rectangle childBounds = children[i].getBounds(); if (children[i].isOpaque() && SwingUtilities.isRectangleContainingRectangle(childBounds, g.getClipBounds())) { startIndex = i; break; } } } paintingTile = true; for (int i = startIndex; i >...
protected void paintChildren(Graphics g) { Shape originalClip = g.getClip(); Rectangle inner = SwingUtilities.calculateInnerArea(this, rectCache); g.clipRect(inner.x, inner.y, inner.width, inner.height); Component[] children = getComponents(); for (int i = children.length - 1; i >= 0; --i) { ...
ui.update(getComponentGraphics(g2), this);
ui.update(g2, this);
protected void paintComponent(Graphics g) { if (ui != null) { Graphics g2 = g; if (!(g instanceof Graphics2D)) g2 = g.create(); ui.update(getComponentGraphics(g2), this); if (!(g instanceof Graphics2D)) g2.dispose(); } }
}
void paintDoubleBuffered(Graphics g) { Rectangle r = g.getClipBounds(); if (r == null) r = new Rectangle(0, 0, getWidth(), getHeight()); RepaintManager rm = RepaintManager.currentManager(this); // Paint on the offscreen buffer. Image buffer = rm.getOffscreenBuffer(this, getWidth(), getHei...
if (processKeyBinding(KeyStroke.getKeyStrokeForEvent(e), e, WHEN_FOCUSED, e.getID() == KeyEvent.KEY_PRESSED))
KeyStroke keyStroke = KeyStroke.getKeyStrokeForEvent(e); boolean pressed = e.getID() == KeyEvent.KEY_PRESSED; if (processKeyBinding(keyStroke, e, WHEN_FOCUSED, pressed)) {
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
else if (processKeyBinding(KeyStroke.getKeyStrokeForEvent(e), e, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, e.getID() == KeyEvent.KEY_PRESSED))
return; } else if (processKeyBinding (keyStroke, e, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, pressed)) {
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
else {
return; }
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
Container current = this; while ((current = current.getParent()) instanceof JComponent)
Container current = getParent(); while (current != null)
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
if (((JComponent)current).processKeyBinding (KeyStroke.getKeyStrokeForEvent(e), e, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, e.getID() == KeyEvent.KEY_PRESSED))
if ((current instanceof JComponent) && ((JComponent)current).processKeyBinding (keyStroke, e,WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, pressed))
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
break;
return;
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
if (current instanceof Window || current instanceof Applet || current instanceof JInternalFrame)
if (current instanceof Window || current instanceof Applet)
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
if (e.isConsumed())
if (current == null || e.isConsumed())
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
}
if (KeyboardManager.getManager().processKeyStroke(current, keyStroke, e)) e.consume();
protected void processKeyEvent(KeyEvent e) { // let the AWT event processing send KeyEvents to registered listeners super.processKeyEvent(e); processComponentKeyEvent(e); if (e.isConsumed()) return; // Input maps are checked in this order: // 1. The focused component's WHEN_FOCUSED map is chec...
InputMap input = getInputMap(); ActionMap actions = getActionMap(); Container parent = getParent(); while ((parent != null) && (parent instanceof JComponent)) { JComponent jParent = (JComponent) parent; InputMap parentInput = jParent.getInputMap(); ActionMap parentAction = jParent.getActionMap(); KeyStroke[] ikeys = ...
KeyboardManager.getManager().clearBindingsForComp(this);
public void removeNotify() { super.removeNotify(); // let parents inherit the keybord mapping InputMap input = getInputMap(); ActionMap actions = getActionMap(); Container parent = getParent(); while ((parent != null) && (parent instanceof JComponent)) { JComponent jParent = (JComponent...
firePropertyChange("ancestor", parent, null);
firePropertyChange("ancestor", getParent(), null);
public void removeNotify() { super.removeNotify(); // let parents inherit the keybord mapping InputMap input = getInputMap(); ActionMap actions = getActionMap(); Container parent = getParent(); while ((parent != null) && (parent instanceof JComponent)) { JComponent jParent = (JComponent...
inputMap_whenInFocusedWindow = map;
if (map != null && !(map instanceof ComponentInputMap)) throw new IllegalArgumentException("WHEN_IN_FOCUSED_WINDOW " + "InputMap must be a ComponentInputMap"); inputMap_whenInFocusedWindow = (ComponentInputMap)map;
public final void setInputMap(int condition, InputMap map) { enableEvents(AWTEvent.KEY_EVENT_MASK); switch (condition) { case WHEN_FOCUSED: inputMap_whenFocused = map; break; case WHEN_ANCESTOR_OF_FOCUSED_COMPONENT: inputMap_whenAncestorOfFocused = map; break; ca...
else maximumSize = null;
public void setMaximumSize(Dimension max) { Dimension oldMaximumSize = maximumSize; maximumSize = new Dimension(max); firePropertyChange("maximumSize", oldMaximumSize, maximumSize); }
else minimumSize = null;
public void setMinimumSize(Dimension min) { Dimension oldMinimumSize = minimumSize; minimumSize = new Dimension(min); firePropertyChange("minimumSize", oldMinimumSize, minimumSize); }
else preferredSize = null;
public void setPreferredSize(Dimension pref) { Dimension oldPreferredSize = preferredSize; preferredSize = new Dimension(pref); firePropertyChange("preferredSize", oldPreferredSize, preferredSize); }
Border margin = block.getMarginWidth(c, width);
Border margin = block.getMarginWidth();
public static void paint(Context c, Box block) { // don't draw if the backgrounds are turned off if (!Configuration.isTrue("xr.renderer.draw.backgrounds", true)) { return; } int width = block.getWidth(); int height = block.getHeight(); if (block.getState() != Box...
String name = JOptionPane.showInputDialog("Create Workflow", "Please specify a new workflow name");
String name = JOptionPane.showInputDialog(ResourceManager.getString("createflow"), ResourceManager.getString("createflow.long"));
public void actionPerformed(ActionEvent e) { String name = JOptionPane.showInputDialog("Create Workflow", "Please specify a new workflow name"); if(name==null) return; try { if(currentWorkspace.getWorkflow(name)!=null) { JOptionPane.showMessageDialog((Component)e.getSource(), "A workflow...
JOptionPane.showMessageDialog((Component)e.getSource(), "A workflow with the name " + name + " already exists.", "Error adding workflow", JOptionPane.ERROR_MESSAGE);
JOptionPane.showMessageDialog((Component)e.getSource(), ResourceManager.getString("createflow.error", new Object[]{name}), ResourceManager.getString("createflow.error"), JOptionPane.ERROR_MESSAGE);
public void actionPerformed(ActionEvent e) { String name = JOptionPane.showInputDialog("Create Workflow", "Please specify a new workflow name"); if(name==null) return; try { if(currentWorkspace.getWorkflow(name)!=null) { JOptionPane.showMessageDialog((Component)e.getSource(), "A workflow...
d.getReference().setRedelivered(true); d.getReference().getMessage().setRedelivered(true);
public boolean cancel(Delivery d) throws Throwable { if (log.isTraceEnabled()) { log.trace("cancel " + d); } d.getReference().setRedelivered(true); d.getReference().getMessage().setRedelivered(true); state.cancel(d); if (log.isTraceEnabled()) { log.trace(this + " ma...
Iterator iter = deliveries.iterator(); while (iter.hasNext()) { ref.incrementDeliveryCount(); iter.next(); }
private Set getDeliveries(Receiver receiver, MessageReference ref) { Set deliveries = Collections.EMPTY_SET; if (receiver == null) { if (log.isTraceEnabled()){ log.trace(this + " passing " + ref + " to router " + router); } deliveries = router.handle(this, ref, null); } ...
return push(null, ref);
Delivery del = push(null, ref); if (del == null) { ref.release(); } return del;
public Delivery handle(DeliveryObserver sender, Routable r, Transaction tx) { if (r == null) { return null; } if (log.isTraceEnabled()){ log.trace(this + " handles " + r + (tx == null ? " non-transactionally" : " in transaction: " + tx) ); } MessageReference ref = ref(r); if (...
ref = ms.reference(r);
if (r.isReference()) { ref = ms.reference((MessageReference)r); } else { ref = ms.reference((Message)r); }
protected MessageReference ref(Routable r) { MessageReference ref = null; //Convert to reference try { ref = ms.reference(r); return ref; } catch (Throwable t) { log.error("Failed to reference routable", t); return null; } }
catch (Throwable t)
catch (Exception e)
protected MessageReference ref(Routable r) { MessageReference ref = null; //Convert to reference try { ref = ms.reference(r); return ref; } catch (Throwable t) { log.error("Failed to reference routable", t); return null; } }
log.error("Failed to reference routable", t);
log.error("Failed to reference routable", e);
protected MessageReference ref(Routable r) { MessageReference ref = null; //Convert to reference try { ref = ms.reference(r); return ref; } catch (Throwable t) { log.error("Failed to reference routable", t); return null; } }
return ((JBossMessage)m).doClone();
copy = ((JBossMessage)m).doClone();
public static JBossMessage copy(Message m) throws JMSException { if (m instanceof JBossMessage) { // more efficient than duplicating a foreign message return ((JBossMessage)m).doClone(); } JBossMessage copy = null; if (m instanceof BytesMessage) { copy = new JB...
JBossMessage copy = null; if (m instanceof BytesMessage)
else if (m instanceof BytesMessage)
public static JBossMessage copy(Message m) throws JMSException { if (m instanceof JBossMessage) { // more efficient than duplicating a foreign message return ((JBossMessage)m).doClone(); } JBossMessage copy = null; if (m instanceof BytesMessage) { copy = new JB...
else
else if (m instanceof Message)
public static JBossMessage copy(Message m) throws JMSException { if (m instanceof JBossMessage) { // more efficient than duplicating a foreign message return ((JBossMessage)m).doClone(); } JBossMessage copy = null; if (m instanceof BytesMessage) { copy = new JB...
copy = new JBossMessage(m);
copy = new JBossMessage((Message)m);
public static JBossMessage copy(Message m) throws JMSException { if (m instanceof JBossMessage) { // more efficient than duplicating a foreign message return ((JBossMessage)m).doClone(); } JBossMessage copy = null; if (m instanceof BytesMessage) { copy = new JB...
protected Rectangle getContentAreaEdge(int left, int top, CssContext cssCtx) {
public Rectangle getContentAreaEdge(int left, int top, CssContext cssCtx) {
protected Rectangle getContentAreaEdge(int left, int top, CssContext cssCtx) { RectPropertySet margin = getStyle().getMarginWidth(cssCtx); RectPropertySet border = getStyle().getCalculatedStyle().getBorder(cssCtx); RectPropertySet padding = getStyle().getPaddingWidth(cssCtx); Rec...
put("KeyPairGenerator.DSA", gnu.java.security.provider.DSAKeyPairGenerator.class.getName()); put("KeyPairGenerator.DiffieHellman", DiffieHellmanKeyPairGeneratorImpl.class.getName ());
put("KeyPairGenerator.DSA", gnu.java.security.provider.DSAKeyPairGenerator.class.getName());
public Object run() { // Note that all implementation class names are referenced by using // Class.getName(). That way when we staticly link the Gnu provider // we automatically get all the implementation classes. // Signature put("Signature.SHA1withDSA", gnu.jav...
put("Alg.Alias.KeyPairGenerator.OID.1.2.840.10040.4.1", "DSA"); put("Alg.Alias.KeyPairGenerator.1.2.840.10040.4.1", "DSA"); put("Alg.Alias.KeyPairGenerator.1.3.14.3.2.12", "DSA"); put("Alg.Alias.KeyPairGenerator.DH", "DiffieHellman");
put("Alg.Alias.KeyPairGenerator.OID.1.2.840.10040.4.1", "DSA"); put("Alg.Alias.KeyPairGenerator.1.2.840.10040.4.1", "DSA"); put("Alg.Alias.KeyPairGenerator.1.3.14.3.2.12", "DSA");
public Object run() { // Note that all implementation class names are referenced by using // Class.getName(). That way when we staticly link the Gnu provider // we automatically get all the implementation classes. // Signature put("Signature.SHA1withDSA", gnu.jav...
put("KeyFactory.DiffieHellman", DiffieHellmanKeyFactoryImpl.class.getName()); put("Alg.Alias.KeyFactory.DH", "DiffieHellman");
put("MessageDigest.SHA", gnu.java.security.provider.SHA.class.getName()); put("MessageDigest.MD5", gnu.java.security.provider.MD5.class.getName());
public Object run() { // Note that all implementation class names are referenced by using // Class.getName(). That way when we staticly link the Gnu provider // we automatically get all the implementation classes. // Signature put("Signature.SHA1withDSA", gnu.jav...
put("MessageDigest.SHA", gnu.java.security.provider.SHA.class.getName()); put("MessageDigest.MD5", gnu.java.security.provider.MD5.class.getName()); put("Alg.Alias.MessageDigest.SHA1", "SHA"); put("Alg.Alias.MessageDigest.SHA-1", "SHA");
put("Alg.Alias.MessageDigest.SHA1", "SHA"); put("Alg.Alias.MessageDigest.SHA-1", "SHA");
public Object run() { // Note that all implementation class names are referenced by using // Class.getName(). That way when we staticly link the Gnu provider // we automatically get all the implementation classes. // Signature put("Signature.SHA1withDSA", gnu.jav...
AccessController.doPrivileged(new PrivilegedAction() { public Object run() { System.setProperty("dns.server", "127.0.0.1"); System.setProperty("dns.search", "localdomain"); return null; } });
public static Resolver getInstance() { if (res == null) { res = new ResolverImpl(); } return res; }
public Object run() throws UnknownHostException { ProtocolAddress[] protocolAddresses; protocolAddresses = getFromHostsFile(hostname); if (protocolAddresses != null) { return protocolAddresses; } Lookup.setDefaultResolver(resolver); final Lookup lookup; try { lookup = new Lookup(hostname); } catch (TextParseExceptio...
public Object run() { System.setProperty("dns.server", "127.0.0.1"); System.setProperty("dns.search", "localdomain"); return null; }
public Object run() throws UnknownHostException { ProtocolAddress[] protocolAddresses; protocolAddresses = getFromHostsFile(hostname); if (protocolAddresses != null) { return protocolAddresses; } Lookup.setDefaultR...
public Element getDefaultSecurityConfig() throws Exception
public String getDefaultSecurityConfig() throws Exception
public Element getDefaultSecurityConfig() throws Exception { return serverPeer.getDefaultSecurityConfig(); }
return serverPeer.getDefaultSecurityConfig();
return serverPeer.getDefaultSecurityConfig().toString();
public Element getDefaultSecurityConfig() throws Exception { return serverPeer.getDefaultSecurityConfig(); }
public void setDefaultSecurityConfig(Element config) throws Exception
public void setDefaultSecurityConfig(String config) throws Exception
public void setDefaultSecurityConfig(Element config) throws Exception { serverPeer.setDefaultSecurityConfig(config); }
serverPeer.setDefaultSecurityConfig(config);
Element element = ServerManagement.toElement(config); serverPeer.setDefaultSecurityConfig(element);
public void setDefaultSecurityConfig(Element config) throws Exception { serverPeer.setDefaultSecurityConfig(config); }
public void setSecurityConfig(String destName, Element config) throws Exception
public void setSecurityConfig(String destName, String config) throws Exception
public void setSecurityConfig(String destName, Element config) throws Exception { serverPeer.setSecurityConfig(destName, config); }
serverPeer.setSecurityConfig(destName, config);
Element element = ServerManagement.toElement(config); serverPeer.setSecurityConfig(destName, element);
public void setSecurityConfig(String destName, Element config) throws Exception { serverPeer.setSecurityConfig(destName, config); }
serverPeer.setDefaultSecurityConfig(toElement(defaultSecurityConfig));
serverPeer.setDefaultSecurityConfig(ServerManagement.toElement(defaultSecurityConfig));
public synchronized void start(String containerConfig) throws Exception { if (isStarted()) { return; } log.debug("starting service container"); sc = new ServiceContainer(containerConfig, null); sc.start(); log.debug("starting JMS server"); serverPeer = new ServerPeer...
int firstPos = pos; while (true)
int crtSize = receivers.size(); receiversCopy = new ArrayList(crtSize); receiversCopy.addAll(receivers); if (pos >= crtSize)
public Set handle(DeliveryObserver observer, Routable routable, Transaction tx) { Set deliveries = new HashSet(); boolean selectorRejected = false; synchronized(receivers) { if (receivers.isEmpty()) { return deliveries; } int first...
Receiver receiver = (Receiver)receivers.get(pos); try
pos = 0; } firstPos = pos; } while (true) { Receiver receiver = (Receiver)receiversCopy.get(pos); try { Delivery d = receiver.handle(observer, routable, tx); if (trace) { log.trace("receiver " + receiver + " handled " + routable + " and returned " + d); } if (d != null && !d.isCancelled())
public Set handle(DeliveryObserver observer, Routable routable, Transaction tx) { Set deliveries = new HashSet(); boolean selectorRejected = false; synchronized(receivers) { if (receivers.isEmpty()) { return deliveries; } int first...
Delivery d = receiver.handle(observer, routable, tx); if (trace) { log.trace("receiver " + receiver + " handled " + routable + " and returned " + d); } if (d != null && !d.isCancelled())
if (d.isSelectorAccepted())
public Set handle(DeliveryObserver observer, Routable routable, Transaction tx) { Set deliveries = new HashSet(); boolean selectorRejected = false; synchronized(receivers) { if (receivers.isEmpty()) { return deliveries; } int first...
if (d.isSelectorAccepted()) { deliveries.add(d); incPos(); break; } else { selectorRejected = true; }
deliveries.add(d); incPos(); break; } else { selectorRejected = true;
public Set handle(DeliveryObserver observer, Routable routable, Transaction tx) { Set deliveries = new HashSet(); boolean selectorRejected = false; synchronized(receivers) { if (receivers.isEmpty()) { return deliveries; } int first...
catch(Throwable t) { log.error("The receiver " + receiver + " is broken", t); } incPos(); if (pos == firstPos) { break; }
} catch(Throwable t) { log.error("The receiver " + receiver + " is broken", t); } incPos(); if (pos == firstPos) { break;
public Set handle(DeliveryObserver observer, Routable routable, Transaction tx) { Set deliveries = new HashSet(); boolean selectorRejected = false; synchronized(receivers) { if (receivers.isEmpty()) { return deliveries; } int first...
if (pos == receivers.size())
if (pos >= receivers.size())
protected void incPos() { pos++; //Wrap around if (pos == receivers.size()) { pos = 0; } }