rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
dsm.getDurableSubscription(connectionEndpoint.clientID, subscriptionName, dm, ms, tl); | dsm.getDurableSubscription(connectionEndpoint.getClientID(), subscriptionName, dm, ms, tl); | public void unsubscribe(String subscriptionName) throws JMSException { if (closed) { throw new IllegalStateException("Session is closed"); } if (subscriptionName == null) { throw new InvalidDestinationException("Destination is null"); } CoreDurableSubscription sub... |
dsm.removeDurableSubscription(connectionEndpoint.clientID, subscriptionName); | dsm.removeDurableSubscription(connectionEndpoint.getClientID(), subscriptionName); | public void unsubscribe(String subscriptionName) throws JMSException { if (closed) { throw new IllegalStateException("Session is closed"); } if (subscriptionName == null) { throw new InvalidDestinationException("Destination is null"); } CoreDurableSubscription sub... |
float percent = 0; | String getStatistics(){ int packets = received+lost; float percent = 0;// if (packets != 0){// percent = lost/packets;// percent *= 100;// } float avg = sum/packets; return new String( packets +" packets transmitted, "+ received +" packets received\n"+ // percent +"% packet loss\n"+ "round-trip min/avg... | |
previousData.setEndsRun(true); | currentData.setEndsRun(true); | public void markRun(int offset, BlockBox previous, BlockBox current) { RelayoutData previousData = get(offset-1); RelayoutData currentData = get(offset); IdentValue previousAfter = previousAfter = previous.getStyle().getCalculatedStyle().getIdent( ... |
int offset = start - 1; | private static boolean relayoutOnNewPage( LayoutContext c, List contentList, Box block, StyleSetListener styleSetListener, RelayoutDataList relayoutDataList, int start, int end) { block.height = relayoutDataList.get(start).getInitialParentHeight(); block.expandToPage... | |
offset++; | private static boolean relayoutOnNewPage( LayoutContext c, List contentList, Box block, StyleSetListener styleSetListener, RelayoutDataList relayoutDataList, int start, int end) { block.height = relayoutDataList.get(start).getInitialParentHeight(); block.expandToPage... | |
c.restoreStateForRelayout(relayoutData.getLayoutState()); | private static boolean relayoutOnNewPage( LayoutContext c, List contentList, Box block, StyleSetListener styleSetListener, RelayoutDataList relayoutDataList, int start, int end) { block.height = relayoutDataList.get(start).getInitialParentHeight(); block.expandToPage... | |
if (log.isTraceEnabled()) log.trace("Creating ServerConsumerDelegate:" + id); | if (log.isTraceEnabled()) log.trace("Creating ServerConsumerDelegate:" + id + ", noLocal:" + noLocal); | public ServerConsumerDelegate(String id, AbstractDestination destination, InvokerCallbackHandler callbackHandler, ServerSessionDelegate sessionEndpoint, String selector, boolean noLocal, ... |
if (log.isTraceEnabled()) log.trace("There's a message selector"); | public boolean accept(Routable r) { boolean accept = true; if (messageSelector != null) { if (log.isTraceEnabled()) log.trace("There's a message selector"); accept = messageSelector.accept(r); if (log.isTraceEnabled()) { log.trace("Result of accept:" + acce... | |
if (log.isTraceEnabled()) log.trace("noLocal is true"); | public boolean accept(Routable r) { boolean accept = true; if (messageSelector != null) { if (log.isTraceEnabled()) log.trace("There's a message selector"); accept = messageSelector.accept(r); if (log.isTraceEnabled()) { log.trace("Result of accept:" + acce... | |
accept = conId.equals(sessionEndpoint.connectionEndpoint.connectionID); | accept = !conId.equals(sessionEndpoint.connectionEndpoint.connectionID); | public boolean accept(Routable r) { boolean accept = true; if (messageSelector != null) { if (log.isTraceEnabled()) log.trace("There's a message selector"); accept = messageSelector.accept(r); if (log.isTraceEnabled()) { log.trace("Result of accept:" + acce... |
if (subscription != null) { subscription.setHasConsumer(false); } | public void close() throws JMSException { if (log.isTraceEnabled()) log.trace("Close() on ServerConsumerDelegate:" + this.id); this.setStarted(false); this.sessionEndpoint.connectionEndpoint.receivers.remove(id); if (subscription != null) { subscription.setHasConsumer(false); } ... | |
if (log.isTraceEnabled()) log.trace("Attempting to remove receiver"); | if (log.isTraceEnabled()) log.trace("Attempting to remove receiver from destination:" + destination); | void setStarted(boolean s) { if (s) { 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); } else { if (log.isT... |
super(null, null, r, null, null, null); | super(r); | public Delivery(InvokerCallbackHandler callbackHandler, Routable r, Logger log) { super(null, null, r, null, null, null); this.callbackHandler = callbackHandler; this.log = log; } |
Client client = state.getCallbackClient(); client.removeListener(state.getMessageCallbackHandler()); client.disconnect(); | ConnectionState cState = (ConnectionState)state.getParent().getParent(); cState.getRemotingConnection().getCallbackManager().unregisterHandler(state.getConsumerID()); | public Object handleClosing(Invocation invocation) throws Throwable { ConsumerState state = getState(invocation); Client client = state.getCallbackClient(); client.removeListener(state.getMessageCallbackHandler()); client.disconnect(); state.getMessageCallbackHandler().close();... |
MessageCallbackHandler messageHandler = new MessageCallbackHandler(isCC, sessState.getAcknowledgeMode(), sessState.getExecutor(), connState.getPooledExecutor()); Client client = connState.getRemotingConnection().registerCallbackHandler(messageHandler); log.debug("listener added"); invocation.getMetaData().addMetaDa... | public Object handleCreateConsumerDelegate(Invocation invocation) throws Throwable { MethodInvocation mi = (MethodInvocation)invocation; boolean isCC = ((Boolean)mi.getArguments()[4]).booleanValue(); //Create the message handler SessionState sessState = (SessionState)((DelegateSup... | |
messageHandler.setSessionDelegate(del); messageHandler.setConsumerDelegate(consumerDelegate); messageHandler.setConsumerID(theState.getConsumerID()); | public Object handleCreateConsumerDelegate(Invocation invocation) throws Throwable { MethodInvocation mi = (MethodInvocation)invocation; boolean isCC = ((Boolean)mi.getArguments()[4]).booleanValue(); //Create the message handler SessionState sessState = (SessionState)((DelegateSup... | |
theState.setCallbackClient(client); | public Object handleCreateConsumerDelegate(Invocation invocation) throws Throwable { MethodInvocation mi = (MethodInvocation)invocation; boolean isCC = ((Boolean)mi.getArguments()[4]).booleanValue(); //Create the message handler SessionState sessState = (SessionState)((DelegateSup... | |
c.setPageCount(pageCount); | public void createPDF(OutputStream os) throws DocumentException { List pages = _root.getLayer().getPages(); RenderingContext c = newRenderingContext(); PageBox firstPage = (PageBox)pages.get(0); com.lowagie.text.Rectangle firstPageSize = new com.lowagie.text.Rectangle( ... | |
c.setCurrentPage(i); | public void createPDF(OutputStream os) throws DocumentException { List pages = _root.getLayer().getPages(); RenderingContext c = newRenderingContext(); PageBox firstPage = (PageBox)pages.get(0); com.lowagie.text.Rectangle firstPageSize = new com.lowagie.text.Rectangle( ... | |
Border margin = tableBox.getMarginWidth(c, (float) oe.getWidth()); | tableBox.setMarginWidth(c, (float) oe.getWidth()); Border margin = tableBox.getMarginWidth(); | public static Box layout(Context c, BlockBox outerBox, Content content) { boolean set_bfc = false; if (content instanceof TableContent) { // install a block formatting context for the body, // ie. if it's null. // set up the outtermost bfc if (c.getBlockForm... |
cell.setMarginWidth(c, c.getExtents().width); | private static CellBox layoutCell(Context 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); } if ... | |
row.setMarginWidth(c, (float) oe.getWidth()); | private static RowBox layoutRow(Context 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(); Casca... | |
sb.append("ID="); | sb.append(""); | public String toString() { StringBuffer sb = new StringBuffer("JBossMessage["); sb.append("ID="); sb.append(messageID); sb.append(","); sb.append(isReliable() ? "PERSISTENT" : "NONPERSISTENT"); sb.append("]"); return sb.toString(); } |
sb.append(","); sb.append(isReliable() ? "PERSISTENT" : "NONPERSISTENT"); sb.append("]"); | sb.append("]:"); sb.append(isReliable() ? "PERSISTENT" : "NON-PERSISTENT"); | public String toString() { StringBuffer sb = new StringBuffer("JBossMessage["); sb.append("ID="); sb.append(messageID); sb.append(","); sb.append(isReliable() ? "PERSISTENT" : "NONPERSISTENT"); sb.append("]"); return sb.toString(); } |
if (ref == null) | try | public Message getMessage() { if (log.isTraceEnabled()) { log.trace(this + ": getting message from reference " + ref); } if (ref == null) { //Been created through serialization } Message m = (Message)ref.get(); if (m == null) { m = ms.retrieve(messageI... |
Message m = (Message)ref.get(); if (m == null) { m = ms.retrieveMessage((String)messageID); ref = new WeakReference(m); } return m; | public Message getMessage() { if (log.isTraceEnabled()) { log.trace(this + ": getting message from reference " + ref); } if (ref == null) { //Been created through serialization } Message m = (Message)ref.get(); if (m == null) { m = ms.retrieve(messageI... | |
Message m = (Message)ref.get(); if (m == null) | catch (Exception e) | public Message getMessage() { if (log.isTraceEnabled()) { log.trace(this + ": getting message from reference " + ref); } if (ref == null) { //Been created through serialization } Message m = (Message)ref.get(); if (m == null) { m = ms.retrieve(messageI... |
m = ms.retrieve(messageID); ref = new WeakReference(m); | log.error("Failed to getMessage", e); return null; | public Message getMessage() { if (log.isTraceEnabled()) { log.trace(this + ": getting message from reference " + ref); } if (ref == null) { //Been created through serialization } Message m = (Message)ref.get(); if (m == null) { m = ms.retrieve(messageI... |
return m; | public Message getMessage() { if (log.isTraceEnabled()) { log.trace(this + ": getting message from reference " + ref); } if (ref == null) { //Been created through serialization } Message m = (Message)ref.get(); if (m == null) { m = ms.retrieve(messageI... | |
if (securityConfig == null) { securityConfig = dm.getDefaultSecurityConfiguration(); } | public synchronized void startService() throws Exception { started = true; if (serviceName != null) { name = serviceName.getKeyProperty("name"); } if (name == null || name.length() == 0) { throw new IllegalStateException( "The " + (isQueue() ? "queue" : "topic") + ... | |
public JBossConnection(ConnectionDelegate delegate, boolean isXAConnection) | public JBossConnection(ConnectionDelegate delegate, boolean isXA, int connectionType) | public JBossConnection(ConnectionDelegate delegate, boolean isXAConnection) { this.delegate = delegate; this.isXAConnection = isXAConnection; } |
this.isXAConnection = isXAConnection; | this.isXA = isXA; this.connectionType = connectionType; | public JBossConnection(ConnectionDelegate delegate, boolean isXAConnection) { this.delegate = delegate; this.isXAConnection = isXAConnection; } |
throw new NotYetImplementedException(); | delegate.closing(); delegate.close(); | public void close() throws JMSException { throw new NotYetImplementedException(); } |
{ | { if (connectionType == TYPE_QUEUE_CONNECTION) throw new IllegalStateException("Cannot create a durable connection consumer on a QueueConnection"); | public ConnectionConsumer createDurableConnectionConsumer( Topic topic, String subscriptionName, String messageSelector, ServerSessionPool sessionPool, int maxMessages) throws JMSException { throw new NotYetImplementedException(); } |
{ return (QueueSession)createSession(transacted, acknowledgeMode); | { return createSessionInternal(transacted, acknowledgeMode, false, JBossSession.TYPE_QUEUE_SESSION); | public QueueSession createQueueSession(boolean transacted, int acknowledgeMode) throws JMSException { return (QueueSession)createSession(transacted, acknowledgeMode); } |
SessionDelegate sessionDelegate = delegate.createSessionDelegate(transacted, acknowledgeMode); return new JBossSession(sessionDelegate); | return createSessionInternal(transacted, acknowledgeMode, false, TYPE_GENERIC_CONNECTION); | public Session createSession(boolean transacted, int acknowledgeMode) throws JMSException { SessionDelegate sessionDelegate = delegate.createSessionDelegate(transacted, acknowledgeMode); return new JBossSession(sessionDelegate); } |
return (TopicSession)createSession(transacted, acknowledgeMode); | return createSessionInternal(transacted, acknowledgeMode, false, JBossSession.TYPE_TOPIC_SESSION); | public TopicSession createTopicSession(boolean transacted, int acknowledgeMode) throws JMSException { return (TopicSession)createSession(transacted, acknowledgeMode); } |
return (XAQueueSession)createXASession(); | if (!isXA) throw new JMSException("Not an XA connection"); return createSessionInternal(true, Session.SESSION_TRANSACTED, true, JBossSession.TYPE_QUEUE_SESSION); | public XAQueueSession createXAQueueSession() throws JMSException { return (XAQueueSession)createXASession(); } |
if (!isXAConnection) throw new JMSException("Not an XA connection"); return (XASession)createSession(true, Session.SESSION_TRANSACTED); | if (!isXA) throw new JMSException("Not an XA connection"); return createSessionInternal(true, Session.SESSION_TRANSACTED, true, JBossSession.TYPE_GENERIC_SESSION); | public XASession createXASession() throws JMSException { if (!isXAConnection) throw new JMSException("Not an XA connection"); return (XASession)createSession(true, Session.SESSION_TRANSACTED); } |
return (XATopicSession)createXASession(); | if (!isXA) throw new JMSException("Not an XA connection"); return createSessionInternal(true, Session.SESSION_TRANSACTED, true, JBossSession.TYPE_TOPIC_SESSION); | public XATopicSession createXATopicSession() throws JMSException { return (XATopicSession)createXASession(); } |
return exceptionListener; | return delegate.getExceptionListener(); | public ExceptionListener getExceptionListener() throws JMSException { return exceptionListener; } |
this.exceptionListener = listener; | delegate.setExceptionListener(listener); | public void setExceptionListener(ExceptionListener listener) throws JMSException { this.exceptionListener = listener; } |
final VmInstanceField stackEndField = (VmInstanceField) vmThreadClass.getField("stackEnd"); | final VmInstanceField threadStackEndField = (VmInstanceField) vmThreadClass.getField("stackEnd"); final VmType vmProcessorClass = loadClass(VmProcessor.class); final VmInstanceField procStackEndField = (VmInstanceField) vmProcessorClass.getField("stackEnd"); | protected void initVmThread(X86Stream os) throws BuildException, ClassNotFoundException { final VmType vmThreadClass = loadClass(VmThread.class); final VmInstanceField threadStackField = (VmInstanceField) vmThreadClass.getField("stack"); final VmInstanceField stackEndField = (VmInstanceField) vmThreadClass.getField... |
os.writeMOV(INTSIZE, Register.EBX, stackEndField.getOffset(), Register.EDX); | os.writeMOV(INTSIZE, Register.EBX, threadStackEndField.getOffset(), Register.EDX); os.writeMOV_Const(Register.EBX, processor); os.writeMOV(INTSIZE, Register.EBX, procStackEndField.getOffset(), Register.EDX); | protected void initVmThread(X86Stream os) throws BuildException, ClassNotFoundException { final VmType vmThreadClass = loadClass(VmThread.class); final VmInstanceField threadStackField = (VmInstanceField) vmThreadClass.getField("stack"); final VmInstanceField stackEndField = (VmInstanceField) vmThreadClass.getField... |
addCompileHighOptLevel("org.jnode.vm.x86.compiler.l1a"); | protected void setupCompileHighOptLevelPackages() { super.setupCompileHighOptLevelPackages(); addCompileHighOptLevel("org.jnode.assembler.x86"); addCompileHighOptLevel("org.jnode.system.x86"); addCompileHighOptLevel("org.jnode.vm.x86"); addCompileHighOptLevel("org.jnode.vm.x86.com... | |
iterator = destination.browse().iterator(); | Filter filter = null; if (messageSelector != null) { filter = new Selector(messageSelector); } iterator = destination.browse(filter).iterator(); | ServerBrowserDelegate(String browserID, AbstractDestination destination, String messageSelector) { this.browserID = browserID; this.messageSelector = messageSelector; this.destination = destination; iterator = destination.browse().iterator();... |
public ClientConsumerDelegate(String objectID, InvokerLocator locator) | public ClientConsumerDelegate(String objectID) | public ClientConsumerDelegate(String objectID, InvokerLocator locator) { super(objectID, locator); } |
super(objectID, locator); | super(objectID); | public ClientConsumerDelegate(String objectID, InvokerLocator locator) { super(objectID, locator); } |
SessionDelegate sessDelegate = (SessionDelegate)this.getDelegate(mi); if (!sessDelegate.getTransacted()) | if (!this.transacted) | public Object invoke(Invocation invocation) throws Throwable { if (!(invocation instanceof MethodInvocation)) { return invocation.invokeNext(); } MethodInvocation mi = (MethodInvocation)invocation; String methodName = mi.getMethod().getName(); if (log.isTraceEnable... |
if (sessDelegate.getXA()) | if (this.XA) | public Object invoke(Invocation invocation) throws Throwable { if (!(invocation instanceof MethodInvocation)) { return invocation.invokeNext(); } MethodInvocation mi = (MethodInvocation)invocation; String methodName = mi.getMethod().getName(); if (log.isTraceEnable... |
if (!sessDelegate.getTransacted()) | if (!this.transacted) | public Object invoke(Invocation invocation) throws Throwable { if (!(invocation instanceof MethodInvocation)) { return invocation.invokeNext(); } MethodInvocation mi = (MethodInvocation)invocation; String methodName = mi.getMethod().getName(); if (log.isTraceEnable... |
else if ("getTransacted".equals(methodName)) { return new Boolean(transacted); } else if ("getXA".equals(methodName)) { return new Boolean(XA); } else if ("setTransacted".equals(methodName)) { this.transacted = ((Boolean)mi.getArguments()[0]).booleanValue(); return null; } else if ("setXA".equals(methodName)) { this.... | public Object invoke(Invocation invocation) throws Throwable { if (!(invocation instanceof MethodInvocation)) { return invocation.invokeNext(); } MethodInvocation mi = (MethodInvocation)invocation; String methodName = mi.getMethod().getName(); if (log.isTraceEnable... | |
if ( display != null && display.equals( "block" ) ) { | if ( display != null && (display.equals( "block" ) || display.equals( "table-cell" )) ) { | public static boolean isBlockNode( Node child, Context c ) { if ( child instanceof Element ) { Element el = (Element)child; String display = c.css.getStringProperty( el, "display", false ); //u.p("display = " + display); if ( display != null && display.equals( "blo... |
panel.startLayout(g2); | public void layout(Graphics2D g2, Dimension dim) { panel.setSize(dim); } | |
if(g2.getClip() == null) { g2.setClip(getMinimumSize()); } | public void render(Graphics2D g2) { panel.paintComponent(g2); } | |
bodyReadOnly = false; | public void clearBody() throws JMSException { content = new HashMap(); super.clearBody(); } | |
bodyReadOnly = in.readBoolean(); | public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException { super.readExternal(in); content = readMap(in); } | |
if (!messageReadWrite) | if (bodyReadOnly) | public void setBoolean(String name, boolean value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, Primitives.valueOf(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setByte(String name, byte value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, new Byte(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setBytes(String name, byte[] value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, value.clone()); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setChar(String name, char value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, new Character(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setDouble(String name, double value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, new Double(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setFloat(String name, float value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, new Float(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setInt(String name, int value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, new Integer(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setLong(String name, long value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, new Long(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setObject(String name, Object value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); if (value instanceof Boolean) content.put(name, value); else if (value instanceof Byte) content... |
if (!messageReadWrite) | if (bodyReadOnly) | public void setShort(String name, short value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, new Short(value)); } |
if (!messageReadWrite) | if (bodyReadOnly) | public void setString(String name, String value) throws JMSException { checkName(name); if (!messageReadWrite) throw new MessageNotWriteableException("Message is ReadOnly !"); content.put(name, value); } |
out.writeBoolean(bodyReadOnly); | public void writeExternal(ObjectOutput out) throws IOException { super.writeExternal(out); writeMap(out, content); } | |
Mapper(java.util.Collection selectors) { | Mapper(java.util.Collection selectors, org.w3c.dom.Node node) { _node = node; | Mapper(java.util.Collection selectors) { axes.addAll(selectors); } |
void mapChildren(org.w3c.dom.Document doc) { org.w3c.dom.NodeList children = doc.getChildNodes(); | void mapChildren() { org.w3c.dom.NodeList children = _node.getChildNodes(); | void mapChildren(org.w3c.dom.Document doc) { org.w3c.dom.NodeList children = doc.getChildNodes(); mapElements(children); } |
mapElement((org.w3c.dom.Element)child); | mapChild((org.w3c.dom.Element)child); | private void mapElements(org.w3c.dom.NodeList children) { for(int i=0; i<children.getLength(); i++) { org.w3c.dom.Node child = children.item(i); if(child.getNodeType() == org.w3c.dom.Node.ELEMENT_NODE) { mapElement((org.w3c.dom.Element)child); ... |
Matcher() { | public Matcher(org.w3c.dom.Document doc, org.xhtmlrenderer.extend.AttributeResolver ar, java.util.Iterator stylesheets) { newMaps(); setDocument(doc); setAttributeResolver(ar); docMapper = createDocumentMapper(stylesheets); | Matcher() { } |
org.xhtmlrenderer.css.sheet.Ruleset elementStyling = getElementStyle(e); String fingerprint = null; if(elementStyling == null) { StringBuffer sb = new StringBuffer(); for(java.util.Iterator i = getMatchedRulesets(e); i.hasNext();) { sb.append(i.next().hashCode()); sb.append(":"); } fingerprint = sb.toString(); if(_csCa... | cs = createCascadedStyle(e); | public CascadedStyle getCascadedStyle(org.w3c.dom.Element e) { if(_csMap == null) _csMap = new java.util.HashMap(); CascadedStyle cs = (CascadedStyle)_csMap.get(e); if(cs != null) return cs; org.xhtmlrenderer.css.sheet.Ruleset elementStyling = getElementStyle(e); String fi... |
docMapper.mapChildren(_doc); | private Mapper getMapper(org.w3c.dom.Element e) { if(_map == null) { _map = new java.util.HashMap(); docMapper.mapChildren(_doc); } return (Mapper) _map.get(e); } | |
return (Mapper) _map.get(e); | Mapper m = (Mapper) _map.get(e); if(m == null) matchElement(e); m = (Mapper) _map.get(e); return m; | private Mapper getMapper(org.w3c.dom.Element e) { if(_map == null) { _map = new java.util.HashMap(); docMapper.mapChildren(_doc); } return (Mapper) _map.get(e); } |
public void setAttributeResolver(org.xhtmlrenderer.extend.AttributeResolver ar) { | void setAttributeResolver(org.xhtmlrenderer.extend.AttributeResolver ar) { | public void setAttributeResolver(org.xhtmlrenderer.extend.AttributeResolver ar) { _attRes = ar; clearMaps(); if(_elStyle != null) _elStyle = new java.util.HashMap(); } |
clearMaps(); | public void setAttributeResolver(org.xhtmlrenderer.extend.AttributeResolver ar) { _attRes = ar; clearMaps(); if(_elStyle != null) _elStyle = new java.util.HashMap(); } | |
public void setDocument(org.w3c.dom.Document doc) { | void setDocument(org.w3c.dom.Document doc) { | public void setDocument(org.w3c.dom.Document doc) { _doc = doc; clearMaps(); if(_elStyle != null) _elStyle = new java.util.HashMap(); } |
clearMaps(); | public void setDocument(org.w3c.dom.Document doc) { _doc = doc; clearMaps(); if(_elStyle != null) _elStyle = new java.util.HashMap(); } | |
_elStyle = null; if(_styleFactory != null) _elStyle = new java.util.HashMap(); _csMap = null; | public void setStylesheetFactory(org.xhtmlrenderer.css.sheet.StylesheetFactory styleFactory) { _styleFactory = styleFactory; //do not have to clear all maps here _elStyle = null; if(_styleFactory != null) _elStyle = new java.util.HashMap(); _csMap = null; } | |
this._primitiveType = guessType(value); | this._primitiveType = ValueConstants.guessType(value); | public DefaultCSSPrimitiveValue(String value) { this._stringValue = value; this._cssValueType = CSS_PRIMITIVE_VALUE; this._primitiveType = guessType(value); } |
assertEquals("aName", ScriptVariableParser.getVariableFromMaps("a.name", transients, ps)); assertEquals(a, ScriptVariableParser.getVariableFromMaps("a", transients, ps)); assertEquals("blah", ScriptVariableParser.getVariableFromMaps("blah", transients, ps)); assertEquals("jack", ScriptVariableParser.getVariableFromMaps... | DefaultVariableResolver resolver = new DefaultVariableResolver(); assertEquals("aName", resolver.getVariableFromMaps("a.name", transients, ps)); assertEquals(a, resolver.getVariableFromMaps("a", transients, ps)); assertEquals("blah", resolver.getVariableFromMaps("blah", transients, ps)); assertEquals("jack", resolver.g... | public void testVariableTranslation() { HashMap transients = new HashMap(); MemoryPropertySet ps = new MemoryPropertySet(); ps.init(null, null); A a = new A("aName", new B(100, "bName")); A a2 = new A("biff", new B(-1, "jack")); transients.put("a", a); transients.put... |
assertEquals("hello, jack, what is your age? -1", ScriptVariableParser.translateVariables("hello, ${a2.b.name}, what is your age? ${a2.b.age}", transients, ps)); assertEquals("hello, , what is your age? -1", ScriptVariableParser.translateVariables("hello, ${I.Don't.EXIST}, what is your age? ${a2.b.age}", transients, ps... | assertEquals("hello, jack, what is your age? -1", resolver.translateVariables("hello, ${a2.b.name}, what is your age? ${a2.b.age}", transients, ps)); assertEquals("hello, , what is your age? -1", resolver.translateVariables("hello, ${I.Don't.EXIST}, what is your age? ${a2.b.age}", transients, ps)); | public void testVariableTranslation() { HashMap transients = new HashMap(); MemoryPropertySet ps = new MemoryPropertySet(); ps.init(null, null); A a = new A("aName", new B(100, "bName")); A a2 = new A("biff", new B(-1, "jack")); transients.put("a", a); transients.put... |
public Class getCategory() | public final Class getCategory() | public Class getCategory() { return MediaSize.class; } |
public String getName() | public final String getName() | public String getName() { return "media-size"; } |
if (log.isTraceEnabled()) { log.trace("Invoking:" + invocation); } | public Object invoke(InvocationRequest invocation) throws Throwable { MethodInvocation i = (MethodInvocation)invocation.getParameter(); String s = (String)i.getMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_SESSION_ID); if (s != null) { Object callbackHandler = null; ... | |
throw new IllegalStateException("Cannot forget a reliable message delivery at this level"); | public boolean remove(Delivery d) throws Throwable { Routable r = d.getRoutable(); if (r.isReliable()) { throw new IllegalStateException("Cannot forget a reliable message delivery at this level"); } if (d instanceof CompositeDelivery) { throw new NotYetImplementedExcep... | |
throw new IllegalStateException("Cannot reliably hold a reliable message"); | public void add(Routable r) throws Throwable { if (r.isReliable()) { throw new IllegalStateException("Cannot reliably hold a reliable message"); } messages.add(r); } | |
Reader r = _userAgent.getReader(info.getUri()); if (r != null) { | InputStream is = _userAgent.getInputStream(info.getUri()); if (is != null) { | private void debugBadStyleSheet(StylesheetInfo info) { Reader r = _userAgent.getReader(info.getUri()); if (r != null) { try { LineNumberReader lnr = new LineNumberReader(new BufferedReader(r)); StringBuffer sb = new StringBuffer(); String line = ... |
Reader r = new InputStreamReader(is); | private void debugBadStyleSheet(StylesheetInfo info) { Reader r = _userAgent.getReader(info.getUri()); if (r != null) { try { LineNumberReader lnr = new LineNumberReader(new BufferedReader(r)); StringBuffer sb = new StringBuffer(); String line = ... | |
public Stylesheet parse(java.io.Reader reader, StylesheetInfo info) { InputSource is = new InputSource(reader); | public Stylesheet parse(InputStream stream, StylesheetInfo info) { Reader r = new InputStreamReader(stream); InputSource is = new InputSource(r); | public Stylesheet parse(java.io.Reader reader, StylesheetInfo info) { InputSource is = new InputSource(reader); CSSStyleSheet style = null; try { style = parser.parseStyleSheet(is); } catch (java.io.IOException e) { throw new XRRuntimeException("IOException on parsi... |
Reader reader = new StringReader(isis[i].getStyle()); StylesheetInfo info = isis[i].getInfo(); info.setUri(main.getUri()); Stylesheet is = parse(reader, info); info.setStylesheet(is); sheet.addStylesheet(info); | try { InputStream stream = new ByteArrayInputStream(isis[i].getStyle().getBytes("UTF-8")); StylesheetInfo info = isis[i].getInfo(); info.setUri(main.getUri()); Stylesheet is = parse(stream, info); info.setStylesheet(is); sheet.addStylesheet(info); } catch (UnsupportedEncodingException e) { e.printStackTrace(); } | public Stylesheet parseInlines(InlineStyleInfo[] isis, StylesheetInfo main) { Stylesheet sheet = new Stylesheet(main.getUri(), main.getOrigin()); if (isis != null) { for (int i = 0; i < isis.length; i++) { Reader reader = new StringReader(isis[i].getStyle()); S... |
this(true); | boxes = new ArrayList(); | public Box() { this(true); } |
BoxRendering.paint(c, box, false, restyle); return; | public static void paintChild(Context c, Box box, boolean restyle) { if (box.isChildrenExceedBounds()) { //Uu.p("box children exceed: " + box); BoxRendering.paint(c, box, false, restyle); return; } if (Configuration.isTrue("xr.renderer.viewport-repaint", false))... | |
Rectangle2D box_rect = new Rectangle(box.x, box.y, box.width, box.height); | Rectangle box_rect = new Rectangle(box.x, box.y, box.width, box.height); Rectangle old_clip = c.getGraphics().getClipBounds(); box_rect = box_rect.union(old_clip); | public static void paintChild(Context c, Box box, boolean restyle) { if (box.isChildrenExceedBounds()) { //Uu.p("box children exceed: " + box); BoxRendering.paint(c, box, false, restyle); return; } if (Configuration.isTrue("xr.renderer.viewport-repaint", false))... |
c.getGraphics().setClip(old_clip); | public static void paintChild(Context c, Box box, boolean restyle) { if (box.isChildrenExceedBounds()) { //Uu.p("box children exceed: " + box); BoxRendering.paint(c, box, false, restyle); return; } if (Configuration.isTrue("xr.renderer.viewport-repaint", false))... | |
/* | public void prepBox(Context c, InlineBox box, InlineBox prev_align, Font font) { // u.p("box = " + box); // u.p("prev align = " + prev_align); // prepare the font, colors, border, etc box.setFont(font); BoxLayout.getBackgroundColor(c,box); BoxLayout.getBorder(c,box); ... | |
CascadedStyle pseudo = c.css.getPseudoElementStyle(getNearestBlockElement(node,c),"first-line"); | CascadedStyle pseudo = c.css.getPseudoElementStyle(LineBreaker.getNearestBlockElement(box.node,c),"first-line"); | public void prepBox(Context c, InlineBox box, InlineBox prev_align, Font font) { // u.p("box = " + box); // u.p("prev align = " + prev_align); // prepare the font, colors, border, etc box.setFont(font); BoxLayout.getBackgroundColor(c,box); BoxLayout.getBorder(c,box); ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.