rem
stringlengths
0
477k
add
stringlengths
0
313k
context
stringlengths
6
599k
while (in < 0) try { if (outClosed) return -1; wait(); } catch (InterruptedException ex) { throw new InterruptedIOException(); } notifyAll(); int retval = buffer[out++] & 0xFF; if (out >= buffer.length) out = 0; if (out == in) { in = -1; out = 0; } return retval; }
if (bytes_read == -1) return(-1); else return((read_buf[0] & 0xFF)); }
public synchronized int read() throws IOException { // TBD: Spec says to throw IOException if thread writing to output stream // died. What does this really mean? Theoretically, multiple threads // could be writing to this object. Do you track the first, last, or // all of them? if (po == null) ...
protected synchronized void receive(int b) throws IOException { if (buffer == null) throw new IOException("pipe closed");
receive(int byte_received) throws IOException { int orig_in = in;
protected synchronized void receive(int b) throws IOException { if (buffer == null) throw new IOException("pipe closed"); // TBD: Spec says to throw IOException if thread reading from input stream // died. What does this really mean? Theoretically, multiple threads // could be reading to this obje...
for (;;) { try { wait(); } catch(InterruptedException e) { ; }
protected synchronized void receive(int b) throws IOException { if (buffer == null) throw new IOException("pipe closed"); // TBD: Spec says to throw IOException if thread reading from input stream // died. What does this really mean? Theoretically, multiple threads // could be reading to this obje...
if (b < 0) { outClosed = true; notifyAll(); return; }
if (closed) throw new IOException("Stream closed before receiving byte");
protected synchronized void receive(int b) throws IOException { if (buffer == null) throw new IOException("pipe closed"); // TBD: Spec says to throw IOException if thread reading from input stream // died. What does this really mean? Theoretically, multiple threads // could be reading to this obje...
while (in == out) try { wait(); } catch (InterruptedException ex) { throw new InterruptedIOException(); } if (in < 0) in = 0; buffer[in++] = (byte) b; if (in >= buffer.length) in = 0; notifyAll(); }
if (in != orig_in) return; } }
protected synchronized void receive(int b) throws IOException { if (buffer == null) throw new IOException("pipe closed"); // TBD: Spec says to throw IOException if thread reading from input stream // died. What does this really mean? Theoretically, multiple threads // could be reading to this obje...
public void connect (PipedInputStream dest) throws IOException { if (closed) throw new IOException("pipe closed");
connect(PipedInputStream snk) throws IOException { if (snk == this.snk) return;
public void connect (PipedInputStream dest) throws IOException { if (closed) throw new IOException("pipe closed"); if (destination != null) if (destination == dest) return; else throw new IOException("pipe already connected"); destination = dest; try { dest.connect(this); ...
if (destination != null) if (destination == dest) return; else throw new IOException("pipe already connected");
if (ever_connected) throw new IOException("Already connected");
public void connect (PipedInputStream dest) throws IOException { if (closed) throw new IOException("pipe closed"); if (destination != null) if (destination == dest) return; else throw new IOException("pipe already connected"); destination = dest; try { dest.connect(this); ...
destination = dest; try { dest.connect(this); } catch (IOException ex) { destination = null; throw ex; } }
if (closed) throw new IOException("Stream is closed and cannot be reopened"); this.snk = snk; ever_connected = true; snk.src = this; snk.connect(this); }
public void connect (PipedInputStream dest) throws IOException { if (closed) throw new IOException("pipe closed"); if (destination != null) if (destination == dest) return; else throw new IOException("pipe already connected"); destination = dest; try { dest.connect(this); ...
String files[] = classPath.split(":");
String files[] = classPath.split(File.pathSeparator);
public static ClassLoader getAppClassLoader() { String classPath = System.getProperty("java.class.path"); String files[] = classPath.split(":"); URL urls[] = new URL[files.length]; for (int i = 0; i < files.length; i++) { String string = files[i]; try { urls[i] = new File(string).toUR...
String parts[] = cp.split(":");
String parts[] = cp.split(File.pathSeparator);
public static void main(String argv[], Class applicationClass) { _wasERXApplicationMainInvoked = true; String cp = System.getProperty("java.class.path"); String parts[] = cp.split(":"); String normalLibs = ""; String systemLibs = ""; allFrameworks = new HashSet(); for (int i = 0; i < par...
systemLibs += jar + ":";
systemLibs += jar + File.pathSeparator;
public static void main(String argv[], Class applicationClass) { _wasERXApplicationMainInvoked = true; String cp = System.getProperty("java.class.path"); String parts[] = cp.split(":"); String normalLibs = ""; String systemLibs = ""; allFrameworks = new HashSet(); for (int i = 0; i < par...
normalLibs += jar + ":";
normalLibs += jar + File.pathSeparator;
public static void main(String argv[], Class applicationClass) { _wasERXApplicationMainInvoked = true; String cp = System.getProperty("java.class.path"); String parts[] = cp.split(":"); String normalLibs = ""; String systemLibs = ""; allFrameworks = new HashSet(); for (int i = 0; i < par...
cp = normalLibs + ":" + systemLibs;
cp = normalLibs + File.pathSeparator + systemLibs;
public static void main(String argv[], Class applicationClass) { _wasERXApplicationMainInvoked = true; String cp = System.getProperty("java.class.path"); String parts[] = cp.split(":"); String normalLibs = ""; String systemLibs = ""; allFrameworks = new HashSet(); for (int i = 0; i < par...
if (true) {
if (System.getProperty("_DisableClasspathReorder") == null) {
public static void main(String argv[], Class applicationClass) { _wasERXApplicationMainInvoked = true; String cp = System.getProperty("java.class.path"); String parts[] = cp.split(":"); String normalLibs = ""; String systemLibs = ""; allFrameworks = new HashSet(); for (int i = 0; i < par...
public void setDataElements(int x, int y, Object obj, DataBuffer data)
public void setDataElements(int x, int y, int w, int h, Object obj, DataBuffer data)
public void setDataElements(int x, int y, Object obj, DataBuffer data) { int offset = scanlineStride*y + x + data.getOffset(); int transferType = getTransferType(); if (getTransferType() != data.getDataType()) { throw new IllegalArgumentException("transfer type ("+ getTransferType()+"), "+ ...
int offset = scanlineStride*y + x + data.getOffset();
public void setDataElements(int x, int y, Object obj, DataBuffer data) { int offset = scanlineStride*y + x + data.getOffset(); int transferType = getTransferType(); if (getTransferType() != data.getDataType()) { throw new IllegalArgumentException("transfer type ("+ getTransferType()+"), "+ ...
int transferType = getTransferType(); if (getTransferType() != data.getDataType()) { throw new IllegalArgumentException("transfer type ("+ getTransferType()+"), "+ "does not match data "+ "buffer type (" + data.getDataType() + ")."); } try { switch (transferType) { case DataBuffer.TYPE_BYTE: { DataBufferByte out = (Da...
Object pixelData; switch (getTransferType()) { case DataBuffer.TYPE_BYTE: pixelData = ((DataBufferByte) data).getData(); break; case DataBuffer.TYPE_USHORT: pixelData = ((DataBufferUShort) data).getData(); break; case DataBuffer.TYPE_INT: pixelData = ((DataBufferInt) data).getData(); break; default: throw new ClassCas...
public void setDataElements(int x, int y, Object obj, DataBuffer data) { int offset = scanlineStride*y + x + data.getOffset(); int transferType = getTransferType(); if (getTransferType() != data.getDataType()) { throw new IllegalArgumentException("transfer type ("+ getTransferType()+"), "+ ...
int inOffset = 0; int dataOffset = scanlineStride*y + x + data.getOffset(); for (int yy=y; yy<(y+h); yy++) { System.arraycopy(obj,inOffset,pixelData,dataOffset,w); dataOffset += scanlineStride; inOffset += w; } }
public void setDataElements(int x, int y, Object obj, DataBuffer data) { int offset = scanlineStride*y + x + data.getOffset(); int transferType = getTransferType(); if (getTransferType() != data.getDataType()) { throw new IllegalArgumentException("transfer type ("+ getTransferType()+"), "+ ...
string_switch(getNames(getters), switchStyle, new StringSwitchCallback() { public void processCase(String key, Label end) {
string_switch(getNames(getters), switchStyle, new ObjectSwitchCallback() { public void processCase(Object key, Label end) {
private void generateGet(final Map getters) throws Exception { begin_method(MethodConstants.MAP_GET); load_this(); super_getfield("bean"); checkcast(type); load_arg(0); checkcast(String.class); string_switch(getNames(getters), switchStyle, new StringSwitchCallback() ...
public void processCase(String key, Label end) {
public void processCase(Object key, Label end) {
public void processCase(String key, Label end) { PropertyDescriptor pd = (PropertyDescriptor)getters.get(key); invoke(pd.getReadMethod()); box(pd.getReadMethod().getReturnType()); return_value(); }
string_switch(getNames(setters), switchStyle, new StringSwitchCallback() { public void processCase(String key, Label end) {
string_switch(getNames(setters), switchStyle, new ObjectSwitchCallback() { public void processCase(Object key, Label end) {
private void generatePut(final Map setters) throws Exception { begin_method(MethodConstants.MAP_PUT); load_this(); super_getfield("bean"); checkcast(type); load_arg(0); checkcast(String.class); string_switch(getNames(setters), switchStyle, new StringSwitchCallback() ...
public void processCase(String key, Label end) {
public void processCase(Object key, Label end) {
public void processCase(String key, Label end) { PropertyDescriptor pd = (PropertyDescriptor)setters.get(key); if (pd.getReadMethod() == null) { aconst_null(); } else { dup(); in...
myUdLength = theUdLength;
public void setContent(SmsUdhElement[] theUdhElements, byte[] theUd, int theUdLength) { // Clear old data myUdhElements = null; myUd = null; myUdLength = 0; if (theUdhElements != null) { myUdhElements = new SmsUdhElement[theUdhElements.length]; Syst...
super (top, left, bottom, right, color);
super (new Insets (top, left, bottom, right), color);
public MatteBorderUIResource(int top, int left, int bottom, int right, Color color) { super (top, left, bottom, right, color); }
super ();
public BorderUIResource(Border delegate) { super (); this.delegate = delegate; }
+ application.settings.objectForKey("appURL") + "?edit=" + session.user().userID(), true);
+ application.settings.objectForKey("appURL") + "wa/default?edit=" + session.user().userID(), true);
public WOComponent requestDate() { session().defaultEditingContext().insertObject(newDate); // put the new date in the user's dates newDate.setPerson(session.user()); session.user().addToDates(newDate); try { if (session.user().group()==null) throw new Exception(...
ExternalComponent externalComponent = (ExternalComponent) component;
ExternalComponent externalComponent = components.get(component);
public IQ query(Component component, IQ packet, int timeout) throws ComponentException { final LinkedBlockingQueue<IQ> answer = new LinkedBlockingQueue<IQ>(8); ExternalComponent externalComponent = (ExternalComponent) component; externalComponent.addIQResultListener(packet.getID(), new IQResult...
public static void setComponentManager(ComponentManager componnetManager) { ComponentManagerFactory.componentManager = componentManager;
public static void setComponentManager(ComponentManager manager) { componentManager = manager;
public static void setComponentManager(ComponentManager componnetManager) { ComponentManagerFactory.componentManager = componentManager; }
try { socket.close(); } catch (IOException e) {}
try { if (socket != null) socket.close(); } catch (IOException e) {}
public void connect(String host, int port, SocketFactory socketFactory, String subdomain) throws ComponentException { try { // Open a socket to the server this.socket = socketFactory.createSocket(host, port); // Assume that the host name matches the real name of th...
checkErrors();
private void parse(URL xmlURL, Resource res, boolean validate) throws ParseException, IOException { try { setResource(res); URL schemaURL = validate?getClass().getResource("ivy.xsd"):null; XMLHelper.parse(xmlURL, schemaURL, this); checkConfigurations(); ...
addError("exception while parsing: "+ex.getMessage()); throw new SAXException("exception while parsing: "+ex.getMessage(), ex);
if (ex instanceof SAXException) { throw (SAXException)ex; } throw new SAXException("problem occured while parsing ivy file. message: "+ex.getMessage(), ex);
public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException { try { if ("ivy-module".equals(qName)) { String version = attributes.getValue("version"); int versionIndex = ALLOWED_VERSIONS.indexOf(version); ...
else
else {
public NodeArgumentDialog(String title, Properties props, boolean isLocal, boolean isEditable) { super((Frame)null, title, isEditable); // display modal dialog createLogger(); Box nodeArgPanel = Box.createVerticalBox(); // create JTable if (isEditable) argTable = new J...
JButton deleteButton = new JButton("Delete Property");
deleteButton = new JButton("Delete Property");
public NodeArgumentDialog(String title, Properties props, boolean isLocal, boolean isEditable) { super((Frame)null, title, isEditable); // display modal dialog createLogger(); Box nodeArgPanel = Box.createVerticalBox(); // create JTable if (isEditable) argTable = new J...
Component c = argTable.getEditorComponent(); if (c != null) if (c instanceof JTextField) { int rowIndex = argTable.getEditingRow(); int colIndex = argTable.getEditingColumn(); if (rowIndex != -1 && colIndex != -1) model.setValueAt(((JTextField)c).getText(), rowIndex, colIndex); } else if(log.isErrorEnabled()) { log.err...
setVisible(false); }
public void actionPerformed(ActionEvent e) { Component c = argTable.getEditorComponent(); if (c != null) if (c instanceof JTextField) { int rowIndex = argTable.getEditingRow(); int colIndex = argTable.getEditingColumn(); if (rowIndex != -1 && colIndex != -1)...
returnValue = JOptionPane.CANCEL_OPTION;
Component c = argTable.getEditorComponent(); if (c != null) if (c instanceof JTextField) { int rowIndex = argTable.getEditingRow(); int colIndex = argTable.getEditingColumn(); if (rowIndex != -1 && colIndex != -1) model.setValueAt(((JTextField)c).getText(), rowIndex, colIndex); } else if(log.isErrorEnabled()) { log.err...
public void actionPerformed(ActionEvent e) { returnValue = JOptionPane.CANCEL_OPTION; setVisible(false); }
model.addRow("", "");
returnValue = JOptionPane.CANCEL_OPTION; setVisible(false);
public void actionPerformed(ActionEvent e) { model.addRow("", ""); }
int i = argTable.getSelectedRow(); if (i != -1) model.removeRow(i);
model.addRow("", "");
public void actionPerformed(ActionEvent e) { int i = argTable.getSelectedRow(); if (i != -1) model.removeRow(i); }
readPropertiesFromFile();
int i = argTable.getSelectedRow(); if (i != -1) model.removeRow(i);
public void actionPerformed(ActionEvent e) { readPropertiesFromFile(); }
byte bytes[] = ERXCompressionUtilities.gzipStringAsByteArray(aValue); if (bytes.length > 0) { takeStoredValueForKey(new NSData(bytes), key);
NSData valueToSet = null; if ( aValue != null ) { byte bytes[] = ERXCompressionUtilities.gzipStringAsByteArray(aValue); if (bytes.length > 0) { valueToSet = new NSData(bytes); }
public void takeStoredGzippedValueForKey(String aValue, String key) { byte bytes[] = ERXCompressionUtilities.gzipStringAsByteArray(aValue); if (bytes.length > 0) { takeStoredValueForKey(new NSData(bytes), key); } }
takeStoredValueForKey(valueToSet, key);
public void takeStoredGzippedValueForKey(String aValue, String key) { byte bytes[] = ERXCompressionUtilities.gzipStringAsByteArray(aValue); if (bytes.length > 0) { takeStoredValueForKey(new NSData(bytes), key); } }
createLogger();
public CSMARTGraph() { super("CSMART", true, true); initGraph(); markedElements = new Vector(); customizeGraph(); setColors(); setupDotPath(); }
public String getUID();
String getUID();
public String getUID();
public boolean isVisible();
boolean isVisible();
public boolean isVisible();
public String getLabel();
String getLabel();
public String getLabel();
public String getToolTip();
String getToolTip();
public String getToolTip();
public String getShape();
String getShape();
public String getShape();
public String getSides();
String getSides();
public String getSides();
public String getDistortion();
String getDistortion();
public String getDistortion();
public String getOrientation();
String getOrientation();
public String getOrientation();
public String getWidth();
String getWidth();
public String getWidth();
public String getHeight();
String getHeight();
public String getHeight();
public String getColor();
String getColor();
public String getColor();
public String getFontStyle();
String getFontStyle();
public String getFontStyle();
public PropertyTree getProperties();
PropertyTree getProperties();
public PropertyTree getProperties();
public Vector getIncomingLinks();
Vector getIncomingLinks();
public Vector getIncomingLinks();
public Vector getOutgoingLinks();
Vector getOutgoingLinks();
public Vector getOutgoingLinks();
public Vector getBidirectionalLinks();
Vector getBidirectionalLinks();
public Vector getBidirectionalLinks();
JFileChooser chooser = new JFileChooser(SocietyFinder.getInstance().getPath()); chooser.setFileSelectionMode(JFileChooser.FILES_AND_DIRECTORIES); int result = chooser.showDialog(this, "OK"); if (result != JFileChooser.APPROVE_OPTION) return null; SocietyComponent sc = null; File file = chooser.getSelectedFile(); Stri...
SocietyComponent sc = newSocietyComponent();
public DefaultMutableTreeNode newSociety() { // display file chooser to allow user to select file that defines society JFileChooser chooser = new JFileChooser(SocietyFinder.getInstance().getPath()); chooser.setFileSelectionMode(JFileChooser.FILES_AND_DIRECTORIES); // int result = chooser.showOpen...
hostConfiguration = new HostConfigurationBuilder(experiment, csmart);
hostConfiguration = new HostConfigurationBuilder(experiment, null);
private void setSocietyComponent(SocietyComponent cc) { communitySupport = new ClientCommunityController(); runningNodes = new Hashtable(); oldNodes = new Hashtable(); nodeListeners = new Hashtable(); nodePanes = new Hashtable(); // top level menus JMenu fileMenu = new JMenu(FILE_MENU); fileMe...
public EOEnterpriseObject object() { return (EOEnterpriseObject)valueForBinding("object"); }
public Object object() { return valueForBinding("object"); }
public EOEnterpriseObject object() { return (EOEnterpriseObject)valueForBinding("object"); }
boolean computed=false;
public Object sectionTitle() { D2WContext c=(D2WContext)valueForBinding("d2wContext"); Object result=object(); boolean computed=false; if (result!=null) { if (c!=null) { String k=(String)c.valueForKey("keyWhenGrouping"); if (k!=null) { ...
result=((EOEnterpriseObject)result).valueForKey(k); computed=true;
result=NSKeyValueCodingAdditions.Utility.valueForKeyPath(result,k);
public Object sectionTitle() { D2WContext c=(D2WContext)valueForBinding("d2wContext"); Object result=object(); boolean computed=false; if (result!=null) { if (c!=null) { String k=(String)c.valueForKey("keyWhenGrouping"); if (k!=null) { ...
setNamePrefix(interfaces[0].getName());
setNamePrefix(interfaces[ReflectUtils.findPackageProtected(interfaces)].getName());
private Object createHelper() { if (superclass != null) { setNamePrefix(superclass.getName()); } else if (interfaces != null) { setNamePrefix(interfaces[0].getName()); } Object key = KEY_FACTORY.newInstance(superclass, interfaces, filter, classOnly); return s...
Impact impact = (Impact)impacts.get(i);
ImpactComponent impact = (ImpactComponent)impacts.get(i);
private List getAgentsInImpacts() { List agents = new ArrayList(); for (int i = 0; i < impacts.size(); i++) { Impact impact = (Impact)impacts.get(i); agents.addAll(Arrays.asList(impact.getAgents())); } return agents; }
agents.addAll(getAgentsInMetrics());
public List getAgentsList() { List agents = getAgentsInSocieties(); agents.addAll(getAgentsInImpacts()); return agents; }
int n = getSocietyComponentCount();
int n = getComponentCount();
public int getTrialCount() { if (hasValidTrials) return numberOfTrials; ArrayList experimentValueCounts = new ArrayList(100); int n = getSocietyComponentCount(); for (int i = 0; i < n; i++) { SocietyComponent society = getSocietyComponent(i); Iterator names = society.getPropertyNames(); ...
SocietyComponent society = getSocietyComponent(i);
ModifiableConfigurableComponent society = getComponent(i);
public int getTrialCount() { if (hasValidTrials) return numberOfTrials; ArrayList experimentValueCounts = new ArrayList(100); int n = getSocietyComponentCount(); for (int i = 0; i < n; i++) { SocietyComponent society = getSocietyComponent(i); Iterator names = society.getPropertyNames(); ...
int n = getSocietyComponentCount();
int n = getComponentCount();
public Trial[] getTrials() { if (hasValidTrials) return (Trial[])trials.toArray(new Trial[trials.size()]); getTrialCount(); // update trial count // get lists of unbound properties and their experimental values List properties = new ArrayList(); List experimentValues = new ArrayList(); int n = ...
SocietyComponent society = getSocietyComponent(i);
ModifiableConfigurableComponent society = getComponent(i);
public Trial[] getTrials() { if (hasValidTrials) return (Trial[])trials.toArray(new Trial[trials.size()]); getTrialCount(); // update trial count // get lists of unbound properties and their experimental values List properties = new ArrayList(); List experimentValues = new ArrayList(); int n = ...
for (int i = 0; i < societies.size(); i++) if (!((SocietyComponent)societies.get(i)).isEditable())
for (int i = 0; i < getComponentCount(); i++) if (!((ModifiableConfigurableComponent)getComponent(i)).isEditable())
public boolean isEditable() { if (editable) { // make sure that societies are editable too for (int i = 0; i < societies.size(); i++) if (!((SocietyComponent)societies.get(i)).isEditable()) return false; return true; } return false; }
for (int i = 0; i < getSocietyComponentCount(); i++) getSocietyComponent(i).setEditable(editable);
for (int i = 0; i < getComponentCount(); i++) getComponent(i).setEditable(editable);
public void setEditable(boolean editable) { this.editable = editable; for (int i = 0; i < getSocietyComponentCount(); i++) getSocietyComponent(i).setEditable(editable); }
assetData.setType(((Integer)propAssetType.getValue()).intValue());
public ComponentData addComponentData(ComponentData data) { AgentAssetData assetData = new AgentAssetData((AgentComponentData)data); assetData.setType(((Integer)propAssetType.getValue()).intValue()); assetData.setAssetClass((String)propAssetClass.getValue()); assetData.setUniqueID((String)propUniqueID.get...
rData.setType((String)rel.getProperty(PROP_TYPE).getValue());
rData.setType((String)rel.getProperty(RelationshipBase.PROP_TYPE).getValue());
public ComponentData addComponentData(ComponentData data) { AgentAssetData assetData = new AgentAssetData((AgentComponentData)data); assetData.setType(((Integer)propAssetType.getValue()).intValue()); assetData.setAssetClass((String)propAssetClass.getValue()); assetData.setUniqueID((String)propUniqueID.get...
rData.setTypeId((String)rel.getProperty(RelationshipBase.PROP_TYPEID).getValue());
public ComponentData addComponentData(ComponentData data) { AgentAssetData assetData = new AgentAssetData((AgentComponentData)data); assetData.setType(((Integer)propAssetType.getValue()).intValue()); assetData.setAssetClass((String)propAssetClass.getValue()); assetData.setUniqueID((String)propUniqueID.get...
propAssetType = addProperty(PROP_TYPE, new Integer(aad.getType())); propAssetType.setToolTip(PROP_TYPE_DESC);
public void initProperties() { // strip off extension if it exists int index = filename.indexOf('.'); if (index != -1) filename = filename.substring(0, index); // Since there are two possible types of asset files, we // need to determine which parser to use. // We will determine this by lookin...
if(aad.getUniqueID() != null) { propUniqueID = addProperty(PROP_UID, aad.getUniqueID()); propUniqueID.setToolTip(PROP_UID_DESC); }
String uniqueId = (aad.getUniqueID() != null) ? aad.getUniqueID() : ""; propUniqueID = addProperty(PROP_UID, uniqueId); propUniqueID.setToolTip(PROP_UID_DESC);
public void initProperties() { // strip off extension if it exists int index = filename.indexOf('.'); if (index != -1) filename = filename.substring(0, index); // Since there are two possible types of asset files, we // need to determine which parser to use. // We will determine this by lookin...
if(aad.getUIC() != null) { propUIC = addProperty(PROP_UIC, aad.getUIC()); propUIC.setToolTip(PROP_UIC_DESC); }
propUIC = addProperty(PROP_UIC, (aad.getUIC() != null) ? aad.getUIC() : ""); propUIC.setToolTip(PROP_UIC_DESC);
public void initProperties() { // strip off extension if it exists int index = filename.indexOf('.'); if (index != -1) filename = filename.substring(0, index); // Since there are two possible types of asset files, we // need to determine which parser to use. // We will determine this by lookin...
File ivyFile = new File(_cache, IvyPatternHelper.substitute(_srcivypattern, _organisation, _module, _pubRevision, "ivy", "ivy", "xml"));
File ivyFile = new File(IvyPatternHelper.substitute(_srcivypattern, _organisation, _module, _pubRevision, "ivy", "ivy", "xml"));
public void execute() throws BuildException { Ivy ivy = getIvyInstance(); _organisation = getProperty(_organisation, ivy, "ivy.organisation"); _module = getProperty(_module, ivy, "ivy.module"); _revision = getProperty(_revision, ivy, "ivy.revision"); _pubRevision = getProperty(_pu...
public Collection publish(ModuleRevisionId mrid, String pubrevision, File cache, String srcArtifactPattern, String resolverName, String srcIvyPattern, boolean validate, boolean overwrite) throws IOException { Message.info(":: publishing :: "+mrid); Message.verbose("\tvalidate = "+validate); long start = System.currentT...
public Collection publish(ModuleRevisionId mrid, String pubrevision, File cache, String srcArtifactPattern, String resolverName, String srcIvyPattern, boolean validate) throws IOException { return publish(mrid, pubrevision, cache, srcArtifactPattern, resolverName, srcIvyPattern, validate, false);
public Collection publish(ModuleRevisionId mrid, String pubrevision, File cache, String srcArtifactPattern, String resolverName, String srcIvyPattern, boolean validate, boolean overwrite) throws IOException { Message.info(":: publishing :: "+mrid); Message.verbose("\tvalidate = "+validate); lon...
public String getBorderColor();
String getBorderColor();
public String getBorderColor();
doc.remove(start, end); doc.insertString(start, text, null);
doc.remove(start, end - start); doc.insertString(start, text, null);
public void replaceRange(String text, int start, int end) { Document doc = getDocument(); if (start > end || start < doc.getStartPosition().getOffset() || end >= doc.getEndPosition().getOffset()) throw new IllegalArgumentException(); try { doc.remove(start, end); doc.insertString(start, text, ...
charWidth(char ch)
charWidth(int ch)
charWidth(char ch){ return(1);}
return(1);
return(charWidth((char)ch));
charWidth(char ch){ return(1);}
formatClass = forName ("java.lang.Number");
formatClass = java.lang.Number.class;
void setLocale (Locale loc) { if (type == null) ; else if (type.equals("number")) { // FIXME: named class literal. // formatClass = Number.class; formatClass = forName ("java.lang.Number"); if (style == null) format = NumberFormat.getInstance(loc); else if (style.equals("currency")) for...
formatClass = forName ("java.util.Date");
formatClass = java.util.Date.class;
void setLocale (Locale loc) { if (type == null) ; else if (type.equals("number")) { // FIXME: named class literal. // formatClass = Number.class; formatClass = forName ("java.lang.Number"); if (style == null) format = NumberFormat.getInstance(loc); else if (style.equals("currency")) for...
this.field_id = field_id;
this.field_attribute = field;
public FieldPosition (int field_id) { this.field_id = field_id; }
if (dotExecutable == null) setupDotPath();
private void layoutDotFile(String dotPathname, boolean minimizeGraph) { // Create a file handle for the dot file // This will be used later to get the size of the file File dotFile = null; try { dotFile = new File(dotPathname); } catch (NullPointerException e) { System.out.println("CSMARTGrap...
public void saveGraph() { if (file != null) saveGraph(file); else saveAsGraph();
private void saveGraph(File outputFile) { if (outputFile == null) return; StringBuffer colorTable = new StringBuffer(500); Attribute ct = getAttribute(COLOR_TABLE); String graphUID = null; if (ct == null) { InetAddress localHost = null; try { localHost = InetAddress.getLocalHost(); } catch (Exception e) { System.out...
public void saveGraph() { if (file != null) saveGraph(file); else saveAsGraph(); }
return cmp(d[a], d[b]) < 0 ? (cmp(d[b], d[c]) < 0 ? b : cmp(d[a], d[c]) < 0 ? c : a) : (cmp(d[b], d[c]) > 0 ? b : cmp(d[a], d[c]) > 0 ? c : a);
return d[a] < d[b] ? (d[b] < d[c] ? b : d[a] < d[c] ? c : a) : (d[b] > d[c] ? b : d[a] > d[c] ? c : a);
private static int med3(int a, int b, int c, byte[]d) { return cmp(d[a], d[b]) < 0 ? (cmp(d[b], d[c]) < 0 ? b : cmp(d[a], d[c]) < 0 ? c : a) : (cmp(d[b], d[c]) > 0 ? b : cmp(d[a], d[c]) > 0 ? c : a); }
if (n < 7)
if (n <= 7)
private static void qsort(byte[]a, int start, int n) { // use an insertion sort on small arrays if (n < 7) { for (int i = start + 1; i < start + n; i++) for (int j = i; j > 0 && cmp(a[j - 1], a[j]) > 0; j--) swap(j, j - 1, a); return; } int pm = n / 2; // small arrays, middle element if ...
for (int j = i; j > 0 && cmp(a[j - 1], a[j]) > 0; j--)
for (int j = i; j > 0 && a[j - 1] > a[j]; j--)
private static void qsort(byte[]a, int start, int n) { // use an insertion sort on small arrays if (n < 7) { for (int i = start + 1; i < start + n; i++) for (int j = i; j > 0 && cmp(a[j - 1], a[j]) > 0; j--) swap(j, j - 1, a); return; } int pm = n / 2; // small arrays, middle element if ...
short r;
int r;
private static void qsort(byte[]a, int start, int n) { // use an insertion sort on small arrays if (n < 7) { for (int i = start + 1; i < start + n; i++) for (int j = i; j > 0 && cmp(a[j - 1], a[j]) > 0; j--) swap(j, j - 1, a); return; } int pm = n / 2; // small arrays, middle element if ...
while (pb <= pc && (r = cmp(a[pb], a[pv])) <= 0)
while (pb <= pc && (r = a[pb] - a[pv]) <= 0)
private static void qsort(byte[]a, int start, int n) { // use an insertion sort on small arrays if (n < 7) { for (int i = start + 1; i < start + n; i++) for (int j = i; j > 0 && cmp(a[j - 1], a[j]) > 0; j--) swap(j, j - 1, a); return; } int pm = n / 2; // small arrays, middle element if ...
while (pc >= pb && (r = cmp(a[pc], a[pv])) >= 0)
while (pc >= pb && (r = a[pc] - a[pv]) >= 0)
private static void qsort(byte[]a, int start, int n) { // use an insertion sort on small arrays if (n < 7) { for (int i = start + 1; i < start + n; i++) for (int j = i; j > 0 && cmp(a[j - 1], a[j]) > 0; j--) swap(j, j - 1, a); return; } int pm = n / 2; // small arrays, middle element if ...
StateTag stateTag = (StateTag) findAncestorWithClass( StateTag.class );
State state = null;
public void doTag(XMLOutput output) throws Exception { StateTag stateTag = (StateTag) findAncestorWithClass( StateTag.class ); if ( stateTag == null ) { throw new JellyException( "Unable to locate a state." ); } State state = stateTag.getState(); if ( state.ge...
if ( stateTag == null )
try { state = getCurrentState(); } catch (JellyException e)
public void doTag(XMLOutput output) throws Exception { StateTag stateTag = (StateTag) findAncestorWithClass( StateTag.class ); if ( stateTag == null ) { throw new JellyException( "Unable to locate a state." ); } State state = stateTag.getState(); if ( state.ge...
throw new JellyException( "Unable to locate a state." );
public void doTag(XMLOutput output) throws Exception { StateTag stateTag = (StateTag) findAncestorWithClass( StateTag.class ); if ( stateTag == null ) { throw new JellyException( "Unable to locate a state." ); } State state = stateTag.getState(); if ( state.ge...
State state = stateTag.getState();
if ( state != null ) { if ( state.getActivity() != null && ! ( state.getActivity() instanceof NoOpActivity ) ) { throw new JellyException( "Activity already defined for state \"" + state.getName() + "\"" ); } }
public void doTag(XMLOutput output) throws Exception { StateTag stateTag = (StateTag) findAncestorWithClass( StateTag.class ); if ( stateTag == null ) { throw new JellyException( "Unable to locate a state." ); } State state = stateTag.getState(); if ( state.ge...
if ( state.getActivity() != null && ! ( state.getActivity() instanceof NoOpActivity ) ) { throw new JellyException( "Activity already defined for state \"" + state.getName() + "\"" ); }
public void doTag(XMLOutput output) throws Exception { StateTag stateTag = (StateTag) findAncestorWithClass( StateTag.class ); if ( stateTag == null ) { throw new JellyException( "Unable to locate a state." ); } State state = stateTag.getState(); if ( state.ge...
state.setActivity( activity );
if ( getVar() != null ) { getContext().setVariable( getVar(), activity ); } if ( state != null ) { state.setActivity( activity ); }
public void doTag(XMLOutput output) throws Exception { StateTag stateTag = (StateTag) findAncestorWithClass( StateTag.class ); if ( stateTag == null ) { throw new JellyException( "Unable to locate a state." ); } State state = stateTag.getState(); if ( state.ge...