rem
stringlengths
0
477k
add
stringlengths
0
313k
context
stringlengths
6
599k
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_NON_PERSISTENT_MESSAGES, 100, 33), new TransactionalReceiver(sessReceive, cons, NUM_NON_PERSISTENT_MESSAGES, 100, 67, true) };
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_PERSISTENT_MESSAGES, 100, 33), new TransactionalReceiver(sessReceive, cons, NUM_PERSISTENT_MESSAGES, 100, 67, true) };
public void test_Simple_XP_LT() throws Exception { Connection conn1 = cf.createConnection(); Connection conn2 = cf.createConnection(); conn2.start(); XASession sessSend = ((XAConnection)conn1).createXASession(); Session sessReceive = conn2.createSession(true, Session.SESSION_TRANSACT...
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_NON_PERSISTENT_MESSAGES, 100, 33), new Transactional2PCReceiver(sessReceive, cons, NUM_NON_PERSISTENT_MESSAGES, 100, 67, true) };
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_PERSISTENT_MESSAGES, 100, 33), new Transactional2PCReceiver(sessReceive, cons, NUM_PERSISTENT_MESSAGES, 100, 67, true) };
public void test_Simple_XP_LX() throws Exception { Connection conn1 = cf.createConnection(); Connection conn2 = cf.createConnection(); conn2.start(); XASession sessSend = ((XAConnection)conn1).createXASession(); XASession sessReceive = ((XAConnection)conn2).createXASession(); ...
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_NON_PERSISTENT_MESSAGES, 100, 33), new Receiver(sessReceive, cons, NUM_NON_PERSISTENT_MESSAGES, false) };
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_PERSISTENT_MESSAGES, 100, 33), new Receiver(sessReceive, cons, NUM_PERSISTENT_MESSAGES, false) };
public void test_Simple_XP_NLA() throws Exception { Connection conn1 = cf.createConnection(); Connection conn2 = cf.createConnection(); conn2.start(); XASession sessSend = ((XAConnection)conn1).createXASession(); Session sessReceive = conn2.createSession(false, Session.AUTO_ACKNOWLED...
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_NON_PERSISTENT_MESSAGES, 100, 33), new RecoveringReceiver(sessReceive, cons, NUM_NON_PERSISTENT_MESSAGES, 100, 67, false) };
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_PERSISTENT_MESSAGES, 100, 33), new RecoveringReceiver(sessReceive, cons, NUM_PERSISTENT_MESSAGES, 100, 67, false) };
public void test_Simple_XP_NLCA() throws Exception { Connection conn1 = cf.createConnection(); Connection conn2 = cf.createConnection(); conn2.start(); XASession sessSend = ((XAConnection)conn1).createXASession(); Session sessReceive = conn2.createSession(false, Session.CLIENT_ACKNOW...
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_NON_PERSISTENT_MESSAGES, 100, 33), new Receiver(sessReceive, cons, NUM_NON_PERSISTENT_MESSAGES, false) };
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_PERSISTENT_MESSAGES, 100, 33), new Receiver(sessReceive, cons, NUM_PERSISTENT_MESSAGES, false) };
public void test_Simple_XP_NLD() throws Exception { Connection conn1 = cf.createConnection(); Connection conn2 = cf.createConnection(); conn2.start(); XASession sessSend = ((XAConnection)conn1).createXASession(); Session sessReceive = conn2.createSession(false, Session.DUPS_OK_ACKNOW...
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_NON_PERSISTENT_MESSAGES, 100, 33), new TransactionalReceiver(sessReceive, cons, NUM_NON_PERSISTENT_MESSAGES, 100, 67, false) };
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_PERSISTENT_MESSAGES, 100, 33), new TransactionalReceiver(sessReceive, cons, NUM_PERSISTENT_MESSAGES, 100, 67, false) };
public void test_Simple_XP_NLT() throws Exception { Connection conn1 = cf.createConnection(); Connection conn2 = cf.createConnection(); conn2.start(); XASession sessSend = ((XAConnection)conn1).createXASession(); Session sessReceive = conn2.createSession(true, Session.SESSION_TRANSAC...
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_NON_PERSISTENT_MESSAGES, 100, 33), new Transactional2PCReceiver(sessReceive, cons, NUM_NON_PERSISTENT_MESSAGES, 100, 67, false) };
Runner[] runners = new Runner[] { new Transactional2PCSender("prod1", sessSend, prod, NUM_PERSISTENT_MESSAGES, 100, 33), new Transactional2PCReceiver(sessReceive, cons, NUM_PERSISTENT_MESSAGES, 100, 67, false) };
public void test_Simple_XP_NLX() throws Exception { Connection conn1 = cf.createConnection(); Connection conn2 = cf.createConnection(); conn2.start(); XASession sessSend = ((XAConnection)conn1).createXASession(); XASession sessReceive = ((XAConnection)conn2).createXASession(); ...
InvalidSelectorException exception = new InvalidSelectorException("The selector is invalid: " + sel); throw exception;
throw new InvalidSelectorException("The selector is invalid: " + sel);
public Selector(String sel) throws InvalidSelectorException { selector = sel; identifiers = new HashMap(); try { ISelectorParser bob = (ISelectorParser) parserClass.newInstance(); result = bob.parse(sel, identifiers); resultType = result.getClass(); } cat...
ref.acquireReference();
public void load() throws Exception { List refs = pm.messageRefs(storeID, channelID); Iterator iter = refs.iterator(); while (iter.hasNext()) { String messageID = (String)iter.next(); MessageReference ref = messageStore.getReference(messageID); messageRefs.addLast(...
outerBox.setStyle(new Style(c.getCurrentStyle(), 0, c));
outerBox.setStyle(new Style(c.getCurrentStyle(), 0));
public static Box layout(LayoutContext c, BlockBox outerBox, Content content) { boolean set_bfc = false; if (content instanceof TableContent) { } else { XRLog.layout(Level.WARNING, "Unsupported table type " + content.getClass().getName()); return null; } // i...
tableBox.setStyle(new Style(c.getCurrentStyle(), (float) oe.getWidth(), c));
tableBox.setStyle(new Style(c.getCurrentStyle(), (float) oe.getWidth()));
public static Box layout(LayoutContext c, BlockBox outerBox, Content content) { boolean set_bfc = false; if (content instanceof TableContent) { } else { XRLog.layout(Level.WARNING, "Unsupported table type " + content.getClass().getName()); return null; } // i...
cell.setStyle(new Style(c.getCurrentStyle(), (float) c.getExtents().width, c));
cell.setStyle(new Style(c.getCurrentStyle(), (float) c.getExtents().width));
private static CellBox layoutCell(LayoutContext c, CellBox cell, Content content, boolean fixed, TableBox table, int col) { //OK, first set up the current style. All depends on this... CascadedStyle pushed = content.getStyle(); if (pushed != null) { c.pushStyle(pushed); } ...
row.setStyle(new Style(c.getCurrentStyle(), (float) oe.getWidth(), c));
row.setStyle(new Style(c.getCurrentStyle(), (float) oe.getWidth()));
private static RowBox layoutRow(LayoutContext c, TableRowContent tableRowContent, TableBox table, boolean fixed, int borderSpacingHorizontal, int borderSpacingVertical) { // copy the extents Rectangle oe = c.getExtents(); c.setExtents(new Rectangle(oe)); RowBox row = new RowBox(); ...
ms = new PagingMessageStore("s20");
ms = new SimpleMessageStore("s20");
public void setUp() throws Exception { super.setUp(); tl = new JDBCPersistenceManager(sc.getDataSource(), sc.getTransactionManager()); tl.start(); ms = new PagingMessageStore("s20"); tr.start(tl); channel = new CoreDurableSubscription(123, "clientid123", "testDurableSubscription", ...
keyedCallbacks = new ArrayList();
Transaction(long id) { this.id = id; state = STATE_ACTIVE; callbacks = new ArrayList(); keyedCallbackMap = new HashMap(); }
callbacks.add(callback);
keyedCallbacks.add(callback);
public void addKeyedCallback(TxCallback callback, Object key) { callbacks.add(callback); keyedCallbackMap.put(key, callback); }
Iterator iter = callbacks.iterator();
List cb = new ArrayList(callbacks); cb.addAll(keyedCallbacks); Iterator iter = cb.iterator();
public void commit() throws Exception { if (state == STATE_ROLLBACK_ONLY) { throw new TransactionException("Transaction marked rollback only, cannot commit"); } if (trace) { log.trace("executing before commit hooks " + this); } boolean onePhase = state != STATE_PREPARED; ...
iter = callbacks.iterator();
iter = cb.iterator();
public void commit() throws Exception { if (state == STATE_ROLLBACK_ONLY) { throw new TransactionException("Transaction marked rollback only, cannot commit"); } if (trace) { log.trace("executing before commit hooks " + this); } boolean onePhase = state != STATE_PREPARED; ...
keyedCallbacks = null;
public void commit() throws Exception { if (state == STATE_ROLLBACK_ONLY) { throw new TransactionException("Transaction marked rollback only, cannot commit"); } if (trace) { log.trace("executing before commit hooks " + this); } boolean onePhase = state != STATE_PREPARED; ...
Iterator iter = callbacks.iterator();
List cb = new ArrayList(callbacks); cb.addAll(keyedCallbacks); Iterator iter = cb.iterator();
public void prepare() throws Exception { if (trace) { log.trace("executing before prepare hooks " + this); } Iterator iter = callbacks.iterator(); while (iter.hasNext()) { TxCallback callback = (TxCallback)iter.next(); callback.beforePrepare(); } s...
iter = callbacks.iterator();
iter = cb.iterator();
public void prepare() throws Exception { if (trace) { log.trace("executing before prepare hooks " + this); } Iterator iter = callbacks.iterator(); while (iter.hasNext()) { TxCallback callback = (TxCallback)iter.next(); callback.beforePrepare(); } s...
Iterator iter = callbacks.iterator();
List cb = new ArrayList(callbacks); cb.addAll(keyedCallbacks); Iterator iter = cb.iterator();
public void rollback() throws Exception { if (trace) { log.trace("executing before rollback hooks " + this); } boolean onePhase = state != STATE_PREPARED; Iterator iter = callbacks.iterator(); while (iter.hasNext()) { TxCallback callback = (TxCallback)iter.next();...
iter = callbacks.iterator();
iter = cb.iterator();
public void rollback() throws Exception { if (trace) { log.trace("executing before rollback hooks " + this); } boolean onePhase = state != STATE_PREPARED; Iterator iter = callbacks.iterator(); while (iter.hasNext()) { TxCallback callback = (TxCallback)iter.next();...
keyedCallbacks = null;
public void rollback() throws Exception { if (trace) { log.trace("executing before rollback hooks " + this); } boolean onePhase = state != STATE_PREPARED; Iterator iter = callbacks.iterator(); while (iter.hasNext()) { TxCallback callback = (TxCallback)iter.next();...
g.setColor(graph.getBackground());
g.setColor(getBackground());
public void paint(Graphics g) { g.setColor(graph.getBackground()); //g.setXORMode(graph.getBackground()); if(preview) { Dimension d = getSize(); g.setColor(java.awt.Color.red); g.drawRect(1, 1, d.width - 3, d.height - 3); g.drawRect(2, 2, d.width - 5, d.height - 5)...
ICON.paintIcon(graph, g, 0, 0);
ICON.paintIcon(this, g, 0, 0);
public void paint(Graphics g) { g.setColor(graph.getBackground()); //g.setXORMode(graph.getBackground()); if(preview) { Dimension d = getSize(); g.setColor(java.awt.Color.red); g.drawRect(1, 1, d.width - 3, d.height - 3); g.drawRect(2, 2, d.width - 5, d.height - 5)...
Point2D location = getLocation(null); Rectangle2D bounds = new Rectangle2D.Double(location.getX() - WIDTH / 2, location.getY(), WIDTH, HEIGHT); return bounds;
Point2D location = getLocation(); return new Rectangle2D.Double(location.getX() - WIDTH / 2, location.getY(), WIDTH, HEIGHT);
public Rectangle2D getBounds() { Point2D location = getLocation(null); Rectangle2D bounds = new Rectangle2D.Double(location.getX() - WIDTH / 2, location.getY(), WIDTH, HEIGHT); //bounds.x = bounds.x - WIDTH / 2; //bounds.width = WIDTH; //bounds.height = HEIGHT; return bounds; }
Destination dest = (Destination)mi.getArguments()[0];
Message m = (Message)mi.getArguments()[0]; Destination dest = m.getJMSDestination();
public Object handleSend(Invocation invocation) throws Throwable { // anonymous producer -if destination is not null then write permissions required MethodInvocation mi = (MethodInvocation)invocation; Destination dest = (Destination)mi.getArguments()[0]; ProducerAdvised del = ...
return currentSteps;
return new ArrayList(currentSteps);
public List findCurrentSteps(long entryId) { List currentSteps = (List) currentStepsCache.get(new Long(entryId)); if (currentSteps == null) { currentSteps = new ArrayList(); currentStepsCache.put(new Long(entryId), currentSteps); } return currentSteps; }
return historySteps;
return new ArrayList(historySteps);
public List findHistorySteps(long entryId) { List historySteps = (List) historyStepsCache.get(new Long(entryId)); if (historySteps == null) { historySteps = new ArrayList(); historyStepsCache.put(new Long(entryId), historySteps); } return historySteps; }
else if ("getExceptionListener".equals(name)) { return mi.getMetaData(JMSAdvisor.JMS, JMSAdvisor.EXCEPTION_LISTENER); } else if ("setExceptionListener".equals(name)) { JMSInvocationHandler thisHandler = ((JMSMethodInvocation)invocation).getHandler(); thisHandler.getMetaData() .addMetaData(JMSAdvisor.JMS, JMSAdvisor.EXC...
public Object invoke(Invocation invocation) throws Throwable { if (invocation instanceof MethodInvocation) { MethodInvocation mi = (MethodInvocation)invocation; Method m = mi.getMethod(); String name = m.getName(); if ("getClientID".equals(name)) { retur...
box.x = 0; box.y = 0;
public static void layoutContent(Context c, Box box, List contentList) { //Here we should always be inside something that corresponds to a block-level element //for formatting purposes Rectangle bounds = new Rectangle(); bounds.width = c.getExtents().width; validateBounds(bounds);...
repaint(comp.getX(), comp.getY(), comp.getWidth(), comp.getHeight());
protected void addImpl(Component comp, Object layerConstraint, int index) { int layer; if (layerConstraint != null && layerConstraint instanceof Integer) layer = ((Integer) layerConstraint).intValue(); else layer = getLayer(comp); int newIdx = insertIndexForLayer(layer, index); setLa...
c.pushStyle(CascadedStyle.emptyCascadedStyle); block.setStyle(new Style(c.getCurrentStyle(), 0, c.getCtx())); c.popStyle();
public static Box createBox(Context c, Content content) { Box block = new AnonymousBlockBox(content); return block; }
if (block.auto_height == false) {
if (!block.getStyle().isAutoHeight()) {
public static Box layout(Context c, Box block, Content content) { // copy the extents Rectangle oe = c.getExtents(); c.setExtents(new Rectangle(oe)); //block.x = c.getExtents().x; //block.y = c.getExtents().y; // save height incase fixed height int original_height = ...
byte[] getBytes(long pos, int length) throws SQLException;
byte[] getBytes(long start, int count) throws SQLException;
byte[] getBytes(long pos, int length) throws SQLException;
OutputStream setBinaryStream(long pos) throws SQLException;
OutputStream setBinaryStream(long start) throws SQLException;
OutputStream setBinaryStream(long pos) throws SQLException;
int setBytes(long pos, byte[] bytes) throws SQLException;
int setBytes(long start, byte[] bytes) throws SQLException;
int setBytes(long pos, byte[] bytes) throws SQLException;
ActionDescriptor action = wf.getAction(actionId);
ActionDescriptor action = null;
public void doAction(long id, int actionId, Map inputs) throws WorkflowException { WorkflowStore store = getPersistence(); WorkflowEntry entry = store.findEntry(id); WorkflowDescriptor wf = getWorkflow(entry.getWorkflowName()); List currentSteps = store.findCurrentSteps(id); Actio...
boolean validAction = isActionAvailable(action, transientVars, ps);
boolean validAction = false; LABEL: for (Iterator iter = currentSteps.iterator(); iter.hasNext();) { Step step = (Step) iter.next(); StepDescriptor s = wf.getStep(step.getStepId()); for (Iterator iterator = s.getActions().iterator(); iterator.hasNext();) { ActionDescriptor actionDesc = (ActionDescriptor) iterator.nex...
public void doAction(long id, int actionId, Map inputs) throws WorkflowException { WorkflowStore store = getPersistence(); WorkflowEntry entry = store.findEntry(id); WorkflowDescriptor wf = getWorkflow(entry.getWorkflowName()); List currentSteps = store.findCurrentSteps(id); Actio...
public static void paintBackground(Context c, Box box) {
public static void paintBackground(Context c, Box box, Rectangle bounds) {
public static void paintBackground(Context c, Box box) { Box block = box; // cache the background color //no sense getBackgroundColor(c); // get the css properties CalculatedStyle style = c.getCurrentStyle(); String back_image = style.getStringProperty(CSSName.BACKGROUND_IM...
BlockFormattingContext bfc = c.getBlockFormattingContext(); if (bfc != null) { float width = bfc.getWidth(); float height = bfc.getHeight();
public static void paintBackground(Context c, Box box) { Box block = box; // cache the background color //no sense getBackgroundColor(c); // get the css properties CalculatedStyle style = c.getCurrentStyle(); String back_image = style.getStringProperty(CSSName.BACKGROUND_IM...
Point pt = style.getBackgroundPosition(width - backImageWidth, height - backImageHeight, c.getCtx()); block.background_position_horizontal = (int) pt.getX(); block.background_position_vertical = (int) pt.getY(); }
Point pt = style.getBackgroundPosition(bounds.width - backImageWidth, bounds.height - backImageHeight, c.getCtx()); block.background_position_horizontal = (int) pt.getX(); block.background_position_vertical = (int) pt.getY();
public static void paintBackground(Context c, Box box) { Box block = box; // cache the background color //no sense getBackgroundColor(c); // get the css properties CalculatedStyle style = c.getCurrentStyle(); String back_image = style.getStringProperty(CSSName.BACKGROUND_IM...
paintBackground(c, block);
int width = block.getWidth(); int height = block.getHeight(); Border margin = c.getCurrentStyle().getMarginWidth(width, height, c.getCtx()); Rectangle bounds = new Rectangle(block.x + margin.left, block.y + margin.top, block.width - margin.left - margin.right, block.height - margin.top - margin.bottom); paintBackgroun...
public static void paintNormal(Context c, Box block, boolean restyle) { paintBackground(c, block); c.translateInsets(block); /* Q&D for now if (block instanceof TableBox) { TableRendering.paintTable(c, (TableBox) block, restyle); } else */ if (isInlineLayedOut(block)) { ...
int width = block.getWidth(); int height = block.getHeight(); Border margin = c.getCurrentStyle().getMarginWidth(width, height, c.getCtx()); Rectangle bounds = new Rectangle(block.x + margin.left, block.y + margin.top, block.width - margin.left - margin.right, block.height - margin.top - margin.bottom);
public static void paintNormal(Context c, Box block, boolean restyle) { paintBackground(c, block); c.translateInsets(block); /* Q&D for now if (block instanceof TableBox) { TableRendering.paintTable(c, (TableBox) block, restyle); } else */ if (isInlineLayedOut(block)) { ...
return Expression.and(buildExpression(query), buildExpression(query));
return Expression.and(buildExpression(left), buildExpression(right));
private Expression buildExpression(WorkflowQuery query) throws StoreException { if (query.getLeft() == null) { if (query.getRight() == null) { return getExpression(query); //leaf node } else { throw new StoreException("Invalid WorkflowQuery object. QueryLe...
return Expression.or(buildExpression(query), buildExpression(query));
return Expression.or(buildExpression(left), buildExpression(right));
private Expression buildExpression(WorkflowQuery query) throws StoreException { if (query.getLeft() == null) { if (query.getRight() == null) { return getExpression(query); //leaf node } else { throw new StoreException("Invalid WorkflowQuery object. QueryLe...
return session.find("FROM step IN CLASS " + HibernateCurrentStep.class.getName() + " WHERE step.entry = ?", entry, Hibernate.association(entry.getClass()));
return session.find("FROM step IN CLASS " + HibernateCurrentStep.class.getName() + " WHERE step.entry = ?", entry, Hibernate.entity(entry.getClass()));
public List findCurrentSteps(long entryId) throws StoreException { HibernateWorkflowEntry entry; try { entry = (HibernateWorkflowEntry) session.find("FROM entry in CLASS " + HibernateWorkflowEntry.class.getName() + " WHERE entry.id = ?", new Long(entryId), Hibernate.LONG).get(0); } c...
return session.find("FROM step IN CLASS " + HibernateHistoryStep.class.getName() + " WHERE step.entry = ?", entry, Hibernate.association(entry.getClass()));
return session.find("FROM step IN CLASS " + HibernateHistoryStep.class.getName() + " WHERE step.entry = ?", entry, Hibernate.entity(entry.getClass()));
public List findHistorySteps(long entryId) throws StoreException { HibernateWorkflowEntry entry; try { entry = (HibernateWorkflowEntry) session.find("FROM entry in CLASS " + HibernateWorkflowEntry.class.getName() + " WHERE entry.id = ?", new Long(entryId), Hibernate.LONG).get(0); } c...
return Expression.eq(getFieldName(query.getField()), getSafeValue(query.getValue()));
return Expression.eq(getFieldName(query.getField()), query.getValue());
private Expression getExpression(WorkflowQuery query) { int operator = query.getOperator(); switch (operator) { case WorkflowQuery.EQUALS: return Expression.eq(getFieldName(query.getField()), getSafeValue(query.getValue())); case WorkflowQuery.NOT_EQUALS: return Exp...
return Expression.not(Expression.like(getFieldName(query.getField()), getSafeValue(query.getValue())));
return Expression.not(Expression.like(getFieldName(query.getField()), query.getValue()));
private Expression getExpression(WorkflowQuery query) { int operator = query.getOperator(); switch (operator) { case WorkflowQuery.EQUALS: return Expression.eq(getFieldName(query.getField()), getSafeValue(query.getValue())); case WorkflowQuery.NOT_EQUALS: return Exp...
return Expression.gt(getFieldName(query.getField()), getSafeValue(query.getValue()));
return Expression.gt(getFieldName(query.getField()), query.getValue());
private Expression getExpression(WorkflowQuery query) { int operator = query.getOperator(); switch (operator) { case WorkflowQuery.EQUALS: return Expression.eq(getFieldName(query.getField()), getSafeValue(query.getValue())); case WorkflowQuery.NOT_EQUALS: return Exp...
return Expression.lt(getFieldName(query.getField()), getSafeValue(query.getValue()));
return Expression.lt(getFieldName(query.getField()), query.getValue());
private Expression getExpression(WorkflowQuery query) { int operator = query.getOperator(); switch (operator) { case WorkflowQuery.EQUALS: return Expression.eq(getFieldName(query.getField()), getSafeValue(query.getValue())); case WorkflowQuery.NOT_EQUALS: return Exp...
Relative.translateRelative(ctx);
Relative.translateRelative(ctx, true);
public static void paintRelative(Context ctx, Box block, boolean restyle) { Relative.translateRelative(ctx); paintNormal(ctx, block, restyle); Relative.untranslateRelative(ctx); }
Relative.untranslateRelative(ctx);
Relative.untranslateRelative(ctx, true);
public static void paintRelative(Context ctx, Box block, boolean restyle) { Relative.translateRelative(ctx); paintNormal(ctx, block, restyle); Relative.untranslateRelative(ctx); }
throw new RuntimeException ("couldn't set java.awt.Component.peer field");
public void addNotify() { // Assume we're using ClasspathToolkit ClasspathToolkit tk = (ClasspathToolkit) getToolkit(); // Circumvent the package-privateness of the AWT internal // java.awt.Component.peer member variable. try { Field peerField = Component.class.getDeclaredField("peer"); AccessCon...
return "ClientConnectionFactoryDelegate[" + id + ", " + serverID + "]";
return "ConnectionFactoryDelegate[" + id + ", " + serverID + "]";
public String toString() { return "ClientConnectionFactoryDelegate[" + id + ", " + serverID + "]"; }
Distributor destination = dm.getCoreDestination(jmsDestination); if (destination == null)
Distributor coreDestination = dm.getCoreDestination(jmsDestination); if (coreDestination == null)
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
Topic topic = (Topic)destination;
Topic topic = (Topic)coreDestination;
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
if (subscriptionName != null)
if (subscriptionName == null)
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
if (log.isTraceEnabled()) { log.trace("creating new non-durable subscription on " + coreDestination); } subscription = new Subscription(topic, selector, ms); } else {
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
throw new JMSException("Cannot create durable subscriber without having set client ID");
throw new JMSException("Cannot create durable subscriber without a valid client ID");
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
if (log.isTraceEnabled()) { log.trace("creating new durable subscription on " + destination); }
if (log.isTraceEnabled()) { log.trace("creating new durable subscription on " + coreDestination); }
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
boolean topicChanged = subscription.getTopic() != destination;
boolean topicChanged = subscription.getTopic() != coreDestination;
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
if (selectorChanged || topicChanged)
boolean noLocalChanged = false; if (selectorChanged || topicChanged || noLocalChanged)
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
if (log.isTraceEnabled()) { log.trace("topic or selector changed so deleting old subscription"); }
if (log.isTraceEnabled()) { log.trace("topic or selector or noLocal changed so deleting old subscription"); }
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
subscription = null;
subscription = dsd.createDurableSubscription(d.getName(), clientID, subscriptionName, selector);
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
else { if (log.isTraceEnabled()) { log.trace("creating new non-durable subscription on " + destination); } subscription = new Subscription(topic, selector, ms); } }
}
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
subscription == null ? (Channel)destination : subscription,
subscription == null ? (Channel)coreDestination : subscription,
public ConsumerDelegate createConsumerDelegate(Destination jmsDestination, String selector, boolean noLocal, String subscriptionName, ...
addMouseListener(new LinkListener(this));
linkListener = new LinkListener(this); addMouseListener(linkListener);
private void setupListeners() { // install a default link listener addMouseListener(new LinkListener(this)); // install a default hover listener HoverListener hoverListener = new HoverListener(this); addMouseListener(hoverListener); addMouseMotionListener(hoverListener); ...
HoverListener hoverListener = new HoverListener(this);
hoverListener = new HoverListener(this);
private void setupListeners() { // install a default link listener addMouseListener(new LinkListener(this)); // install a default hover listener HoverListener hoverListener = new HoverListener(this); addMouseListener(hoverListener); addMouseMotionListener(hoverListener); ...
throws JMSException
throws InvalidSelectorException
public ServerConsumerDelegate(String id, AbstractDestination destination, InvokerCallbackHandler callbackHandler, ServerSessionDelegate sessionEndpoint, String selector, boolean noLocal, ...
messageSelector = new Selector(selector);
if (log.isTraceEnabled()) log.trace("Creating selector:" + selector); this.messageSelector = new Selector(selector); if (log.isTraceEnabled()) log.trace("Created selector");
public ServerConsumerDelegate(String id, AbstractDestination destination, InvokerCallbackHandler callbackHandler, ServerSessionDelegate sessionEndpoint, String selector, boolean noLocal, ...
if (log.isTraceEnabled()) { log.trace("accepting?" + accept); }
public boolean accept(Routable r) { boolean accept = true; if (messageSelector != null) { accept = messageSelector.accept(r); } if (accept) { if (noLocal) { String conId = ((JBossMessage)r).getConnectionID(); if (conId != nul...
this.sessionEndpoint.consumers.remove(id);
public void close() throws JMSException { this.setStarted(false); this.sessionEndpoint.connectionEndpoint.receivers.remove(id); if (subscription != null) { subscription.setHasConsumer(false); } }
if (log.isTraceEnabled()) log.trace("handle ServerConsumerDelegate:" + this.id);
public boolean handle(Routable r) { // deliver the message on a different thread than the core thread that brought it here try { threadPool.execute(new Delivery(callbackHandler, r, log)); } catch(InterruptedException e) { log.warn("Interrupted asynchronous delivery", e...
threadPool.execute(new Delivery(callbackHandler, r, log));
boolean sendMessage = this.accept(r); if (log.isTraceEnabled()) log.trace("Sending message?:" + sendMessage); if (sendMessage) { threadPool.execute(new Delivery(callbackHandler, r, log)); }
public boolean handle(Routable r) { // deliver the message on a different thread than the core thread that brought it here try { threadPool.execute(new Delivery(callbackHandler, r, log)); } catch(InterruptedException e) { log.warn("Interrupted asynchronous delivery", e...
destination.add(this);
if (log.isTraceEnabled()) log.trace("Attempting to add receiver"); boolean added = destination.add(this); if (log.isTraceEnabled()) log.trace("Added receiver:" + this.id + ", success=" + added);
void setStarted(boolean s) { if (s) { destination.add(this); } else { destination.remove(id); } }
destination.remove(id);
if (log.isTraceEnabled()) log.trace("Attempting to remove receiver"); Receiver removed = destination.remove(id); if (log.isTraceEnabled()) log.trace("Removed receiver:" + removed);
void setStarted(boolean s) { if (s) { destination.add(this); } else { destination.remove(id); } }
if (log.isTraceEnabled()) { log.trace("checking access permissions to " + dest); }
if (trace) { log.trace("checking access permissions to " + dest); }
private void check(Destination dest, CheckType checkType, ServerConnectionEndpoint conn) throws JMSSecurityException { if (log.isTraceEnabled()) { log.trace("checking access permissions to " + dest); } JBossDestination jbd = (JBossDestination)dest; boolean isQueue = jbd.isQueue(); String n...
if (channel instanceof CoreSubscription)
if (channel instanceof Subscription)
public void close() throws JMSException { if (closed) { throw new IllegalStateException("Consumer is already closed"); } if (trace) { log.trace(this + " close"); } closed = true; // On close we only disconnect the consumer from the Channel we don't actually remove it // T...
CoreSubscription sub = (CoreSubscription)channel; sub.closeConsumer();
Subscription sub = (Subscription)channel; try { if (!sub.isRecoverable()) { sub.disconnect(); } } catch (Exception e) { throw new MessagingJMSException("Failed to disconnect", e); }
public void close() throws JMSException { if (closed) { throw new IllegalStateException("Consumer is already closed"); } if (trace) { log.trace(this + " close"); } closed = true; // On close we only disconnect the consumer from the Channel we don't actually remove it // T...
int fullSize, int pageSize, int downCacheSize, QueuedExecutor executor, Filter filter)
int fullSize, int pageSize, int downCacheSize, QueuedExecutor executor)
public Queue(long id, MessageStore ms, PersistenceManager pm, boolean acceptReliableMessages, boolean recoverable, int fullSize, int pageSize, int downCacheSize, QueuedExecutor executor, Filter filter) { super(id, ms, pm, acceptReliableMessages, recove...
this.filter = filter;
public Queue(long id, MessageStore ms, PersistenceManager pm, boolean acceptReliableMessages, boolean recoverable, int fullSize, int pageSize, int downCacheSize, QueuedExecutor executor, Filter filter) { super(id, ms, pm, acceptReliableMessages, recove...
Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
postOffice.bindQueue("queue1", "topic1", queue1);
postOffice.bindQueue("queue1", "topic1", null, queue1);
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
Queue queue2 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue2 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
postOffice.bindQueue("queue2", "topic1", queue2);
postOffice.bindQueue("queue2", "topic1", null, queue2);
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
Queue queue3 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue3 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
postOffice.bindQueue("queue3", "topic1", queue3);
postOffice.bindQueue("queue3", "topic1", null, queue3);
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
Queue queue4 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue4 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
postOffice.bindQueue("queue4", "topic2", queue4);
postOffice.bindQueue("queue4", "topic2", null, queue4);
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
Queue queue5 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue5 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
postOffice.bindQueue("queue5", "topic2", queue5);
postOffice.bindQueue("queue5", "topic2", null, queue5);
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
Queue queue6 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue6 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
postOffice.bindQueue("queue6", "topic2", queue6);
postOffice.bindQueue("queue6", "topic2", null, queue6);
protected void route(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); Bind...
Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void routeTransactional(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); ...
postOffice.bindQueue("queue1", "topic1", queue1); Queue queue2 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
postOffice.bindQueue("queue1", "topic1", null, queue1); Queue queue2 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get());
protected void routeTransactional(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); ...
postOffice.bindQueue("queue2", "topic1", queue2);
postOffice.bindQueue("queue2", "topic1", null, queue2);
protected void routeTransactional(boolean persistentMessage) throws Throwable { PostOffice postOffice = null; try { postOffice = createPostOffice(); Queue queue1 = new Queue(im.getId(), ms, pm, true, false, 2000, 100, 100, (QueuedExecutor)pool.get(), null); ...
Queue queue1 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get(), null);
Queue queue1 = new Queue(im.getId(), ms, pm, true, true, 2000, 100, 100, (QueuedExecutor)pool.get());
public final void testBind() throws Throwable { PostOffice office1 = null; PostOffice office2 = null; PostOffice office3 = null; try { office1 = createPostOffice(); //Bind one durable Filter filter1 = new Selector("x ...