rem
stringlengths 0
477k
| add
stringlengths 0
313k
| context
stringlengths 6
599k
| meta
stringlengths 141
403
|
---|---|---|---|
} else if (operand instanceof Constant) {
|
} else if (refs[0] instanceof Constant) {
|
public void generateCode(CodeGenerator cg) { Variable lhs = getLHS(); Location lhsLoc = lhs.getLocation(); if (lhsLoc instanceof RegisterLocation) { RegisterLocation regLoc = (RegisterLocation) lhsLoc; Object lhsReg = regLoc.getRegister(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { // this probably won't happen, is should be folded earlier Constant con = (Constant) operand; cg.generateCodeFor(this, lhsReg, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else if (lhsLoc instanceof StackLocation) { StackLocation lhsStackLoc = (StackLocation) lhsLoc; int lhsDisp = lhsStackLoc.getDisplacement(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { Constant con = (Constant) operand; cg.generateCodeFor(this, lhsDisp, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else { throw new IllegalArgumentException("Unknown location: " + lhsLoc); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
Constant con = (Constant) operand;
|
Constant con = (Constant) refs[0];
|
public void generateCode(CodeGenerator cg) { Variable lhs = getLHS(); Location lhsLoc = lhs.getLocation(); if (lhsLoc instanceof RegisterLocation) { RegisterLocation regLoc = (RegisterLocation) lhsLoc; Object lhsReg = regLoc.getRegister(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { // this probably won't happen, is should be folded earlier Constant con = (Constant) operand; cg.generateCodeFor(this, lhsReg, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else if (lhsLoc instanceof StackLocation) { StackLocation lhsStackLoc = (StackLocation) lhsLoc; int lhsDisp = lhsStackLoc.getDisplacement(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { Constant con = (Constant) operand; cg.generateCodeFor(this, lhsDisp, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else { throw new IllegalArgumentException("Unknown location: " + lhsLoc); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
throw new IllegalArgumentException("Unknown operand: " + operand);
|
throw new IllegalArgumentException("Unknown operand: " + refs[0]);
|
public void generateCode(CodeGenerator cg) { Variable lhs = getLHS(); Location lhsLoc = lhs.getLocation(); if (lhsLoc instanceof RegisterLocation) { RegisterLocation regLoc = (RegisterLocation) lhsLoc; Object lhsReg = regLoc.getRegister(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { // this probably won't happen, is should be folded earlier Constant con = (Constant) operand; cg.generateCodeFor(this, lhsReg, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else if (lhsLoc instanceof StackLocation) { StackLocation lhsStackLoc = (StackLocation) lhsLoc; int lhsDisp = lhsStackLoc.getDisplacement(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { Constant con = (Constant) operand; cg.generateCodeFor(this, lhsDisp, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else { throw new IllegalArgumentException("Unknown location: " + lhsLoc); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
if (operand instanceof Variable) { Variable var = (Variable) operand;
|
if (refs[0] instanceof Variable) { Variable var = (Variable) refs[0];
|
public void generateCode(CodeGenerator cg) { Variable lhs = getLHS(); Location lhsLoc = lhs.getLocation(); if (lhsLoc instanceof RegisterLocation) { RegisterLocation regLoc = (RegisterLocation) lhsLoc; Object lhsReg = regLoc.getRegister(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { // this probably won't happen, is should be folded earlier Constant con = (Constant) operand; cg.generateCodeFor(this, lhsReg, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else if (lhsLoc instanceof StackLocation) { StackLocation lhsStackLoc = (StackLocation) lhsLoc; int lhsDisp = lhsStackLoc.getDisplacement(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { Constant con = (Constant) operand; cg.generateCodeFor(this, lhsDisp, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else { throw new IllegalArgumentException("Unknown location: " + lhsLoc); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
} else if (operand instanceof Constant) { Constant con = (Constant) operand;
|
} else if (refs[0] instanceof Constant) { Constant con = (Constant) refs[0];
|
public void generateCode(CodeGenerator cg) { Variable lhs = getLHS(); Location lhsLoc = lhs.getLocation(); if (lhsLoc instanceof RegisterLocation) { RegisterLocation regLoc = (RegisterLocation) lhsLoc; Object lhsReg = regLoc.getRegister(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { // this probably won't happen, is should be folded earlier Constant con = (Constant) operand; cg.generateCodeFor(this, lhsReg, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else if (lhsLoc instanceof StackLocation) { StackLocation lhsStackLoc = (StackLocation) lhsLoc; int lhsDisp = lhsStackLoc.getDisplacement(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { Constant con = (Constant) operand; cg.generateCodeFor(this, lhsDisp, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else { throw new IllegalArgumentException("Unknown location: " + lhsLoc); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
throw new IllegalArgumentException("Unknown operand: " + operand);
|
throw new IllegalArgumentException("Unknown operand: " + refs[0]);
|
public void generateCode(CodeGenerator cg) { Variable lhs = getLHS(); Location lhsLoc = lhs.getLocation(); if (lhsLoc instanceof RegisterLocation) { RegisterLocation regLoc = (RegisterLocation) lhsLoc; Object lhsReg = regLoc.getRegister(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsReg, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { // this probably won't happen, is should be folded earlier Constant con = (Constant) operand; cg.generateCodeFor(this, lhsReg, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else if (lhsLoc instanceof StackLocation) { StackLocation lhsStackLoc = (StackLocation) lhsLoc; int lhsDisp = lhsStackLoc.getDisplacement(); if (operand instanceof Variable) { Variable var = (Variable) operand; Location varLoc = var.getLocation(); if (varLoc instanceof RegisterLocation) { RegisterLocation vregLoc = (RegisterLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, vregLoc.getRegister()); } else if (varLoc instanceof StackLocation) { StackLocation stackLoc = (StackLocation) varLoc; cg.generateCodeFor(this, lhsDisp, operation, stackLoc.getDisplacement()); } else { throw new IllegalArgumentException("Unknown location: " + varLoc); } } else if (operand instanceof Constant) { Constant con = (Constant) operand; cg.generateCodeFor(this, lhsDisp, operation, con); } else { throw new IllegalArgumentException("Unknown operand: " + operand); } } else { throw new IllegalArgumentException("Unknown location: " + lhsLoc); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
return operand;
|
return refs[0];
|
public Operand getOperand() { return operand; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
OP_MAP[operation - I2L] + " " + operand.toString();
|
OP_MAP[operation - I2L] + " " + refs[0].toString();
|
public String toString() { return getAddress() + ": " + getLHS().toString() + " = " + OP_MAP[operation - I2L] + " " + operand.toString(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/568227fef1ae7ced51f104ef1af634c7a6188718/UnaryQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/UnaryQuad.java
|
public AssignQuad(int address, IRBasicBlock block, int lhsIndex) { this(address, block, block.getVariables()[lhsIndex]);
|
public AssignQuad(int address, IRBasicBlock block, Variable lhs) { super(address, block); setLHS(lhs);
|
public AssignQuad(int address, IRBasicBlock block, int lhsIndex) { this(address, block, block.getVariables()[lhsIndex]); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/51e4aed2205f326c2698e2154ea7f83ae5dfc2b6/AssignQuad.java/buggy/core/src/core/org/jnode/vm/compiler/ir/quad/AssignQuad.java
|
m.minor = Minor.UserException;
|
public static ValueMember read(InputStream istream) { try { ValueMember value = new ValueMember(); value.name = istream.read_string(); value.id = istream.read_string(); value.defined_in = istream.read_string(); value.version = istream.read_string(); value.type = TypeCodeHelper.read(istream); value.type_def = IDLTypeHelper.read(istream); value.access = istream.read_short(); return value; } catch (UserException ex) { MARSHAL m = new MARSHAL(); m.initCause(ex); throw m; } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/ValueMemberHelper.java/buggy/core/src/classpath/org/org/omg/CORBA/ValueMemberHelper.java
|
|
m.minor = Minor.UserException;
|
public static void write(OutputStream ostream, ValueMember value) { try { ostream.write_string(value.name); ostream.write_string(value.id); ostream.write_string(value.defined_in); ostream.write_string(value.version); TypeCodeHelper.write(ostream, value.type); IDLTypeHelper.write(ostream, value.type_def); ostream.write_short(value.access); } catch (UserException ex) { MARSHAL m = new MARSHAL(); m.initCause(ex); throw m; } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/ValueMemberHelper.java/buggy/core/src/classpath/org/org/omg/CORBA/ValueMemberHelper.java
|
|
NIOSocket socket = (NIOSocket) ((SocketChannelImpl) ch).socket(); return socket.getPlainSocketImpl().getNativeFD();
|
try { return ((SocketChannelImpl) ch).getVMChannel().getState().getNativeFD(); } catch (IOException ioe) { throw new IllegalStateException(ioe); }
|
public int getNativeFD() { NIOSocket socket = (NIOSocket) ((SocketChannelImpl) ch).socket(); return socket.getPlainSocketImpl().getNativeFD(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/7202d16ccc1adec85971720b757bc983cbd72c10/SocketChannelSelectionKey.java/buggy/core/src/classpath/gnu/gnu/java/nio/SocketChannelSelectionKey.java
|
if (event.modified)
|
public void insertString(int offset, String text, AttributeSet attributes) throws BadLocationException { // Just return when no text to insert was given. if (text == null || text.length() == 0) return; DefaultDocumentEvent event = new DefaultDocumentEvent(offset, text.length(), DocumentEvent.EventType.INSERT); writeLock(); UndoableEdit undo = content.insertString(offset, text); insertUpdate(event, attributes); writeUnlock(); if (event.modified) fireInsertUpdate(event); if (undo != null) fireUndoableEditUpdate(new UndoableEditEvent(this, undo)); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/a78ab2f492456918e4f5c52be600854882e139fc/AbstractDocument.java/clean/core/src/classpath/javax/javax/swing/text/AbstractDocument.java
|
|
if (appProps.containsKey("defaultPrinter")) { if (getStringProperty("defaultPrinter").equals("Yes")) defaultPrinter = true; else defaultPrinter = false; }
|
public void loadProps(Properties props) { appProps = props; loadColors(); if (appProps.containsKey("colSeparator")) { if (getStringProperty("colSeparator").equals("Line")) colSepLine = 0; if (getStringProperty("colSeparator").equals("ShortLine")) colSepLine = 1; if (getStringProperty("colSeparator").equals("Dot")) colSepLine = 2; } if (appProps.containsKey("showAttr")) { if (getStringProperty("showAttr").equals("Hex")) showHex = true; } if (appProps.containsKey("guiInterface")) { if (getStringProperty("guiInterface").equals("Yes")) guiInterface = true; else guiInterface = false; } if (appProps.containsKey("guiShowUnderline")) { if (getStringProperty("guiShowUnderline").equals("Yes")) guiShowUnderline = true; else guiShowUnderline = false; } if (appProps.containsKey("hotspots")) { if (getStringProperty("hotspots").equals("Yes")) hotSpots = true; else hotSpots = false; } if (appProps.containsKey("hsMore")) { if (getStringProperty("hsMore").length() > 0) { hsMore.setLength(0); hsMore.append(getStringProperty("hsMore")); } } if (appProps.containsKey("hsBottom")) { if (getStringProperty("hsBottom").length() > 0) { hsBottom.setLength(0); hsBottom.append(getStringProperty("hsBottom")); } } if (appProps.containsKey("colSeparator")) { if (getStringProperty("colSeparator").equals("Line")) colSepLine = 0; if (getStringProperty("colSeparator").equals("ShortLine")) colSepLine = 1; if (getStringProperty("colSeparator").equals("Dot")) colSepLine = 2; } if (appProps.containsKey("cursorSize")) { if (getStringProperty("cursorSize").equals("Full")) cursorSize = 2; if (getStringProperty("cursorSize").equals("Half")) cursorSize = 1; if (getStringProperty("cursorSize").equals("Line")) cursorSize = 0; } if (appProps.containsKey("crossHair")) { if (getStringProperty("crossHair").equals("None")) crossHair = 0; if (getStringProperty("crossHair").equals("Horz")) crossHair = 1; if (getStringProperty("crossHair").equals("Vert")) crossHair = 2; if (getStringProperty("crossHair").equals("Both")) crossHair = 3; } if (appProps.containsKey("fontScaleHeight")) { sfh = getFloatProperty("fontScaleHeight"); } if (appProps.containsKey("fontScaleWidth")) { sfw = getFloatProperty("fontScaleWidth"); } if (appProps.containsKey("fontPointSize")) { ps132 = getFloatProperty("fontPointSize"); } if (appProps.containsKey("cursorBottOffset")) { cursorBottOffset = getIntProperty("cursorBottOffset"); } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/bc7e11ab017c3feeba41d87e99dba276258b7c41/Screen5250.java/clean/tn5250j/src/org/tn5250j/Screen5250.java
|
|
public final void printMe() { Thread printerThread = new PrinterThread(screen, font, numCols, numRows, colorBg, (Session)gui); printerThread.start(); }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/bc7e11ab017c3feeba41d87e99dba276258b7c41/Screen5250.java/clean/tn5250j/src/org/tn5250j/Screen5250.java
|
||
if (pn.equals("defaultPrinter")) { if (pce.getNewValue().equals("Yes")) defaultPrinter = true; else defaultPrinter = false; }
|
public void propertyChange(PropertyChangeEvent pce) { String pn = pce.getPropertyName(); boolean resetAttr = false; if (pn.equals("colorBg")) { colorBg = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorBlue")) { colorBlue = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorTurq")) { colorTurq = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorRed")) { colorRed = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorWhite")) { colorWhite = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorYellow")) { colorYellow = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorGreen")) { colorGreen = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorPink")) { colorPink = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorGUIField")) { colorGUIField = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorCursor")) { colorCursor = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorSep")) { colorSep = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("colorHexAttr")) { colorHexAttr = (Color)pce.getNewValue(); resetAttr = true; } if (pn.equals("cursorSize")) { if (pce.getNewValue().equals("Full")) cursorSize = 2; if (pce.getNewValue().equals("Half")) cursorSize = 1; if (pce.getNewValue().equals("Line")) cursorSize = 0; } if (pn.equals("crossHair")) { if (pce.getNewValue().equals("None")) crossHair = 0; if (pce.getNewValue().equals("Horz")) crossHair = 1; if (pce.getNewValue().equals("Vert")) crossHair = 2; if (pce.getNewValue().equals("Both")) crossHair = 3; } if (pn.equals("colSeparator")) { if (pce.getNewValue().equals("Line")) colSepLine = 0; if (pce.getNewValue().equals("ShortLine")) colSepLine = 1; if (pce.getNewValue().equals("Dot")) colSepLine = 2; } if (pn.equals("showAttr")) { if (pce.getNewValue().equals("Hex")) showHex = true; else showHex= false; } if (pn.equals("guiInterface")) { if (pce.getNewValue().equals("Yes")) guiInterface = true; else guiInterface = false; } if (pn.equals("guiShowUnderline")) { if (pce.getNewValue().equals("Yes")) guiShowUnderline = true; else guiShowUnderline = false; } if (pn.equals("hotspots")) { if (pce.getNewValue().equals("Yes")) hotSpots = true; else hotSpots = false; } if (pn.equals("hsMore")) { hsMore.setLength(0); hsMore.append((String)pce.getNewValue()); } if (pn.equals("hsBottom")) { hsBottom.setLength(0); hsBottom.append((String)pce.getNewValue()); } if (pn.equals("font")) { font = new Font((String)pce.getNewValue(),Font.PLAIN,14); updateFont = true; } if (pn.equals("fontScaleHeight")) {// try { sfh = Float.parseFloat((String)pce.getNewValue()); updateFont = true;// } } if (pn.equals("fontScaleWidth")) {// try { sfw = Float.parseFloat((String)pce.getNewValue()); updateFont = true;// } } if (pn.equals("fontPointSize")) {// try { ps132 = Float.parseFloat((String)pce.getNewValue()); updateFont = true;// } } if (pn.equals("cursorBottOffset")) { cursorBottOffset = getIntProperty("cursorBottOffset"); } if (updateFont) { Rectangle r = gui.getDrawingBounds(); resizeScreenArea(r.width,r.height); updateFont = false; } if (resetAttr) { for (int y = 0;y < lenScreen; y++) { screen[y].setAttribute(screen[y].getCharAttr()); } bi.drawOIA(fmWidth,fmHeight,numRows,numCols,font,colorBg,colorBlue); } gui.validate(); gui.repaint(); }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/bc7e11ab017c3feeba41d87e99dba276258b7c41/Screen5250.java/clean/tn5250j/src/org/tn5250j/Screen5250.java
|
|
showMe = new JCheckBox(LangTool.getString("ss.labelShowMe")); if(props.containsKey("emul.showConnectDialog")) showMe.setSelected(true); showMe.addItemListener(new java.awt.event.ItemListener() { public void itemStateChanged(ItemEvent e) { showMe_itemStateChanged(e); } }); options.add(showMe);
|
void jbInit() throws Exception { // make it non resizable setResizable(true); this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE); // create some reusable borders and layouts Border etchedBorder = BorderFactory.createEtchedBorder(); BorderLayout borderLayout = new BorderLayout(); // get an instance of our table model ctm = new ConfigureTableModel(); // create a table using our custom table model sessions = new JSortTable(ctm); // Add enter as default key for connect with this session Action connect = new AbstractAction("connect") { public void actionPerformed(ActionEvent e) { doActionConnect(); } }; KeyStroke enter = KeyStroke.getKeyStroke(KeyEvent.VK_ENTER,0,false); sessions.getInputMap().put(enter,"connect"); sessions.getActionMap().put("connect",connect ); sessions.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); sessions.setPreferredScrollableViewportSize(new Dimension(500,200)); sessions.setShowGrid(false); //Create the scroll pane and add the table to it. scrollPane = new JScrollPane(sessions); scrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED); scrollPane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED); //Setup our selection model listener rowSM = sessions.getSelectionModel(); rowSM.addListSelectionListener(new ListSelectionListener() { public void valueChanged(ListSelectionEvent e) { //Ignore extra messages. if (e.getValueIsAdjusting()) return; ListSelectionModel lsm = (ListSelectionModel)e.getSource(); if (lsm.isSelectionEmpty()) { //no rows are selected editButton.setEnabled(false); removeButton.setEnabled(false); connectButton.setEnabled(false); } else { int selectedRow = lsm.getMinSelectionIndex(); //selectedRow is selected editButton.setEnabled(true); removeButton.setEnabled(true); connectButton.setEnabled(true); } } }); // setup the frame interface panel interfacePanel = new JPanel(); TitledBorder tb = BorderFactory.createTitledBorder( LangTool.getString("conf.labelPresentation")); interfacePanel.setBorder(tb); ButtonGroup intGroup = new ButtonGroup(); intTABS = new JRadioButton(LangTool.getString("conf.labelTABS")); intTABS.setSelected(true); intTABS.addItemListener(new java.awt.event.ItemListener() { public void itemStateChanged(ItemEvent e) { intTABS_itemStateChanged(e); } }); intMDI = new JRadioButton(LangTool.getString("conf.labelMDI")); // add the interface options to the group control intGroup.add(intTABS); intGroup.add(intMDI); if (props.containsKey("emul.interface")) { if (props.getProperty("emul.interface").equalsIgnoreCase("MDI")) intMDI.setSelected(true); } interfacePanel.add(intTABS); interfacePanel.add(intMDI); //Setup panels configOptions.setLayout(borderLayout); sessionPanel.setLayout(borderLayout); configOptions.add(sessionPanel, BorderLayout.CENTER); sessionOpts.add(scrollPane, BorderLayout.CENTER); sessionPanel.add(sessionOpts, BorderLayout.NORTH); sessionPanel.add(sessionOptPanel, BorderLayout.SOUTH); sessionPanel.setBorder(BorderFactory.createRaisedBevelBorder()); // add the option buttons addOptButton(LangTool.getString("ss.optAdd"),"ADD",sessionOptPanel); removeButton = addOptButton(LangTool.getString("ss.optDelete"), "REMOVE", sessionOptPanel, false); editButton = addOptButton(LangTool.getString("ss.optEdit"), "EDIT", sessionOptPanel, false); showMe = new JCheckBox(LangTool.getString("ss.labelShowMe")); if(props.containsKey("emul.showConnectDialog")) showMe.setSelected(true); showMe.addItemListener(new java.awt.event.ItemListener() { public void itemStateChanged(ItemEvent e) { showMe_itemStateChanged(e); } }); options.add(showMe); connectButton = addOptButton(LangTool.getString("ss.optConnect"), "CONNECT",options,false); applyButton = addOptButton(LangTool.getString("ss.optApply"), "APPLY",options,true); addOptButton(LangTool.getString("ss.optCancel"),"DONE",options); // add the panels to our dialog getContentPane().add(sessionPanel,BorderLayout.CENTER); getContentPane().add(options, BorderLayout.SOUTH); getContentPane().add(interfacePanel,BorderLayout.NORTH); // pack it and center it on the screen pack(); Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); Dimension frameSize = getSize(); if (frameSize.height > screenSize.height) frameSize.height = screenSize.height; if (frameSize.width > screenSize.width) frameSize.width = screenSize.width; setLocation((screenSize.width - frameSize.width) / 2, (screenSize.height - frameSize.height) / 2); // set default selection value as the first row or default session if (sessions.getRowCount() > 0) { int selInterval = 0; for (int x = 0; x < sessions.getRowCount(); x++) { if (((Boolean)ctm.getValueAt(x,2)).booleanValue()) selInterval = x; } sessions.getSelectionModel().setSelectionInterval(selInterval,selInterval); } sessions.requestFocus(); // now show the world what we and they can do this.setVisible(true); }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/69e4ad8b79244d7a9ead6ae9be5f21d5cf302742/Connect.java/buggy/tn5250j/src/org/tn5250j/Connect.java
|
|
getContentPane().add(interfacePanel,BorderLayout.NORTH);
|
getContentPane().add(emulOptPanel,BorderLayout.NORTH);
|
void jbInit() throws Exception { // make it non resizable setResizable(true); this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE); // create some reusable borders and layouts Border etchedBorder = BorderFactory.createEtchedBorder(); BorderLayout borderLayout = new BorderLayout(); // get an instance of our table model ctm = new ConfigureTableModel(); // create a table using our custom table model sessions = new JSortTable(ctm); // Add enter as default key for connect with this session Action connect = new AbstractAction("connect") { public void actionPerformed(ActionEvent e) { doActionConnect(); } }; KeyStroke enter = KeyStroke.getKeyStroke(KeyEvent.VK_ENTER,0,false); sessions.getInputMap().put(enter,"connect"); sessions.getActionMap().put("connect",connect ); sessions.setSelectionMode(ListSelectionModel.SINGLE_SELECTION); sessions.setPreferredScrollableViewportSize(new Dimension(500,200)); sessions.setShowGrid(false); //Create the scroll pane and add the table to it. scrollPane = new JScrollPane(sessions); scrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED); scrollPane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED); //Setup our selection model listener rowSM = sessions.getSelectionModel(); rowSM.addListSelectionListener(new ListSelectionListener() { public void valueChanged(ListSelectionEvent e) { //Ignore extra messages. if (e.getValueIsAdjusting()) return; ListSelectionModel lsm = (ListSelectionModel)e.getSource(); if (lsm.isSelectionEmpty()) { //no rows are selected editButton.setEnabled(false); removeButton.setEnabled(false); connectButton.setEnabled(false); } else { int selectedRow = lsm.getMinSelectionIndex(); //selectedRow is selected editButton.setEnabled(true); removeButton.setEnabled(true); connectButton.setEnabled(true); } } }); // setup the frame interface panel interfacePanel = new JPanel(); TitledBorder tb = BorderFactory.createTitledBorder( LangTool.getString("conf.labelPresentation")); interfacePanel.setBorder(tb); ButtonGroup intGroup = new ButtonGroup(); intTABS = new JRadioButton(LangTool.getString("conf.labelTABS")); intTABS.setSelected(true); intTABS.addItemListener(new java.awt.event.ItemListener() { public void itemStateChanged(ItemEvent e) { intTABS_itemStateChanged(e); } }); intMDI = new JRadioButton(LangTool.getString("conf.labelMDI")); // add the interface options to the group control intGroup.add(intTABS); intGroup.add(intMDI); if (props.containsKey("emul.interface")) { if (props.getProperty("emul.interface").equalsIgnoreCase("MDI")) intMDI.setSelected(true); } interfacePanel.add(intTABS); interfacePanel.add(intMDI); //Setup panels configOptions.setLayout(borderLayout); sessionPanel.setLayout(borderLayout); configOptions.add(sessionPanel, BorderLayout.CENTER); sessionOpts.add(scrollPane, BorderLayout.CENTER); sessionPanel.add(sessionOpts, BorderLayout.NORTH); sessionPanel.add(sessionOptPanel, BorderLayout.SOUTH); sessionPanel.setBorder(BorderFactory.createRaisedBevelBorder()); // add the option buttons addOptButton(LangTool.getString("ss.optAdd"),"ADD",sessionOptPanel); removeButton = addOptButton(LangTool.getString("ss.optDelete"), "REMOVE", sessionOptPanel, false); editButton = addOptButton(LangTool.getString("ss.optEdit"), "EDIT", sessionOptPanel, false); showMe = new JCheckBox(LangTool.getString("ss.labelShowMe")); if(props.containsKey("emul.showConnectDialog")) showMe.setSelected(true); showMe.addItemListener(new java.awt.event.ItemListener() { public void itemStateChanged(ItemEvent e) { showMe_itemStateChanged(e); } }); options.add(showMe); connectButton = addOptButton(LangTool.getString("ss.optConnect"), "CONNECT",options,false); applyButton = addOptButton(LangTool.getString("ss.optApply"), "APPLY",options,true); addOptButton(LangTool.getString("ss.optCancel"),"DONE",options); // add the panels to our dialog getContentPane().add(sessionPanel,BorderLayout.CENTER); getContentPane().add(options, BorderLayout.SOUTH); getContentPane().add(interfacePanel,BorderLayout.NORTH); // pack it and center it on the screen pack(); Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize(); Dimension frameSize = getSize(); if (frameSize.height > screenSize.height) frameSize.height = screenSize.height; if (frameSize.width > screenSize.width) frameSize.width = screenSize.width; setLocation((screenSize.width - frameSize.width) / 2, (screenSize.height - frameSize.height) / 2); // set default selection value as the first row or default session if (sessions.getRowCount() > 0) { int selInterval = 0; for (int x = 0; x < sessions.getRowCount(); x++) { if (((Boolean)ctm.getValueAt(x,2)).booleanValue()) selInterval = x; } sessions.getSelectionModel().setSelectionInterval(selInterval,selInterval); } sessions.requestFocus(); // now show the world what we and they can do this.setVisible(true); }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/69e4ad8b79244d7a9ead6ae9be5f21d5cf302742/Connect.java/buggy/tn5250j/src/org/tn5250j/Connect.java
|
public DebugGraphics(Graphics graphics)
|
public DebugGraphics()
|
public DebugGraphics(Graphics graphics) { this.graphics = graphics; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/50cfc3ee73e2e377b07c91f0e40a2f172b10fd27/DebugGraphics.java/clean/core/src/classpath/javax/javax/swing/DebugGraphics.java
|
this.graphics = graphics;
|
public DebugGraphics(Graphics graphics) { this.graphics = graphics; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/50cfc3ee73e2e377b07c91f0e40a2f172b10fd27/DebugGraphics.java/clean/core/src/classpath/javax/javax/swing/DebugGraphics.java
|
|
ExceptionList exceptions, ContextList ctx_list )
|
ExceptionList exceptions, ContextList ctx_list)
|
public Request create_request(org.omg.CORBA.Object target, Context context, String method, NVList parameters, NamedValue returns, ExceptionList exceptions, ContextList ctx_list ) { operation = method; LocalRequest rq = new LocalRequest(object, poa, Id); rq.setOperation(method); rq.set_args(parameters); rq.set_result(returns); rq.set_exceptions(exceptions); rq.set_context_list(ctx_list); return rq; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/LocalDelegate.java/buggy/core/src/classpath/gnu/gnu/CORBA/Poa/LocalDelegate.java
|
InvokeHandler handler = lr.object.getHandler(lr.operation(), lr.cookie, false);
|
InvokeHandler handler = lr.object.getHandler(lr.operation(), lr.cookie, false);
|
public InputStream invoke(org.omg.CORBA.Object target, OutputStream output) throws ApplicationException { try { streamRequest sr = (streamRequest) output; LocalRequest lr = (LocalRequest) sr.request; InvokeHandler handler = lr.object.getHandler(lr.operation(), lr.cookie, false); if (handler instanceof dynImpHandler) { // The local request known how to handle it, but the different // method must be called. lr.invoke(); // The encapsulation will inherit orb, endian, charsets, etc. cdrOutput buf = sr.createEncapsulation(); // Write all request parameters to the buffer stream. if (lr.env().exception() != null) { try { UnknownUserException uex = (UnknownUserException) lr.env().exception(); throw new ApplicationException(uex.except.type().id(), uex.except.create_input_stream() ); } catch (BadKind ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } } if (lr.return_value() != null) lr.return_value().write_value(buf); NamedValue a; try { for (int i = 0; i < lr.arguments().count(); i++) { a = lr.arguments().item(i); if (a.flags() == ARG_INOUT.value || a.flags() == ARG_INOUT.value ) { a.value().write_value(buf); } } } catch (Bounds ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } return buf.create_input_stream(); } else { LocalRequest lrq = (LocalRequest) sr.request; return lrq.s_invoke(handler); } } catch (gnuForwardRequest f) { try { return ((ObjectImpl) f.forward_reference)._invoke(f.forward_reference._request( operation, true ) ); } catch (RemarshalException e) { // Never thrown in this place by Classpath implementation. throw new NO_IMPLEMENT(); } } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/LocalDelegate.java/buggy/core/src/classpath/gnu/gnu/CORBA/Poa/LocalDelegate.java
|
UnknownUserException uex = (UnknownUserException) lr.env().exception();
|
UnknownUserException uex = (UnknownUserException) lr.env().exception();
|
public InputStream invoke(org.omg.CORBA.Object target, OutputStream output) throws ApplicationException { try { streamRequest sr = (streamRequest) output; LocalRequest lr = (LocalRequest) sr.request; InvokeHandler handler = lr.object.getHandler(lr.operation(), lr.cookie, false); if (handler instanceof dynImpHandler) { // The local request known how to handle it, but the different // method must be called. lr.invoke(); // The encapsulation will inherit orb, endian, charsets, etc. cdrOutput buf = sr.createEncapsulation(); // Write all request parameters to the buffer stream. if (lr.env().exception() != null) { try { UnknownUserException uex = (UnknownUserException) lr.env().exception(); throw new ApplicationException(uex.except.type().id(), uex.except.create_input_stream() ); } catch (BadKind ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } } if (lr.return_value() != null) lr.return_value().write_value(buf); NamedValue a; try { for (int i = 0; i < lr.arguments().count(); i++) { a = lr.arguments().item(i); if (a.flags() == ARG_INOUT.value || a.flags() == ARG_INOUT.value ) { a.value().write_value(buf); } } } catch (Bounds ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } return buf.create_input_stream(); } else { LocalRequest lrq = (LocalRequest) sr.request; return lrq.s_invoke(handler); } } catch (gnuForwardRequest f) { try { return ((ObjectImpl) f.forward_reference)._invoke(f.forward_reference._request( operation, true ) ); } catch (RemarshalException e) { // Never thrown in this place by Classpath implementation. throw new NO_IMPLEMENT(); } } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/LocalDelegate.java/buggy/core/src/classpath/gnu/gnu/CORBA/Poa/LocalDelegate.java
|
uex.except.create_input_stream() );
|
uex.except.create_input_stream());
|
public InputStream invoke(org.omg.CORBA.Object target, OutputStream output) throws ApplicationException { try { streamRequest sr = (streamRequest) output; LocalRequest lr = (LocalRequest) sr.request; InvokeHandler handler = lr.object.getHandler(lr.operation(), lr.cookie, false); if (handler instanceof dynImpHandler) { // The local request known how to handle it, but the different // method must be called. lr.invoke(); // The encapsulation will inherit orb, endian, charsets, etc. cdrOutput buf = sr.createEncapsulation(); // Write all request parameters to the buffer stream. if (lr.env().exception() != null) { try { UnknownUserException uex = (UnknownUserException) lr.env().exception(); throw new ApplicationException(uex.except.type().id(), uex.except.create_input_stream() ); } catch (BadKind ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } } if (lr.return_value() != null) lr.return_value().write_value(buf); NamedValue a; try { for (int i = 0; i < lr.arguments().count(); i++) { a = lr.arguments().item(i); if (a.flags() == ARG_INOUT.value || a.flags() == ARG_INOUT.value ) { a.value().write_value(buf); } } } catch (Bounds ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } return buf.create_input_stream(); } else { LocalRequest lrq = (LocalRequest) sr.request; return lrq.s_invoke(handler); } } catch (gnuForwardRequest f) { try { return ((ObjectImpl) f.forward_reference)._invoke(f.forward_reference._request( operation, true ) ); } catch (RemarshalException e) { // Never thrown in this place by Classpath implementation. throw new NO_IMPLEMENT(); } } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/LocalDelegate.java/buggy/core/src/classpath/gnu/gnu/CORBA/Poa/LocalDelegate.java
|
if (a.flags() == ARG_INOUT.value || a.flags() == ARG_INOUT.value )
|
if (a.flags() == ARG_INOUT.value || a.flags() == ARG_INOUT.value)
|
public InputStream invoke(org.omg.CORBA.Object target, OutputStream output) throws ApplicationException { try { streamRequest sr = (streamRequest) output; LocalRequest lr = (LocalRequest) sr.request; InvokeHandler handler = lr.object.getHandler(lr.operation(), lr.cookie, false); if (handler instanceof dynImpHandler) { // The local request known how to handle it, but the different // method must be called. lr.invoke(); // The encapsulation will inherit orb, endian, charsets, etc. cdrOutput buf = sr.createEncapsulation(); // Write all request parameters to the buffer stream. if (lr.env().exception() != null) { try { UnknownUserException uex = (UnknownUserException) lr.env().exception(); throw new ApplicationException(uex.except.type().id(), uex.except.create_input_stream() ); } catch (BadKind ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } } if (lr.return_value() != null) lr.return_value().write_value(buf); NamedValue a; try { for (int i = 0; i < lr.arguments().count(); i++) { a = lr.arguments().item(i); if (a.flags() == ARG_INOUT.value || a.flags() == ARG_INOUT.value ) { a.value().write_value(buf); } } } catch (Bounds ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } return buf.create_input_stream(); } else { LocalRequest lrq = (LocalRequest) sr.request; return lrq.s_invoke(handler); } } catch (gnuForwardRequest f) { try { return ((ObjectImpl) f.forward_reference)._invoke(f.forward_reference._request( operation, true ) ); } catch (RemarshalException e) { // Never thrown in this place by Classpath implementation. throw new NO_IMPLEMENT(); } } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/LocalDelegate.java/buggy/core/src/classpath/gnu/gnu/CORBA/Poa/LocalDelegate.java
|
operation, true ) );
|
operation, true));
|
public InputStream invoke(org.omg.CORBA.Object target, OutputStream output) throws ApplicationException { try { streamRequest sr = (streamRequest) output; LocalRequest lr = (LocalRequest) sr.request; InvokeHandler handler = lr.object.getHandler(lr.operation(), lr.cookie, false); if (handler instanceof dynImpHandler) { // The local request known how to handle it, but the different // method must be called. lr.invoke(); // The encapsulation will inherit orb, endian, charsets, etc. cdrOutput buf = sr.createEncapsulation(); // Write all request parameters to the buffer stream. if (lr.env().exception() != null) { try { UnknownUserException uex = (UnknownUserException) lr.env().exception(); throw new ApplicationException(uex.except.type().id(), uex.except.create_input_stream() ); } catch (BadKind ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } } if (lr.return_value() != null) lr.return_value().write_value(buf); NamedValue a; try { for (int i = 0; i < lr.arguments().count(); i++) { a = lr.arguments().item(i); if (a.flags() == ARG_INOUT.value || a.flags() == ARG_INOUT.value ) { a.value().write_value(buf); } } } catch (Bounds ex) { InternalError ierr = new InternalError(); ierr.initCause(ex); throw ierr; } return buf.create_input_stream(); } else { LocalRequest lrq = (LocalRequest) sr.request; return lrq.s_invoke(handler); } } catch (gnuForwardRequest f) { try { return ((ObjectImpl) f.forward_reference)._invoke(f.forward_reference._request( operation, true ) ); } catch (RemarshalException e) { // Never thrown in this place by Classpath implementation. throw new NO_IMPLEMENT(); } } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/LocalDelegate.java/buggy/core/src/classpath/gnu/gnu/CORBA/Poa/LocalDelegate.java
|
org.omg.CORBA.Object other )
|
org.omg.CORBA.Object other)
|
public boolean is_equivalent(org.omg.CORBA.Object target, org.omg.CORBA.Object other ) { if (target == other) return true; else if (target instanceof ObjectImpl && other instanceof ObjectImpl) { org.omg.CORBA.portable.Delegate a = null; org.omg.CORBA.portable.Delegate b = null; try { a = ((ObjectImpl) target)._get_delegate(); b = ((ObjectImpl) other)._get_delegate(); } catch (Exception ex) { // Unable to get one of the delegates. return false; } if (a instanceof LocalDelegate && b instanceof LocalDelegate) { byte[] k1 = ((LocalDelegate) a).Id; byte[] k2 = ((LocalDelegate) b).Id; return Arrays.equals(k1, k2); } else return false; } else return false; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/44e3ea509d80974dab547c4d1cf8c070d32bac86/LocalDelegate.java/buggy/core/src/classpath/gnu/gnu/CORBA/Poa/LocalDelegate.java
|
return result;
|
protected PrivateKey engineGeneratePrivate(KeySpec keySpec) throws InvalidKeySpecException { if (keySpec instanceof DSAPrivateKeySpec) { DSAPrivateKeySpec spec = (DSAPrivateKeySpec) keySpec; BigInteger p = spec.getP(); BigInteger q = spec.getQ(); BigInteger g = spec.getG(); BigInteger x = spec.getX(); return new DSSPrivateKey(Registry.PKCS8_ENCODING_ID, p, q, g, x); } if (keySpec instanceof PKCS8EncodedKeySpec) { PKCS8EncodedKeySpec spec = (PKCS8EncodedKeySpec) keySpec; byte[] encoded = spec.getEncoded(); PrivateKey result; try { result = new DSSKeyPairPKCS8Codec().decodePrivateKey(encoded); } catch (RuntimeException x) { InvalidKeySpecException y = new InvalidKeySpecException(); y.initCause(x); throw y; } } throw new InvalidKeySpecException("Unsupported (private) key specification"); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b9aa2b76c5fb6ec27c94f7eecf71cb3bc137fe2f/DSSKeyFactory.java/clean/core/src/classpath/gnu/gnu/java/security/jce/sig/DSSKeyFactory.java
|
|
return result;
|
protected PublicKey engineGeneratePublic(KeySpec keySpec) throws InvalidKeySpecException { if (keySpec instanceof DSAPublicKeySpec) { DSAPublicKeySpec spec = (DSAPublicKeySpec) keySpec; BigInteger p = spec.getP(); BigInteger q = spec.getQ(); BigInteger g = spec.getG(); BigInteger y = spec.getY(); return new DSSPublicKey(Registry.X509_ENCODING_ID, p, q, g, y); } if (keySpec instanceof X509EncodedKeySpec) { X509EncodedKeySpec spec = (X509EncodedKeySpec) keySpec; byte[] encoded = spec.getEncoded(); PublicKey result; try { result = new DSSKeyPairX509Codec().decodePublicKey(encoded); } catch (RuntimeException x) { InvalidKeySpecException y = new InvalidKeySpecException(); y.initCause(x); throw y; } } throw new InvalidKeySpecException("Unsupported (public) key specification"); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b9aa2b76c5fb6ec27c94f7eecf71cb3bc137fe2f/DSSKeyFactory.java/clean/core/src/classpath/gnu/gnu/java/security/jce/sig/DSSKeyFactory.java
|
|
public void mouseWheelMoved(MouseWheelEvent event) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicScrollPaneUI.java/buggy/core/src/classpath/javax/javax/swing/plaf/basic/BasicScrollPaneUI.java
|
||
viewportInsets = viewportBorder.getBorderInsets(parent);
|
viewportInsets = viewportBorder.getBorderInsets(parent);
|
public Dimension minimumLayoutSize(Container parent) { if (parent instanceof JScrollPane) { JScrollPane sc = (JScrollPane) parent; synchronized (sc.getTreeLock ()) { Dimension insetsSize = new Dimension(0,0); Dimension viewportSize = new Dimension(0,0); Dimension viewportInsetsSize = new Dimension(0,0); Dimension columnHeaderSize = new Dimension(0,0); Dimension rowHeaderSize = new Dimension(0,0); Dimension verticalScrollBarSize = new Dimension(0,0); Dimension horizontalScrollBarSize = new Dimension(0,0); Insets insets = sc.getInsets(); Border viewportBorder = sc.getViewportBorder(); Insets viewportInsets = null; if (viewportBorder != null) { viewportInsets = viewportBorder.getBorderInsets(parent); if (viewportInsets != null) viewportInsetsSize.setSize(viewportInsets.left + viewportInsets.right, viewportInsets.top + viewportInsets.bottom); } if (insets != null) insetsSize.setSize(insets.left + insets.right, insets.top + insets.bottom); maybeSetMinimumSize(colHead, columnHeaderSize); maybeSetMinimumSize(rowHead, rowHeaderSize); if (vsbPolicy != VERTICAL_SCROLLBAR_NEVER) maybeSetMinimumSize(vsb, verticalScrollBarSize); if (hsbPolicy != HORIZONTAL_SCROLLBAR_NEVER) maybeSetMinimumSize(hsb, horizontalScrollBarSize); return new Dimension(insetsSize.width + viewportSize.width + viewportInsetsSize.width + rowHeaderSize.width + verticalScrollBarSize.width, insetsSize.height + viewportSize.height + viewportInsetsSize.height + columnHeaderSize.height + horizontalScrollBarSize.height); } } else { return new Dimension(0,0); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/3826e72d9ebe31a854c4d01d6c8f1ec65a8d80fe/ScrollPaneLayout.java/buggy/core/src/classpath/javax/javax/swing/ScrollPaneLayout.java
|
public Dimension minimumLayoutSize(Container parent) { if (parent instanceof JScrollPane) { JScrollPane sc = (JScrollPane) parent; synchronized (sc.getTreeLock ()) { Dimension insetsSize = new Dimension(0,0); Dimension viewportSize = new Dimension(0,0); Dimension viewportInsetsSize = new Dimension(0,0); Dimension columnHeaderSize = new Dimension(0,0); Dimension rowHeaderSize = new Dimension(0,0); Dimension verticalScrollBarSize = new Dimension(0,0); Dimension horizontalScrollBarSize = new Dimension(0,0); Insets insets = sc.getInsets(); Border viewportBorder = sc.getViewportBorder(); Insets viewportInsets = null; if (viewportBorder != null) { viewportInsets = viewportBorder.getBorderInsets(parent); if (viewportInsets != null) viewportInsetsSize.setSize(viewportInsets.left + viewportInsets.right, viewportInsets.top + viewportInsets.bottom); } if (insets != null) insetsSize.setSize(insets.left + insets.right, insets.top + insets.bottom); maybeSetMinimumSize(colHead, columnHeaderSize); maybeSetMinimumSize(rowHead, rowHeaderSize); if (vsbPolicy != VERTICAL_SCROLLBAR_NEVER) maybeSetMinimumSize(vsb, verticalScrollBarSize); if (hsbPolicy != HORIZONTAL_SCROLLBAR_NEVER) maybeSetMinimumSize(hsb, horizontalScrollBarSize); return new Dimension(insetsSize.width + viewportSize.width + viewportInsetsSize.width + rowHeaderSize.width + verticalScrollBarSize.width, insetsSize.height + viewportSize.height + viewportInsetsSize.height + columnHeaderSize.height + horizontalScrollBarSize.height); } } else { return new Dimension(0,0); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/3826e72d9ebe31a854c4d01d6c8f1ec65a8d80fe/ScrollPaneLayout.java/buggy/core/src/classpath/javax/javax/swing/ScrollPaneLayout.java
|
||
public Dimension minimumLayoutSize(Container parent) { if (parent instanceof JScrollPane) { JScrollPane sc = (JScrollPane) parent; synchronized (sc.getTreeLock ()) { Dimension insetsSize = new Dimension(0,0); Dimension viewportSize = new Dimension(0,0); Dimension viewportInsetsSize = new Dimension(0,0); Dimension columnHeaderSize = new Dimension(0,0); Dimension rowHeaderSize = new Dimension(0,0); Dimension verticalScrollBarSize = new Dimension(0,0); Dimension horizontalScrollBarSize = new Dimension(0,0); Insets insets = sc.getInsets(); Border viewportBorder = sc.getViewportBorder(); Insets viewportInsets = null; if (viewportBorder != null) { viewportInsets = viewportBorder.getBorderInsets(parent); if (viewportInsets != null) viewportInsetsSize.setSize(viewportInsets.left + viewportInsets.right, viewportInsets.top + viewportInsets.bottom); } if (insets != null) insetsSize.setSize(insets.left + insets.right, insets.top + insets.bottom); maybeSetMinimumSize(colHead, columnHeaderSize); maybeSetMinimumSize(rowHead, rowHeaderSize); if (vsbPolicy != VERTICAL_SCROLLBAR_NEVER) maybeSetMinimumSize(vsb, verticalScrollBarSize); if (hsbPolicy != HORIZONTAL_SCROLLBAR_NEVER) maybeSetMinimumSize(hsb, horizontalScrollBarSize); return new Dimension(insetsSize.width + viewportSize.width + viewportInsetsSize.width + rowHeaderSize.width + verticalScrollBarSize.width, insetsSize.height + viewportSize.height + viewportInsetsSize.height + columnHeaderSize.height + horizontalScrollBarSize.height); } } else { return new Dimension(0,0); } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/3826e72d9ebe31a854c4d01d6c8f1ec65a8d80fe/ScrollPaneLayout.java/buggy/core/src/classpath/javax/javax/swing/ScrollPaneLayout.java
|
||
public CharacterBreakIterator() {
|
public CharacterBreakIterator () {
|
public CharacterBreakIterator() { iter = null; // FIXME? }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
public Object clone() { return new CharacterBreakIterator(this);
|
public Object clone () { return new CharacterBreakIterator (this);
|
public Object clone() { return new CharacterBreakIterator(this); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
private final boolean isHighSurrogate(char c) {
|
private final boolean isHighSurrogate (char c) {
|
private final boolean isHighSurrogate(char c) { return c >= highSurrogateStart && c <= highSurrogateEnd; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
private final boolean isL(char c) {
|
private final boolean isL (char c) {
|
private final boolean isL(char c) { return c >= LBase && c <= LBase + LCount; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
private final boolean isLVT(char c) { return isL(c) || isV(c) || isT(c);
|
private final boolean isLVT (char c) { return isL (c) || isV (c) || isT (c);
|
private final boolean isLVT(char c) { return isL(c) || isV(c) || isT(c); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
private final boolean isLowSurrogate(char c) {
|
private final boolean isLowSurrogate (char c) {
|
private final boolean isLowSurrogate(char c) { return c >= lowSurrogateStart && c <= lowSurrogateEnd; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
private final boolean isT(char c) {
|
private final boolean isT (char c) {
|
private final boolean isT(char c) { return c >= TBase && c <= TBase + TCount; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
private final boolean isV(char c) {
|
private final boolean isV (char c) {
|
private final boolean isV(char c) { return c >= VBase && c <= VBase + VCount; }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
public int next() {
|
public int next () {
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) {
|
for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) {
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead))
|
if (aheadType != Character.NON_SPACING_MARK && ! isLowSurrogate (ahead) && ! isLVT (ahead))
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (!isLVT(c) && isLVT(ahead))
|
if (! isLVT (c) && isLVT (ahead))
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK)
|
if (isL (c) && ! isLVT (ahead) && aheadType != Character.NON_SPACING_MARK)
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK)
|
if (isV (c) && ! isV (ahead) && !isT (ahead) && aheadType != Character.NON_SPACING_MARK)
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK)
|
if (isT (c) && ! isT (ahead) && aheadType != Character.NON_SPACING_MARK)
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (!isHighSurrogate(c) && isLowSurrogate(ahead))
|
if (! isHighSurrogate (c) && isLowSurrogate (ahead))
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (isHighSurrogate(c) && !isLowSurrogate(ahead))
|
if (isHighSurrogate (c) && ! isLowSurrogate (ahead))
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (!isHighSurrogate(prev) && isLowSurrogate(c))
|
if (! isHighSurrogate (prev) && isLowSurrogate (c))
|
public int next() { int end = iter.getEndIndex(); if (iter.getIndex() == end) return DONE; char c; for (char prev = CharacterIterator.DONE; iter.getIndex() < end; prev = c) { c = iter.next(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); // Break after paragraph separators. if (type == Character.PARAGRAPH_SEPARATOR) break; // Now we need some lookahead. char ahead = iter.next(); iter.previous(); if (ahead == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType != Character.NON_SPACING_MARK && !isLowSurrogate(ahead) && !isLVT(ahead)) break; if (!isLVT(c) && isLVT(ahead)) break; if (isL(c) && !isLVT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isV(c) && !isV(ahead) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (isT(c) && !isT(ahead) && aheadType != Character.NON_SPACING_MARK) break; if (!isHighSurrogate(c) && isLowSurrogate(ahead)) break; if (isHighSurrogate(c) && !isLowSurrogate(ahead)) break; if (!isHighSurrogate(prev) && isLowSurrogate(c)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
public int previous() {
|
public int previous () {
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
while (iter.getIndex() >= iter.getBeginIndex()) {
|
int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) {
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c))
|
if (type != Character.NON_SPACING_MARK && ! isLowSurrogate (c) && ! isLVT (c))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (ahead == CharacterIterator.DONE) {
|
if (ahead == CharacterIterator.DONE) {
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (isLVT(c) && !isLVT(ahead))
|
if (isLVT (c) && ! isLVT (ahead))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead))
|
if (! isLVT (c) && type != Character.NON_SPACING_MARK && isL (ahead))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead))
|
if (! isV (c) && ! isT (c) && type != Character.NON_SPACING_MARK && isV (ahead))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead))
|
if (! isT (c) && type != Character.NON_SPACING_MARK && isT (ahead))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (isLowSurrogate(c) && !isHighSurrogate(ahead))
|
if (isLowSurrogate (c) && ! isHighSurrogate (ahead))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (!isLowSurrogate(c) && isHighSurrogate(ahead))
|
if (! isLowSurrogate (c) && isHighSurrogate (ahead))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2))
|
if (isLowSurrogate (ahead) && ! isHighSurrogate (ahead2))
|
public int previous() { if (iter.getIndex() == iter.getBeginIndex()) return DONE; //int start = iter.getBeginIndex(); while (iter.getIndex() >= iter.getBeginIndex()) { char c = iter.previous(); if (c == CharacterIterator.DONE) break; int type = Character.getType(c); if (type != Character.NON_SPACING_MARK && !isLowSurrogate(c) && !isLVT(c)) break; // Now we need some lookahead. char ahead = iter.previous(); if (ahead == CharacterIterator.DONE) { iter.next(); break; } char ahead2 = iter.previous(); iter.next(); iter.next(); if (ahead2 == CharacterIterator.DONE) break; int aheadType = Character.getType(ahead); if (aheadType == Character.PARAGRAPH_SEPARATOR) break; if (isLVT(c) && !isLVT(ahead)) break; if (!isLVT(c) && type != Character.NON_SPACING_MARK && isL(ahead)) break; if (!isV(c) && !isT(c) && type != Character.NON_SPACING_MARK && isV(ahead)) break; if (!isT(c) && type != Character.NON_SPACING_MARK && isT(ahead)) break; if (isLowSurrogate(c) && !isHighSurrogate(ahead)) break; if (!isLowSurrogate(c) && isHighSurrogate(ahead)) break; if (isLowSurrogate(ahead) && !isHighSurrogate(ahead2)) break; } return iter.getIndex(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/b5af1a0dd02ba16d1f4f4556ab34fa51c2db060d/CharacterBreakIterator.java/clean/core/src/classpath/gnu/gnu/java/text/CharacterBreakIterator.java
|
else { Component comp = comboBox.getEditor().getEditorComponent(); Dimension prefSize = comp.getPreferredSize(); int width = prefSize.width; int height = prefSize.height + 2; Object prototype = comboBox.getPrototypeDisplayValue(); if (prototype != null) { FontMetrics fm = comboBox.getFontMetrics(comboBox.getFont()); width = Math.max(width, fm.stringWidth(prototype.toString()) + 2); } displaySize = new Dimension(width, height); return displaySize; } }
|
protected Dimension getDisplaySize() { Object prototype = comboBox.getPrototypeDisplayValue(); if (prototype != null) { // calculate result based on prototype ListCellRenderer renderer = comboBox.getRenderer(); Component comp = renderer.getListCellRendererComponent(listBox, prototype, -1, false, false); Dimension compSize = comp.getPreferredSize(); compSize.width += 2; // add 1 pixel margin around area compSize.height += 2; return compSize; } else { ComboBoxModel model = comboBox.getModel(); int numItems = model.getSize(); // if combo box doesn't have any items then simply // return its default size if (numItems == 0) { displaySize = getDefaultSize(); return displaySize; } Dimension size = new Dimension(0, 0); // ComboBox's display size should be equal to the // size of the largest item in the combo box. ListCellRenderer renderer = comboBox.getRenderer(); for (int i = 0; i < numItems; i++) { Object item = model.getElementAt(i); Component comp = renderer.getListCellRendererComponent(listBox, item, -1, false, false); Dimension compSize = comp.getPreferredSize(); if (compSize.width + 2 > size.width) size.width = compSize.width + 2; if (compSize.height + 2 > size.height) size.height = compSize.height + 2; } displaySize = size; return displaySize; } }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/4f54b4c49f6326d2bfe26573a0af55c73b713f0a/BasicComboBoxUI.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboBoxUI.java
|
|
comboBox.setEditor(createEditor()); editor = comboBox.getEditor().getEditorComponent();
|
currentEditor = createEditor(); comboBox.setEditor(currentEditor);
|
protected void installComponents() { // create drop down list of items popup = createPopup(); listBox = popup.getList(); // set editor and renderer for the combo box. Editor is used // only if combo box becomes editable, otherwise renderer is used // to paint the selected item; combobox is not editable by default. comboBox.setRenderer(createRenderer()); // create and install arrow button arrowButton = createArrowButton(); configureArrowButton(); comboBox.add(arrowButton); ComboBoxEditor currentEditor = comboBox.getEditor(); if (currentEditor == null || currentEditor instanceof UIResource) { comboBox.setEditor(createEditor()); editor = comboBox.getEditor().getEditorComponent(); } comboBox.revalidate(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/4f54b4c49f6326d2bfe26573a0af55c73b713f0a/BasicComboBoxUI.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboBoxUI.java
|
editor = currentEditor.getEditorComponent();
|
protected void installComponents() { // create drop down list of items popup = createPopup(); listBox = popup.getList(); // set editor and renderer for the combo box. Editor is used // only if combo box becomes editable, otherwise renderer is used // to paint the selected item; combobox is not editable by default. comboBox.setRenderer(createRenderer()); // create and install arrow button arrowButton = createArrowButton(); configureArrowButton(); comboBox.add(arrowButton); ComboBoxEditor currentEditor = comboBox.getEditor(); if (currentEditor == null || currentEditor instanceof UIResource) { comboBox.setEditor(createEditor()); editor = comboBox.getEditor().getEditorComponent(); } comboBox.revalidate(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/4f54b4c49f6326d2bfe26573a0af55c73b713f0a/BasicComboBoxUI.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboBoxUI.java
|
|
JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt);
|
if (!isEMailAvailable()) {
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")};
|
JOptionPane.showMessageDialog(parent, "The Java E-Mail API can not be found or is not installed\n" + "Please read e-mail.txt file for installation instructions." ,"Error", JOptionPane.ERROR_MESSAGE,null);
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, message, LangTool.getString("em.title"), JOptionPane.DEFAULT_OPTION, JOptionPane.QUESTION_MESSAGE, null, options, options[0] );
|
} else { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt);
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
switch(result) { case 0: SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText());
|
Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")};
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0;
|
int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, message, LangTool.getString("em.title"), JOptionPane.DEFAULT_OPTION, JOptionPane.QUESTION_MESSAGE, null, options, options[0] ); switch(result) { case 0: SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; }
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
}
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
|
sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent");
|
sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent");
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
break; case 1: break; case 2: SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); break; default: break;
|
break; case 1: break; case 2: SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); break; default: break; }
|
public SendEMailDialog(Frame parent, Screen5250 screen ) { JPanel semp = new JPanel(); semp.setLayout(new AlignLayout(2,5,5)); JLabel tol = new JLabel(LangTool.getString("em.to")); JTextField tot = new JTextField(30); JLabel subl = new JLabel(LangTool.getString("em.subject")); JTextField subt = new JTextField(30); JLabel fnl = new JLabel(LangTool.getString("em.fileName")); JTextField fnt = new JTextField("tn5250j.txt",30); semp.add(tol); semp.add(tot); semp.add(subl); semp.add(subt); semp.add(fnl); semp.add(fnt); Object[] message = new Object[1]; message[0] = semp; String[] options = {LangTool.getString("em.optSendLabel"), LangTool.getString("em.optCancelLabel"), LangTool.getString("em.optConfigureLabel")}; int result = 0; while (result == 0 || result == 2) { result = JOptionPane.showOptionDialog( parent, // the parent that the dialog blocks message, // the dialog message array LangTool.getString("em.title"), // the title of the dialog window JOptionPane.DEFAULT_OPTION, // option type JOptionPane.QUESTION_MESSAGE, // message type null, // optional icon, use null to use the default icon options, // options string array, will be made into buttons// options[0] // option that should be made into a default button ); switch(result) { case 0: // Send it SendEMail sem = new SendEMail(); sem.setConfigFile("SMTPProperties.cfg"); sem.setTo(tot.getText()); sem.setSubject(subt.getText()); if (fnt.getText().length() > 0) sem.setFileName(fnt.getText()); StringBuffer sb = new StringBuffer(); char[] s = screen.getScreenAsChars(); int c = screen.getCols(); int l = screen.getRows() * c; int col = 0; for (int x = 0; x < l; x++,col++) { sb.append(s[x]); if (col == c) { sb.append('\n'); col = 0; } } sem.setMessage(sb.toString()); try { sem.send(); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } sem.release(); sem = null; System.out.println("Message sent"); break; case 1: // Cancel // System.out.println("Cancel"); break; case 2: // Configure SMTP SMTPConfig smtp = new SMTPConfig(parent,"",true); smtp.setVisible(true); smtp.dispose(); // System.out.println("Cancel"); break; default: break; } } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/99debc0e39981c309029bd7389a7d7c50837d87b/SendEMailDialog.java/clean/tn5250j/src/org/tn5250j/mailtools/SendEMailDialog.java
|
public InvocationKeyHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public void keyReleased(KeyEvent e) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
protected InvocationMouseHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
protected InvocationMouseMotionHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
protected ItemHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public void itemStateChanged(ItemEvent e) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public ListDataHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public void contentsChanged(ListDataEvent e) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public void intervalAdded(ListDataEvent e) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public void intervalRemoved(ListDataEvent e) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
protected ListMouseHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public void mousePressed(MouseEvent e) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
if (index >= 0)
|
public void mouseReleased(MouseEvent anEvent) { int index = list.locationToIndex(anEvent.getPoint()); comboBox.setSelectedIndex(index); hide(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
|
protected ListMouseMotionHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
int index = list.locationToIndex(anEvent.getPoint()); list.setSelectedIndex(index); list.repaint();
|
updateListBoxSelectionForEvent(anEvent, false);
|
public void mouseMoved(MouseEvent anEvent) { // Highlight list cells over which the mouse is located. // This changes list model, but has no effect on combo box's data model int index = list.locationToIndex(anEvent.getPoint()); list.setSelectedIndex(index); list.repaint(); }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
protected ListSelectionHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
public void valueChanged(ListSelectionEvent e) { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
protected PropertyChangeHandler() { }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
||
int index = list.locationToIndex(anEvent.getPoint()); if (index >= 0) list.setSelectedIndex(index);
|
protected void updateListBoxSelectionForEvent(MouseEvent anEvent, boolean shouldScroll) { // FIXME: Need to implement }
|
1056 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1056/963ae61676e8c35a9e0998e0b7de1f942db82a26/BasicComboPopup.java/clean/core/src/classpath/javax/javax/swing/plaf/basic/BasicComboPopup.java
|
|
System.out.println(ioe.getMessage());
|
log.warn(ioe.getMessage());
|
public final void cancelInvite() { screen52.setStatus(Screen5250.STATUS_SYSTEM, Screen5250.STATUS_VALUE_ON,null); // from rfc1205 section 4.3 // Server: Sends header with the 000A12A0 00000400 000AFFEF // Opcode = Cancel Invite. // Client: sends header with the 000A12A0 00000400 000AFFEF // Opcode = Cancel Invite to // indicate that the work station is // no longer invited. try { writeGDS(0, 10, null); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
System.out.println("Closing socket");
|
log.info("Closing socket");
|
public final boolean disconnect() { if (me != null && me.isAlive()) { me.interrupt(); keepTrucking = false; pthread.interrupt(); } screen52.setStatus(Screen5250.STATUS_SYSTEM, Screen5250.STATUS_VALUE_ON,"X - Disconnected"); screen52.setKeyboardLocked(false); pendingUnlock =false; try { if (sock != null) { System.out.println("Closing socket"); sock.close(); } if (bin != null) bin.close(); if (bout != null) bout.close(); connected = false; firstScreen = false; controller.fireSessionChanged(TN5250jConstants.STATE_DISCONNECTED); } catch(Exception exception) { System.out.println(exception.getMessage()); connected = false; devSeq = -1; return false; } devSeq = -1; return true; }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
System.out.println(exception.getMessage());
|
log.warn(exception.getMessage());
|
public final boolean disconnect() { if (me != null && me.isAlive()) { me.interrupt(); keepTrucking = false; pthread.interrupt(); } screen52.setStatus(Screen5250.STATUS_SYSTEM, Screen5250.STATUS_VALUE_ON,"X - Disconnected"); screen52.setKeyboardLocked(false); pendingUnlock =false; try { if (sock != null) { System.out.println("Closing socket"); sock.close(); } if (bin != null) bin.close(); if (bout != null) bout.close(); connected = false; firstScreen = false; controller.fireSessionChanged(TN5250jConstants.STATE_DISCONNECTED); } catch(Exception exception) { System.out.println(exception.getMessage()); connected = false; devSeq = -1; return false; } devSeq = -1; return true; }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
System.out.println(" Pending unlock " + pendingUnlock); System.out.println(" Status Error " + screen52.isStatusErrorCode()); System.out.println(" Keyboard Locked " + screen52.isKeyboardLocked()); System.out.println(" Cursor On " + cursorOn); System.out.println(" Cursor Active " + screen52.cursorActive);
|
if(log.isDebugEnabled()) { log.debug(" Pending unlock " + pendingUnlock); log.debug(" Status Error " + screen52.isStatusErrorCode()); log.debug(" Keyboard Locked " + screen52.isKeyboardLocked()); log.debug(" Cursor On " + cursorOn); log.debug(" Cursor Active " + screen52.cursorActive); }
|
public void dumpStuff() { System.out.println(" Pending unlock " + pendingUnlock); System.out.println(" Status Error " + screen52.isStatusErrorCode()); System.out.println(" Keyboard Locked " + screen52.isKeyboardLocked()); System.out.println(" Cursor On " + cursorOn); System.out.println(" Cursor Active " + screen52.cursorActive); }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
System.out.println(ioe.getMessage());
|
log.warn(ioe.getMessage());
|
public final void hostPrint(int aid) { if (screen52.isStatusErrorCode()) { screen52.restoreErrorLine(); screen52.setStatus(Screen5250.STATUS_ERROR_CODE, Screen5250.STATUS_VALUE_OFF,null); } screen52.setCursorActive(false); screen52.setStatus(Screen5250.STATUS_SYSTEM, Screen5250.STATUS_VALUE_ON,null); // From client access ip capture // it seems to use an operation code of 3 and 4 // also note that the flag field that says reserved is being sent as well // with a value of 0x80 // // I have tried with not setting these flags and sending with 3 or 1 // there is no effect and I still get a host print screen. Go figure //0000: 000D 12A0 0000 0400 8003 1407 F6FFEF //0000: 000D 12A0 0000 0400 8001 110E F6FFEF // // Client sends header 000D12A0000004000003####F6FFEF // operation code 3 // row - first ## // column - second ## // F6 - Print Aid Key baosp.write(screen52.getCurrentRow()); baosp.write(screen52.getCurrentCol()); baosp.write(AID_PRINT); // aid key try { writeGDS(0, 3, baosp.toByteArray()); } catch (IOException ioe) { System.out.println(ioe.getMessage()); } baosp.reset(); }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
log.debug("save screen partial");
|
private void parseIncoming() { boolean controlChars = false; byte control0; byte control1; boolean done = false; boolean error = false; try { while (bk.hasNext() && !done) { byte b = bk.getNextByte(); switch (b) { case 0: case 1: break; case CMD_SAVE_SCREEN: // 0x02 2 Save Screen case 3: // 0x03 3 Save Partial Screen// System.out.println("save screen partial"); saveScreen(); break; case ESC: // ESCAPE break; case 7: // audible bell Toolkit.getDefaultToolkit().beep(); bk.getNextByte(); bk.getNextByte(); break; case CMD_WRITE_TO_DISPLAY: // 0x11 17 write to display error = writeToDisplay(true); break; case CMD_RESTORE_SCREEN: // 0x12 18 Restore Screen case 13: // 0x13 19 Restore Partial Screen// System.out.println("restore screen partial"); restoreScreen(); break; case CMD_CLEAR_UNIT_ALTERNATE: // 0x20 32 clear unit alternate int param = bk.getNextByte(); if (param != 0) {// System.out.println(" clear unit alternate error " + Integer.toHexString(param)); sendNegResponse(NR_REQUEST_ERROR,03,01,05, " clear unit alternate not supported"); done = true; } else { if (screen52.getRows() != 27) screen52.setRowsCols(27,132); screen52.clearAll(); } break; case CMD_WRITE_ERROR_CODE: // 0x21 33 Write Error Code writeErrorCode(); error = writeToDisplay(false); break; case CMD_WRITE_ERROR_CODE_TO_WINDOW: // 0x22 34 // Write Error Code to window writeErrorCodeToWindow(); error = writeToDisplay(false); break; case CMD_READ_SCREEN_IMMEDIATE: // 0x62 98 case CMD_READ_SCREEN_TO_PRINT: // 0x66 102 read screen to print readScreen(); break; case CMD_CLEAR_UNIT: // 64 0x40 clear unit if (screen52.getRows() != 24) screen52.setRowsCols(24,80); screen52.clearAll(); break; case CMD_CLEAR_FORMAT_TABLE: // 80 0x50 Clear format table screen52.clearTable(); break; case CMD_READ_INPUT_FIELDS: //0x42 66 read input fields case CMD_READ_MDT_FIELDS: // 0x52 82 read MDT Fields bk.getNextByte(); bk.getNextByte(); readType = b; screen52.goHome(); // do nothing with the cursor here it is taken care of // in the main loop.//////////////// screen52.setCursorOn(); waitingForInput = true; pendingUnlock = true;// screen52.setKeyboardLocked(false); break; case CMD_READ_MDT_IMMEDIATE_ALT: // 0x53 83 readType = b;// screen52.goHome();// waitingForInput = true;// screen52.setKeyboardLocked(false); readImmediate(readType); break; case CMD_WRITE_STRUCTURED_FIELD: // 243 0xF3 -13 Write structured field writeStructuredField(); break; case CMD_ROLL: // 0x23 35 Roll Not sure what it does right now int updown = bk.getNextByte(); int topline = bk.getNextByte(); int bottomline = bk.getNextByte(); screen52.rollScreen(updown,topline,bottomline); break; default: done = true; sendNegResponse(NR_REQUEST_ERROR,03,01,01,"parseIncoming"); break; } if (error) done = true; } } catch (Exception exc) {System.out.println("incoming " + exc.getMessage());}; }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
|
log.debug("restore screen partial");
|
private void parseIncoming() { boolean controlChars = false; byte control0; byte control1; boolean done = false; boolean error = false; try { while (bk.hasNext() && !done) { byte b = bk.getNextByte(); switch (b) { case 0: case 1: break; case CMD_SAVE_SCREEN: // 0x02 2 Save Screen case 3: // 0x03 3 Save Partial Screen// System.out.println("save screen partial"); saveScreen(); break; case ESC: // ESCAPE break; case 7: // audible bell Toolkit.getDefaultToolkit().beep(); bk.getNextByte(); bk.getNextByte(); break; case CMD_WRITE_TO_DISPLAY: // 0x11 17 write to display error = writeToDisplay(true); break; case CMD_RESTORE_SCREEN: // 0x12 18 Restore Screen case 13: // 0x13 19 Restore Partial Screen// System.out.println("restore screen partial"); restoreScreen(); break; case CMD_CLEAR_UNIT_ALTERNATE: // 0x20 32 clear unit alternate int param = bk.getNextByte(); if (param != 0) {// System.out.println(" clear unit alternate error " + Integer.toHexString(param)); sendNegResponse(NR_REQUEST_ERROR,03,01,05, " clear unit alternate not supported"); done = true; } else { if (screen52.getRows() != 27) screen52.setRowsCols(27,132); screen52.clearAll(); } break; case CMD_WRITE_ERROR_CODE: // 0x21 33 Write Error Code writeErrorCode(); error = writeToDisplay(false); break; case CMD_WRITE_ERROR_CODE_TO_WINDOW: // 0x22 34 // Write Error Code to window writeErrorCodeToWindow(); error = writeToDisplay(false); break; case CMD_READ_SCREEN_IMMEDIATE: // 0x62 98 case CMD_READ_SCREEN_TO_PRINT: // 0x66 102 read screen to print readScreen(); break; case CMD_CLEAR_UNIT: // 64 0x40 clear unit if (screen52.getRows() != 24) screen52.setRowsCols(24,80); screen52.clearAll(); break; case CMD_CLEAR_FORMAT_TABLE: // 80 0x50 Clear format table screen52.clearTable(); break; case CMD_READ_INPUT_FIELDS: //0x42 66 read input fields case CMD_READ_MDT_FIELDS: // 0x52 82 read MDT Fields bk.getNextByte(); bk.getNextByte(); readType = b; screen52.goHome(); // do nothing with the cursor here it is taken care of // in the main loop.//////////////// screen52.setCursorOn(); waitingForInput = true; pendingUnlock = true;// screen52.setKeyboardLocked(false); break; case CMD_READ_MDT_IMMEDIATE_ALT: // 0x53 83 readType = b;// screen52.goHome();// waitingForInput = true;// screen52.setKeyboardLocked(false); readImmediate(readType); break; case CMD_WRITE_STRUCTURED_FIELD: // 243 0xF3 -13 Write structured field writeStructuredField(); break; case CMD_ROLL: // 0x23 35 Roll Not sure what it does right now int updown = bk.getNextByte(); int topline = bk.getNextByte(); int bottomline = bk.getNextByte(); screen52.rollScreen(updown,topline,bottomline); break; default: done = true; sendNegResponse(NR_REQUEST_ERROR,03,01,01,"parseIncoming"); break; } if (error) done = true; } } catch (Exception exc) {System.out.println("incoming " + exc.getMessage());}; }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
|
log.debug(" clear unit alternate error " + Integer.toHexString(param));
|
private void parseIncoming() { boolean controlChars = false; byte control0; byte control1; boolean done = false; boolean error = false; try { while (bk.hasNext() && !done) { byte b = bk.getNextByte(); switch (b) { case 0: case 1: break; case CMD_SAVE_SCREEN: // 0x02 2 Save Screen case 3: // 0x03 3 Save Partial Screen// System.out.println("save screen partial"); saveScreen(); break; case ESC: // ESCAPE break; case 7: // audible bell Toolkit.getDefaultToolkit().beep(); bk.getNextByte(); bk.getNextByte(); break; case CMD_WRITE_TO_DISPLAY: // 0x11 17 write to display error = writeToDisplay(true); break; case CMD_RESTORE_SCREEN: // 0x12 18 Restore Screen case 13: // 0x13 19 Restore Partial Screen// System.out.println("restore screen partial"); restoreScreen(); break; case CMD_CLEAR_UNIT_ALTERNATE: // 0x20 32 clear unit alternate int param = bk.getNextByte(); if (param != 0) {// System.out.println(" clear unit alternate error " + Integer.toHexString(param)); sendNegResponse(NR_REQUEST_ERROR,03,01,05, " clear unit alternate not supported"); done = true; } else { if (screen52.getRows() != 27) screen52.setRowsCols(27,132); screen52.clearAll(); } break; case CMD_WRITE_ERROR_CODE: // 0x21 33 Write Error Code writeErrorCode(); error = writeToDisplay(false); break; case CMD_WRITE_ERROR_CODE_TO_WINDOW: // 0x22 34 // Write Error Code to window writeErrorCodeToWindow(); error = writeToDisplay(false); break; case CMD_READ_SCREEN_IMMEDIATE: // 0x62 98 case CMD_READ_SCREEN_TO_PRINT: // 0x66 102 read screen to print readScreen(); break; case CMD_CLEAR_UNIT: // 64 0x40 clear unit if (screen52.getRows() != 24) screen52.setRowsCols(24,80); screen52.clearAll(); break; case CMD_CLEAR_FORMAT_TABLE: // 80 0x50 Clear format table screen52.clearTable(); break; case CMD_READ_INPUT_FIELDS: //0x42 66 read input fields case CMD_READ_MDT_FIELDS: // 0x52 82 read MDT Fields bk.getNextByte(); bk.getNextByte(); readType = b; screen52.goHome(); // do nothing with the cursor here it is taken care of // in the main loop.//////////////// screen52.setCursorOn(); waitingForInput = true; pendingUnlock = true;// screen52.setKeyboardLocked(false); break; case CMD_READ_MDT_IMMEDIATE_ALT: // 0x53 83 readType = b;// screen52.goHome();// waitingForInput = true;// screen52.setKeyboardLocked(false); readImmediate(readType); break; case CMD_WRITE_STRUCTURED_FIELD: // 243 0xF3 -13 Write structured field writeStructuredField(); break; case CMD_ROLL: // 0x23 35 Roll Not sure what it does right now int updown = bk.getNextByte(); int topline = bk.getNextByte(); int bottomline = bk.getNextByte(); screen52.rollScreen(updown,topline,bottomline); break; default: done = true; sendNegResponse(NR_REQUEST_ERROR,03,01,01,"parseIncoming"); break; } if (error) done = true; } } catch (Exception exc) {System.out.println("incoming " + exc.getMessage());}; }
|
1179 /local/tlutelli/issta_data/temp/all_java0context/java/2006_temp/2006/1179/379255347f37d0432228baaff23d41ccb4ad68bd/tnvt.java/buggy/tn5250j/src/org/tn5250j/tnvt.java
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.