rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | Object obj = session.getAttribute("answers"); ArrayList<String> answers = null; if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("... | public void addStringListQuestionToSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getParam... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | Collection answers = (Collection) session.getAttribute("answers"); | public void removeAnswerFromSession(HttpServletRequest request){ HttpSession session = request.getSession(); int rowId = Integer.parseInt(request.getParameter("row")); rowId--; ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); answers.remove(rowId); session.setAttribute("answers", ... |
ArrayList<String> columns = (ArrayList<String>) session.getAttribute("columns"); | ArrayList<String> columns = null; Object obj = session.getAttribute("columns"); if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); columns = new ArrayList<String>(); while(iter.hasNext()){ columns.add((String)iter.next()); } } else columns = (ArrayList<String>) session.getAttribute("c... | public void removeColumnFromSession(HttpServletRequest request){ HttpSession session = request.getSession(); int rowId = Integer.parseInt(request.getParameter("row")); rowId--; ArrayList<String> columns = (ArrayList<String>) session.getAttribute("columns"); columns.remove(rowId); session.setAttribute("columns", ... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | ArrayList<String> answers = null; Object obj = session.getAttribute("answers"); if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String)iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("a... | public void updateAnswerInSession(HttpServletRequest request){ HttpSession session = request.getSession(); int rowId = Integer.parseInt(request.getParameter("row")); String answer = request.getParameter("answer"); rowId--; ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); answers.s... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | Object obj = session.getAttribute("answers"); ArrayList<String> answers = null; if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("... | public void updateCheckBoxQuestionInSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getPara... |
ArrayList<String> columns = (ArrayList<String>) session.getAttribute("columns"); | ArrayList<String> columns = null; Object obj = session.getAttribute("columns"); if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); columns = new ArrayList<String>(); while(iter.hasNext()){ columns.add((String)iter.next()); } } else columns = (ArrayList<String>) session.getAttribute("c... | public void updateColumnInSession(HttpServletRequest request){ HttpSession session = request.getSession(); int rowId = Integer.parseInt(request.getParameter("row")); String column = request.getParameter("column"); rowId--; ArrayList<String> columns = (ArrayList<String>) session.getAttribute("columns"); columns.s... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); ArrayList<String> columns = (ArrayList<String>) session.getAttribute("columns"); | Object obj = session.getAttribute("answers"); ArrayList<String> answers = null; if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("... | public void updateMatrixQuestionInSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getParame... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | Object obj = session.getAttribute("answers"); ArrayList<String> answers = null; if(obj instanceof PersistentList){ Iterator iter = ((PersistentList) obj).iterator(); answers = new ArrayList<String>(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = (ArrayList<String>) session.getAttribute("... | public void updateNumericQuestionInSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String validationType = request.getParam... |
question.setValidationType(validationType); | public void updateNumericQuestionInSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String validationType = request.getParam... | |
if(sform.getFlowScript()!=null && sform.getFlowScript().length()>0){ | if(sform.getMethod().equals("addSection")){ | public void updateSessionSurvey(HttpServletRequest request, SurveyForm sform){ Survey survey = null; HttpSession session = request.getSession(); if(sform.getFlowScript()!=null && sform.getFlowScript().length()>0){ // add a new section survey = addSectionToSurvey(request, sform); } else { // set survey's v... |
ArrayList<String> answers = (ArrayList<String>) session.getAttribute("answers"); | ArrayList<String> answers; Object obj = session.getAttribute("answers"); PersistentList persist = null; if(obj instanceof PersistentList){ persist = (PersistentList) obj; answers = new ArrayList<String>(); Iterator iter = persist.iterator(); while(iter.hasNext()){ answers.add((String) iter.next()); } } else answers = ... | public void updateStringListQuestionInSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getPa... |
buffer = new byte[4096]; | buffer = new byte[BUFSIZE]; | ReaderToUTF8Stream(LimitReader reader) { this.reader = reader; buffer = new byte[4096]; blen = -1; } |
private static void testAutoCommitFailure(Connection con) throws SQLException { DatabaseMetaData dmd = con.getMetaData(); boolean shouldBeClosed = dmd.autoCommitFailureClosesAllResultSets(); | public void testAutoCommitFailure() throws SQLException { Connection con = getConnection(); | private static void testAutoCommitFailure(Connection con) throws SQLException { DatabaseMetaData dmd = con.getMetaData(); boolean shouldBeClosed = dmd.autoCommitFailureClosesAllResultSets(); con.setAutoCommit(true); Statement s1 = con.createStatement(ResultSet.TYPE_F... |
System.out.println("\"" + query + "\" is expected to fail, " + "but it didn't."); | fail("Query didn't fail."); | private static void testAutoCommitFailure(Connection con) throws SQLException { DatabaseMetaData dmd = con.getMetaData(); boolean shouldBeClosed = dmd.autoCommitFailureClosesAllResultSets(); con.setAutoCommit(true); Statement s1 = con.createStatement(ResultSet.TYPE_F... |
boolean isClosed = resultSet.isClosed(); if (isClosed != shouldBeClosed) { System.out.println("autoCommitFailureClosesAllResultSets() " + "returned " + shouldBeClosed + ", but ResultSet is " + (isClosed ? "closed." : "not closed.")); } | assertEquals("autoCommitFailureClosesAllResultSets() returned value " + "which doesn't match actual behaviour.", resultSet.isClosed(), meta.autoCommitFailureClosesAllResultSets()); | private static void testAutoCommitFailure(Connection con) throws SQLException { DatabaseMetaData dmd = con.getMetaData(); boolean shouldBeClosed = dmd.autoCommitFailureClosesAllResultSets(); con.setAutoCommit(true); Statement s1 = con.createStatement(ResultSet.TYPE_F... |
private static void testStoredProcEscapeSyntax(Connection con) throws SQLException { con.setAutoCommit(false); | public void testStoredProcEscapeSyntax() throws SQLException { getConnection().setAutoCommit(false); | private static void testStoredProcEscapeSyntax(Connection con) throws SQLException { con.setAutoCommit(false); String call = "{CALL SYSCS_UTIL.SYSCS_SET_RUNTIMESTATISTICS(0)}"; Statement stmt = con.createStatement(); boolean success; try { stmt.execute(call); ... |
Statement stmt = con.createStatement(); | Statement stmt = createStatement(); | private static void testStoredProcEscapeSyntax(Connection con) throws SQLException { con.setAutoCommit(false); String call = "{CALL SYSCS_UTIL.SYSCS_SET_RUNTIMESTATISTICS(0)}"; Statement stmt = con.createStatement(); boolean success; try { stmt.execute(call); ... |
DatabaseMetaData dmd = con.getMetaData(); boolean supported = dmd.supportsStoredFunctionsUsingCallSyntax(); if (success != supported) { System.out.println("supportsStoredFunctionsUsingCallSyntax() " + "returned " + supported + ", but executing " + call + (success ? " succeeded." : " failed.")); } | assertEquals("supportsStoredFunctionsUsingCallSyntax() returned " + "value which doesn't match actual behaviour.", success, meta.supportsStoredFunctionsUsingCallSyntax()); | private static void testStoredProcEscapeSyntax(Connection con) throws SQLException { con.setAutoCommit(false); String call = "{CALL SYSCS_UTIL.SYSCS_SET_RUNTIMESTATISTICS(0)}"; Statement stmt = con.createStatement(); boolean success; try { stmt.execute(call); ... |
con.rollback(); | private static void testStoredProcEscapeSyntax(Connection con) throws SQLException { con.setAutoCommit(false); String call = "{CALL SYSCS_UTIL.SYSCS_SET_RUNTIMESTATISTICS(0)}"; Statement stmt = con.createStatement(); boolean success; try { stmt.execute(call); ... | |
mb.callMethod(VMOpcode.INVOKEVIRTUAL, (String) null, "getParameter", | mb.callMethod(VMOpcode.INVOKEVIRTUAL, ClassName.BaseActivation, "getParameter", | public void generateExpression(ExpressionClassBuilder acb, MethodBuilder mb) throws StandardException { DataTypeDescriptor dtd = getTypeServices(); if ((dtd != null) && dtd.getTypeId().isXMLTypeId()) { // We're a parameter that corresponds to an XML column/target, // which we don't allow. We thr... |
Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions = null; | stmt.clearDrdaParams(); | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... |
paramDrdaTypes.addElement(new Byte(reader.readByte())); | final byte t = reader.readByte(); | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... |
Integer.toHexString(((Byte ) paramDrdaTypes.lastElement()).byteValue())); | Integer.toHexString(t)); | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... |
paramLens.addElement(new Integer(drdaLength)); | stmt.addDrdaParam(t, drdaLength); | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... |
numVars = paramDrdaTypes.size(); | numVars = stmt.getDrdaParamCount(); | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... |
if ((((Byte)paramDrdaTypes.elementAt(i)).byteValue() & 0x1) == 0x1) | if ((stmt.getParamDRDAType(i+1) & 0x1) == 0x1) | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... |
paramExtPositions = readAndSetParams(i, stmt, ((Byte)paramDrdaTypes.elementAt(i)).byteValue(), pmeta, paramExtPositions, ((Integer)(paramLens.elementAt(i))).intValue()); | readAndSetParams(i, stmt, pmeta); | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... |
stmt.cliParamExtPositions = paramExtPositions; stmt.cliParamDrdaTypes = paramDrdaTypes; stmt.cliParamLens = paramLens; | private void parseSQLDTA_work(DRDAStatement stmt) throws DRDAProtocolException,SQLException { String strVal; PreparedStatement ps = stmt.getPreparedStatement(); int codePoint; EngineParameterMetaData pmeta = null; Vector paramDrdaTypes = new Vector(); Vector paramLens = new Vector(); ArrayList paramExtPositions... | |
int numExt = stmt.cliParamExtPositions.size(); for (int i = 0; i < stmt.cliParamExtPositions.size(); i++) | final int numExt = stmt.getExtPositionCount(); for (int i = 0; i < numExt; i++) | private void readAndSetAllExtParams(final DRDAStatement stmt, final boolean streamLOB) throws SQLException, DRDAProtocolException { int numExt = stmt.cliParamExtPositions.size(); for (int i = 0; i < stmt.cliParamExtPositions.size(); i++) { int paramPos = ((Integer) (stmt.cliParamExtPositions).get(i)).intV... |
int paramPos = ((Integer) (stmt.cliParamExtPositions).get(i)).intValue(); | int paramPos = stmt.getExtPosition(i); | private void readAndSetAllExtParams(final DRDAStatement stmt, final boolean streamLOB) throws SQLException, DRDAProtocolException { int numExt = stmt.cliParamExtPositions.size(); for (int i = 0; i < stmt.cliParamExtPositions.size(); i++) { int paramPos = ((Integer) (stmt.cliParamExtPositions).get(i)).intV... |
((Byte)stmt.cliParamDrdaTypes.elementAt(paramPos)).intValue(), ((Integer)(stmt.cliParamLens.elementAt(paramPos))).intValue(), | stmt.getParamDRDAType(paramPos+1), stmt.getParamLen(paramPos+1), | private void readAndSetAllExtParams(final DRDAStatement stmt, final boolean streamLOB) throws SQLException, DRDAProtocolException { int numExt = stmt.cliParamExtPositions.size(); for (int i = 0; i < stmt.cliParamExtPositions.size(); i++) { int paramPos = ((Integer) (stmt.cliParamExtPositions).get(i)).intV... |
private ArrayList readAndSetParams(int i, DRDAStatement stmt, int drdaType, EngineParameterMetaData pmeta, ArrayList paramExtPositions, int paramLenNumBytes) | private void readAndSetParams(int i, DRDAStatement stmt, EngineParameterMetaData pmeta) | private ArrayList readAndSetParams(int i, DRDAStatement stmt, int drdaType, EngineParameterMetaData pmeta, ArrayList paramExtPositions, int paramLenNumBytes) throws DRDAProtocolException, SQLException { PreparedStatement ps = stmt.getPreparedStatement(); // mask out null indicator... |
drdaType = ((drdaType | 0x01) & 0x000000ff); | final int drdaType = ((stmt.getParamDRDAType(i+1) | 0x01) & 0xff); final int paramLenNumBytes = stmt.getParamLen(i+1); | private ArrayList readAndSetParams(int i, DRDAStatement stmt, int drdaType, EngineParameterMetaData pmeta, ArrayList paramExtPositions, int paramLenNumBytes) throws DRDAProtocolException, SQLException { PreparedStatement ps = stmt.getPreparedStatement(); // mask out null indicator... |
if (paramExtPositions == null) paramExtPositions = new ArrayList(); paramExtPositions.add(new Integer(i)); | stmt.addExtPosition(i); | private ArrayList readAndSetParams(int i, DRDAStatement stmt, int drdaType, EngineParameterMetaData pmeta, ArrayList paramExtPositions, int paramLenNumBytes) throws DRDAProtocolException, SQLException { PreparedStatement ps = stmt.getPreparedStatement(); // mask out null indicator... |
return paramExtPositions; | private ArrayList readAndSetParams(int i, DRDAStatement stmt, int drdaType, EngineParameterMetaData pmeta, ArrayList paramExtPositions, int paramLenNumBytes) throws DRDAProtocolException, SQLException { PreparedStatement ps = stmt.getPreparedStatement(); // mask out null indicator... | |
numCols = stmt.getNumParams(); | numCols = stmt.getDrdaParamCount(); | private boolean writeFDODTA (DRDAStatement stmt) throws DRDAProtocolException, SQLException { boolean hasdata = false; int blksize = stmt.getBlksize() > 0 ? stmt.getBlksize() : CodePoint.QRYBLKSZ_MAX; long rowCount = 0; ResultSet rs =null; boolean moreData = (stmt.getQryprctyp() == CodePoint.LMTBLKPRC); ... |
System.out.println("Test the metadata calls related to visibility of *own* changes for different resultset types"); System.out.println("ownUpdatesAreVisible(ResultSet.TYPE_FORWARD_ONLY)? " + met.ownUpdatesAreVisible(ResultSet.TYPE_FORWARD_ONLY)); System.out.println("ownDeletesAreVisible(ResultSet.TYPE_FORWARD_ONLY)? " ... | public void runTest() { DatabaseMetaData met; ResultSet rs; ResultSetMetaData rsmet; System.out.println("Test metadata starting"); try { //Cleanup any leftover database objects from previous test run cleanUp(s); // test decimal type and other numeric types precision, scale, // and display width after ope... | |
RadioMatrixQuestion question = new RadioMatrixQuestion(columns.size(), answers.size()); | CheckBoxMatrixQuestion question = new CheckBoxMatrixQuestion(); | public void addMatrixQuestionToSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getParameter... |
survey.setStatus(SurveyState.OPEN.getCode()); | survey.setStatus(SurveyState.DESIGN.getCode()); | public void createSessionSurvey(HttpServletRequest request){ HttpSession session = request.getSession(true); Survey survey = new Survey(); Calendar creationDate = Calendar.getInstance(); survey.setCreationDate(creationDate); survey.setStatus(SurveyState.OPEN.getCode()); session.setAttribute("currentSurvey", surv... |
Collection answers = (Collection) session.getAttribute("answers"); answers.remove(rowId); session.setAttribute("answers", answers); | Object obj = session.getAttribute("answers"); if (obj instanceof PersistentList){ PersistentList answers = (PersistentList) obj; answers.remove(rowId); session.setAttribute("answers", answers); } else { ArrayList<String> answers = (ArrayList<String>) obj; answers.remove(rowId); session.setAttribute("answers", answers);... | public void removeAnswerFromSession(HttpServletRequest request){ HttpSession session = request.getSession(); int rowId = Integer.parseInt(request.getParameter("row")); rowId--; Collection answers = (Collection) session.getAttribute("answers"); answers.remove(rowId); session.setAttribute("answers", answers); } |
RadioMatrixQuestion question = new RadioMatrixQuestion(columns.size(), answers.size()); | CheckBoxMatrixQuestion question = new CheckBoxMatrixQuestion(); | public void updateMatrixQuestionInSection(HttpServletRequest request){ HttpSession session = request.getSession(); Section section = (Section) session.getAttribute("currentSection"); String name = request.getParameter("name"); String image = request.getParameter("image"); String questionText = request.getParame... |
survey.setRestrictionType(sform.getRestrictionType()); survey.setDescription(sform.getDescription()); | public void updatePersistedSurvey(HttpServletRequest request, SurveyForm sform){ Survey survey; HttpSession session = request.getSession(); if(sform.getSectionName()!=null && !sform.getSectionName().equals("")) survey = addSectionToSurvey(request, sform); else { survey = (Survey) session.getAttribute("currentS... | |
survey.setFinishDate(Transformer.getCalendarFromString(sform.getEndDate())); survey.setStartDate(Transformer.getCalendarFromString(sform.getStartDate())); | survey.setFinishDate(Transformer.getCalendarFromString(sform .getEndDate())); survey.setStartDate(Transformer.getCalendarFromString(sform .getStartDate())); survey.setDescription(sform.getDescription()); survey.setRestrictionType(sform.getRestrictionType()); | private Survey updateSessionSurveyValues(HttpServletRequest request, SurveyForm sform){ HttpSession session = request.getSession(); Survey survey = (Survey) session.getAttribute("currentSurvey"); survey.setName(sform.getName()); survey.setCreationDate(Calendar.getInstance()); survey.setFinishDate(Transformer.getC... |
getJogador(numNotificado).vez(getJogadorDaVez(), isPodeFechada()); | getJogador(numNotificado).vez(jogadorDaVez, podeFechada); | private void notificaVez() { class ThreadNotifica extends Thread { public int numNotificado; public void run() { getJogador(numNotificado).vez(getJogadorDaVez(), isPodeFechada()); } } for (int i = 1; i <= 4; i++) { ThreadNotifica tn = new ThreadNotifica(); tn.numNotificado = i; tn.start(); } } |
tn.jogadorDaVez = j; tn.podeFechada = pf; | private void notificaVez() { class ThreadNotifica extends Thread { public int numNotificado; public void run() { getJogador(numNotificado).vez(getJogadorDaVez(), isPodeFechada()); } } for (int i = 1; i <= 4; i++) { ThreadNotifica tn = new ThreadNotifica(); tn.numNotificado = i; tn.start(); } } | |
getJogador(numNotificado).vez(getJogadorDaVez(), isPodeFechada()); | getJogador(numNotificado).vez(jogadorDaVez, podeFechada); | public void run() { getJogador(numNotificado).vez(getJogadorDaVez(), isPodeFechada()); } |
} catch (SQLException ex) { | } catch (NoSuchMethodError nsme) { System.out.println("ResultSet.updateRef not present - correct for JSR169"); } catch (SQLException ex) { | public static void main(String[] args) { Connection con; ResultSet rs; Statement stmt; String[] columnNames = {"i", "s", "r", "d", "dt", "t", "ts", "c", "v", "tn", "dc"}; System.out.println("Test resultsetJdbc30 starting"); try { // use the ij utility to read the property file and // make the initial conne... |
} catch (SQLException ex) { | } catch (NoSuchMethodError nsme) { System.out.println("ResultSet.updateArray not present - correct for JSR169"); } catch (SQLException ex) { | public static void main(String[] args) { Connection con; ResultSet rs; Statement stmt; String[] columnNames = {"i", "s", "r", "d", "dt", "t", "ts", "c", "v", "tn", "dc"}; System.out.println("Test resultsetJdbc30 starting"); try { // use the ij utility to read the property file and // make the initial conne... |
System.out.println("trying rs.updateClob(String, Array) :"); | System.out.println("trying rs.updateArray(String, Array) :"); | public static void main(String[] args) { Connection con; ResultSet rs; Statement stmt; String[] columnNames = {"i", "s", "r", "d", "dt", "t", "ts", "c", "v", "tn", "dc"}; System.out.println("Test resultsetJdbc30 starting"); try { // use the ij utility to read the property file and // make the initial conne... |
closeCleanup); | userSuppliedOptimizerOverrides, closeCleanup); | public NestedLoopLeftOuterJoinResultSet( NoPutResultSet leftResultSet, int leftNumCols, NoPutResultSet rightResultSet, int rightNumCols, Activation activation, GeneratedMethod restriction, int resultSetNumber, GeneratedMethod emptyRowFun, boolean wasRightOuterJoin, ... |
BufferedReader bufferedReader = new BufferedReader(reader); while (true) { String line = bufferedReader.readLine(); if (line == null) { break; } else { buffer.append(line); buffer.append('\n'); } } | char[] charBuffer = new char[ 4096 ]; int read; do { read = reader.read( charBuffer ); if ( read > 0 ) { buffer.append( charBuffer, 0, read ); } } while ( read > 0); | protected String loadText(Reader reader) throws IOException { StringBuffer buffer = new StringBuffer(); // @todo its probably more efficient to use a fixed char[] buffer instead try { BufferedReader bufferedReader = new BufferedReader(reader); while (true) { ... |
try { dumpRS(met.getFunctions(null, null, null)); dumpRS(met.getFunctions("Dummy Catalog", null, null)); dumpRS(met.getFunctions(null, "SYS%", null)); dumpRS(met.getFunctions(null, null, "%GET%")); checkEmptyRS(met.getFunctions("", "", null)); } catch (SQLException e) { System.out.println("getFunctions():");... | dumpRS(met.getFunctions(null, null, null)); dumpRS(met.getFunctions("Dummy Catalog", null, null)); dumpRS(met.getFunctions(null, "SYS%", null)); dumpRS(met.getFunctions(null, null, "%GET%")); checkEmptyRS(met.getFunctions("", "", null)); | private static void testDatabaseMetaDataMethods(Connection con) throws Exception { con.setAutoCommit(true); // make sure it is true Statement s = con.createStatement(); DatabaseMetaData met = con.getMetaData(); if (!met.supportsStoredFunctionsUsingCallSyntax()) { Sys... |
testSecMec tester = new testSecMec(); | testSecMec tester = new testSecMec(consoleLogStream, originalStream, shutdownLogStream, consoleErrLogStream, originalErrStream, shutdownErrLogStream); | public static void main(String[] args) throws Exception { // Load harness properties. ij.getPropertyArg(args); String hostName = TestUtil.getHostName(); if (hostName.equals("localhost")) NETWORKSERVER_PORT = 20000; else NETWORKSERVER_PORT = 1527; // "runTest()" is going to try to connect to the database thro... |
{ | { consoleLogStream.switchOutput( shutdownLogStream ); consoleErrLogStream.switchOutput( shutdownErrLogStream ); | public static void main(String[] args) throws Exception { // Load harness properties. ij.getPropertyArg(args); String hostName = TestUtil.getHostName(); if (hostName.equals("localhost")) NETWORKSERVER_PORT = 20000; else NETWORKSERVER_PORT = 1527; // "runTest()" is going to try to connect to the database thro... |
System.out.close(); System.err.close(); | originalStream.close(); shutdownLogStream.close(); originalErrStream.close(); shutdownErrLogStream.close(); | public static void main(String[] args) throws Exception { // Load harness properties. ij.getPropertyArg(args); String hostName = TestUtil.getHostName(); if (hostName.equals("localhost")) NETWORKSERVER_PORT = 20000; else NETWORKSERVER_PORT = 1527; // "runTest()" is going to try to connect to the database thro... |
public Volume( String volName, String volBaseDir ) { volumeName = volName; volumeBaseDir = new File( volBaseDir ); if ( !volumeBaseDir.exists() ) { volumeBaseDir.mkdir(); } registerVolume(); | public Volume() { | public Volume( String volName, String volBaseDir ) { volumeName = volName; volumeBaseDir = new File( volBaseDir ); if ( !volumeBaseDir.exists() ) { volumeBaseDir.mkdir(); } registerVolume(); } |
log.debug( "Mapped " + fname + " to " + archiveFile ); | public File mapFileName( String fname ) throws FileNotFoundException { File yearDir = new File( volumeBaseDir, fname.substring( 0, 4 ) ); File monthDir = new File ( yearDir, fname.substring( 0, 6 ) ); File archiveFile = new File( monthDir, fname ); if ( !archiveFile.exists() ) { throw new FileNotFoundException(... | |
public Vector<Transaction> getTransactions(Date startDate, Date endDate){ Vector<Transaction> transactions = getTransactions(); Vector<Transaction> v = new Vector<Transaction>(); for (Transaction t : transactions) { if ((t.getDate().after(startDate) || t.getDate().equals(startDate)) && (t.getDate().before(endDate) || ... | public Vector<Transaction> getTransactions(){ Vector<Transaction> transactions = new Vector<Transaction>(getDataModel().getAllTransactions().getTransactions()); Collections.sort(transactions); return transactions; | public Vector<Transaction> getTransactions(Date startDate, Date endDate){ Vector<Transaction> transactions = getTransactions(); Vector<Transaction> v = new Vector<Transaction>(); for (Transaction t : transactions) { if ((t.getDate().after(startDate) || t.getDate().equals(startDate)) && (t.getDate().before(... |
public void parseHapMap(Vector rawLines) throws PedFileException { | public void parseHapMap(Vector lines) throws PedFileException { | public void parseHapMap(Vector rawLines) throws PedFileException { int colNum = -1; int numLines = rawLines.size(); if (numLines < 2){ throw new PedFileException("Hapmap data format error: empty file"); } Individual ind; this.allIndividuals = new Vector(); ... |
int numLines = rawLines.size(); | int numLines = lines.size(); | public void parseHapMap(Vector rawLines) throws PedFileException { int colNum = -1; int numLines = rawLines.size(); if (numLines < 2){ throw new PedFileException("Hapmap data format error: empty file"); } Individual ind; this.allIndividuals = new Vector(); ... |
Vector lines = new Vector(); Hashtable sortHelp = new Hashtable(numLines-1,1.0f); long[] pos = new long[numLines-1]; lines.add(rawLines.get(0)); for (int k = 1; k < numLines; k++){ StringTokenizer st = new StringTokenizer((String) rawLines.get(k)); st.nextToken();st.nextToken();st.nextToken(); pos[k-1] = new Long(st.n... | public void parseHapMap(Vector rawLines) throws PedFileException { int colNum = -1; int numLines = rawLines.size(); if (numLines < 2){ throw new PedFileException("Hapmap data format error: empty file"); } Individual ind; this.allIndividuals = new Vector(); ... | |
public Family(String familyName){ | public Family(){ | public Family(String familyName){ this.members = new Hashtable(); this.familyName = familyName; } |
this.familyName = familyName; | public Family(String familyName){ this.members = new Hashtable(); this.familyName = familyName; } | |
public void doTag(XMLOutput output) throws Exception { | public void doTag(XMLOutput output) throws JellyTagException { | public void doTag(XMLOutput output) throws Exception { String message = getMessage(); if ( message == null ) { message = getBodyText(); } fail( message ); } |
public void flushCache(XWikiContext context) { virtualWikiList = new ArrayList(); if (virtualWikiMap!=null) { virtualWikiMap.flushAll(); virtualWikiMap = null; } if (groupService != null) groupService.flushCache(); XWikiStoreInterface store = getStore(); if ((store != null) && (store instanceof XWikiCacheStoreInt... | public void flushCache() { flushCache(null); | public void flushCache(XWikiContext context) { // We need to flush the virtual wiki list virtualWikiList = new ArrayList(); // We need to flush the server Cache if (virtualWikiMap!=null) { virtualWikiMap.flushAll(); virtualWikiMap = null; } // We need ... |
putValue(SHORT_DESCRIPTION, "Forward Engineer SQL Script"); | public ExportDDLAction() { super("Forward Engineer...", ASUtils.createIcon("ForwardEngineer", "Forward Engineer", ArchitectFrame.getMainInstance().sprefs.getInt(SwingUserSettings.ICON_SIZE, 24))); architectFrame = ArchitectFrame.getMainInstance(); } | |
"Export DDL Script"); | "Forward Engineer SQL Script"); | public void actionPerformed(ActionEvent e) { final JDialog d = new JDialog(ArchitectFrame.getMainInstance(), "Export DDL Script"); JPanel cp = new JPanel(new BorderLayout(12,12)); cp.setBorder(BorderFactory.createEmptyBorder(12,12,12,12)); final DDLExportPanel ddlPanel = new DDLExportPanel(architectFrame... |
architectFrame.project.getDDLGenerator().writeDDL (architectFrame.playpen.getDatabase()); | showPreview(architectFrame.project.getDDLGenerator(), d); | public void actionPerformed(ActionEvent e) { final JDialog d = new JDialog(ArchitectFrame.getMainInstance(), "Export DDL Script"); JPanel cp = new JPanel(new BorderLayout(12,12)); cp.setBorder(BorderFactory.createEmptyBorder(12,12,12,12)); final DDLExportPanel ddlPanel = new DDLExportPanel(architectFrame... |
d.setVisible(false); | public void actionPerformed(ActionEvent e) { final JDialog d = new JDialog(ArchitectFrame.getMainInstance(), "Export DDL Script"); JPanel cp = new JPanel(new BorderLayout(12,12)); cp.setBorder(BorderFactory.createEmptyBorder(12,12,12,12)); final DDLExportPanel ddlPanel = new DDLExportPanel(architectFrame... | |
architectFrame.project.getDDLGenerator().writeDDL (architectFrame.playpen.getDatabase()); | showPreview(architectFrame.project.getDDLGenerator(), d); | public void actionPerformed(ActionEvent evt) { try { ddlPanel.applyChanges(); architectFrame.project.getDDLGenerator().writeDDL (architectFrame.playpen.getDatabase()); } catch (Exception ex) { JOptionPane.showMessageDialog (architectFrame, "Can't export DDL: "+ex.getMessage... |
d.setVisible(false); | public void actionPerformed(ActionEvent evt) { try { ddlPanel.applyChanges(); architectFrame.project.getDDLGenerator().writeDDL (architectFrame.playpen.getDatabase()); } catch (Exception ex) { JOptionPane.showMessageDialog (architectFrame, "Can't export DDL: "+ex.getMessage... | |
public Object getTaskObject(); | public Object getTaskObject() throws Exception; | public Object getTaskObject(); |
getBody().run(context, output); | invokeBody( output); | public void doTag(XMLOutput output) throws Exception { output.startElement(uri, localName, qname, attributes); getBody().run(context, output); output.endElement(uri, localName, qname); } |
int scaleSize = theData.dPrimeTable.length*30; | void doExportDPrime(){ fc.setSelectedFile(null); int returnVal = fc.showSaveDialog(this); if (returnVal == JFileChooser.APPROVE_OPTION){ try { int scaleSize = theData.dPrimeTable.length*30; DrawingMethods dm = new DrawingMethods(); BufferedImage image = new BufferedImage(scaleSize, scaleSize, BufferedImage.T... | |
BufferedImage image = new BufferedImage(scaleSize, scaleSize, BufferedImage.TYPE_3BYTE_BGR); | Dimension theSize = dm.dPrimeGetPreferredSize(theData.dPrimeTable.length, infoKnown); BufferedImage image = new BufferedImage((int)theSize.getWidth(), (int)theSize.getHeight(), BufferedImage.TYPE_3BYTE_BGR); | void doExportDPrime(){ fc.setSelectedFile(null); int returnVal = fc.showSaveDialog(this); if (returnVal == JFileChooser.APPROVE_OPTION){ try { int scaleSize = theData.dPrimeTable.length*30; DrawingMethods dm = new DrawingMethods(); BufferedImage image = new BufferedImage(scaleSize, scaleSize, BufferedImage.T... |
finished = true; | public void doMonitoredComputation(){ dPrimeTable = generateDPrimeTable(chromosomes); blocks = guessBlocks(dPrimeTable, 0); } | |
public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ | public void dPrimeDraw(PairwiseLinkage[][] table, boolean info, Vector snps, Graphics g){ | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... |
float d, l, blgr; | double d, l, blgr; | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... |
if (info) activeOffset = labeloffset; g.setColor(new Color(192,192,192)); g.fillRect(0,0,scale+activeOffset,scale); g.setColor(Color.black); g.setFont(boldFont); shifts = centerString("1", boldfm); g.drawString("1", activeOffset + shifts[0], shifts[1]); if (info){ NumberFormat nf = NumberFormat.getInstance(); nf.... | if (info) activeOffset = labeloffset; g.setColor(new Color(192,192,192)); g.fillRect(0,0,scale+activeOffset,scale); g.setColor(Color.black); g.setFont(boldFont); shifts = centerString("1", boldfm); g.drawString("1", activeOffset + shifts[0], shifts[1]); if (info){ NumberFormat nf = NumberFormat.getInstance(); nf.... | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... |
if (table.length > 3){ g.drawLine(labeloffset+95,0,labeloffset+scale,scale-95); double lineLength = Math.sqrt((scale-95)*(scale-95)*2); double start = ((SNP)snps.elementAt(0)).getPosition(); double totalLength = ((SNP)snps.elementAt(table.length-1)).getPosition() - start; int numKB = (int)(totalLength/1000); g.drawStri... | for (int x = 0; x < table.length-1; x++){ for (int y = x + 1; y < table.length; y++){ PairwiseLinkage thisPair = table[x][y]; d = thisPair.getDPrime(); l = thisPair.getLOD(); if (l > 2){ if (d < 0.5) { myColor = new Color(255, 224, 224); } else { blgr = (255-32)*2*(1-d); myColor = new Color(255, (int) blgr, (int) bl... | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... |
} | for (int x = 0; x < table.length-1; x++){ for (int y = x + 1; y < table.length; y++){ StringTokenizer st = new StringTokenizer(table[x][y]); d = Float.parseFloat(st.nextToken()); l = Float.parseFloat(st.nextToken()); if (l > 2){ if (d < 0.5) { myColor = new Color(255, 224, 224); } else { blgr = (255-32)*2*(1-d); myC... | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... |
for (int x = 0; x < table.length-1; x++){ for (int y = x + 1; y < table.length; y++){ StringTokenizer st = new StringTokenizer(table[x][y]); d = Float.parseFloat(st.nextToken()); l = Float.parseFloat(st.nextToken()); if (l > 2){ if (d < 0.5) { myColor = new Color(255, 224, 224); } else { blgr = (255-32)*2*(1-d); myC... | g.setColor(myColor); g.fillRect(x*boxDimension, y*boxDimension, boxDimension, boxDimension); | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... |
g.setColor(myColor); g.fillRect(x*30+1+activeOffset, y*30+1, 28, 28); g.setColor(Color.black); g.drawRect(x*30+activeOffset, y*30, 30, 30); g.setFont(regFont); shifts=centerString(Float.toString(d), regfm); g.drawString(Float.toString(d), shifts[0]+(x*30)+activeOffset,(y*30)+shifts[1]); | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... | |
g.setColor(Color.black); g.setFont(boldFont); shifts = centerString(Integer.toString(x+2), boldfm); g.drawString(Integer.toString(x+2), shifts[0]+(x+1)*30+activeOffset, shifts[1]+(x+1)*30); } | }**/ | public void dPrimeDraw(String[][] table, boolean info, Vector snps, Graphics g){ int scale = table.length*30; int activeOffset = 0; float d, l, blgr; Color myColor; int[] shifts; Font regFont = new Font("Lucida Sans Regular", Font.PLAIN, 10); FontMetrics regfm = g.getFontMetrics(regFont); Font boldFont = new Font("... |
if (! (filename.endsWith(".jpg") || filename.endsWith(".JPG"))){ filename += ".jpg"; | if (! (filename.endsWith(".png") || filename.endsWith(".PNG"))){ filename += ".png"; | void saveImage(BufferedImage image, String filename) throws IOException{ try { if (! (filename.endsWith(".jpg") || filename.endsWith(".JPG"))){ filename += ".jpg"; } Jimi.putImage("image/jpg", (Image)image, filename); }catch (com.sun.jimi.core.JimiException e){ e.printStackTrace(); } } |
Jimi.putImage("image/jpg", (Image)image, filename); | Jimi.putImage("image/png", (Image)image, filename); | void saveImage(BufferedImage image, String filename) throws IOException{ try { if (! (filename.endsWith(".jpg") || filename.endsWith(".JPG"))){ filename += ".jpg"; } Jimi.putImage("image/jpg", (Image)image, filename); }catch (com.sun.jimi.core.JimiException e){ e.printStackTrace(); } } |
DPrimePanel(String[][] t){ | DPrimePanel(String[][] t, boolean b, Vector v){ | DPrimePanel(String[][] t){ table = t; } |
info = b; vec = v; | DPrimePanel(String[][] t){ table = t; } | |
spacerScale = (((SNP)markers.lastElement()).getPosition() - ((SNP)markers.firstElement()).getPosition())/(780-(20*markers.size())); | spacerScale = (((SNP)markers.lastElement()).getPosition() - ((SNP)markers.firstElement()).getPosition())/(779-(20*markers.size())); | BlockDisplay(Vector ms, Vector bs, DPrimePanel dp, boolean ik){ markers = ms; blocks = bs; theDPrime = dp; infoKnown = ik; setBackground(Color.black); setLayout(gridbag); selected = new boolean[markers.size()]; markerButtons = new JButton[markers.size()]; spaceLabels = new JLabel[markers.size() - 1]; //create a bu... |
public void saveDprimeToText(String[][] dPrimeTable, File dumpDprimeFile, boolean info, Vector markerinfo) throws IOException{ | public void saveDprimeToText(PairwiseLinkage[][] dPrimeTable, File dumpDprimeFile, boolean info, Vector markerinfo) throws IOException{ | public void saveDprimeToText(String[][] dPrimeTable, File dumpDprimeFile, boolean info, Vector markerinfo) throws IOException{ FileWriter saveDprimeWriter = new FileWriter(dumpDprimeFile); if (info){ saveDprimeWriter.write("L1\tL2\tD'\tLOD\tr^2\tCIlow\tCIhi\tDist\n"); long dist; for (int i = 0; i ... |
saveDprimeWriter.write((i+1) + "\t" + (j+1) + "\t" + dPrimeTable[i][j] + "\t" + dist + "\n"); | saveDprimeWriter.write((i+1) + "\t" + (j+1) + "\t" + dPrimeTable[i][j].toString() + "\t" + dist + "\n"); | public void saveDprimeToText(String[][] dPrimeTable, File dumpDprimeFile, boolean info, Vector markerinfo) throws IOException{ FileWriter saveDprimeWriter = new FileWriter(dumpDprimeFile); if (info){ saveDprimeWriter.write("L1\tL2\tD'\tLOD\tr^2\tCIlow\tCIhi\tDist\n"); long dist; for (int i = 0; i ... |
public void setAttribute(String name, Object value) throws JellyTagException { int index = attributes.getIndex("", name); if (index >= 0) { attributes.removeAttribute(index); } if (value != null) { attributes.addAttribute("", name, name, "CDATA", value.toString()); } | public void setAttribute(String name, String prefix, String nsURI, Object value) { if(value==null) return; if(prefix!=null && prefix.length()>0) attributes.addAttribute(nsURI,name,prefix+":"+name,"CDATA",value.toString()); else attributes.addAttribute("",name,name,"CDATA",value.toString()); | public void setAttribute(String name, Object value) throws JellyTagException { // ### we'll assume that all attributes are in no namespace! // ### this is severely limiting! // ### - Tag attributes should allow for namespace aware int index = attributes.getIndex("", name); if (ind... |
public void startElement( String uri, String localName, String qName, Attributes atts) throws SAXException { int idx = qName.indexOf(':'); String attNsPrefix = ""; if (idx >= 0) { attNsPrefix = qName.substring(0, idx); } namespaceStack.pushNamespace(attNsPrefix, uri); for (int i = 0; i < atts.getLength(); i++) { Strin... | public void startElement(String localName) throws SAXException { startElement("", localName, localName, EMPTY_ATTRIBUTES); | public void startElement( String uri, String localName, String qName, Attributes atts) throws SAXException { int idx = qName.indexOf(':'); String attNsPrefix = ""; if (idx >= 0) { attNsPrefix = qName.substring(0, idx); } namespaceStack... |
public void endElement(String uri, String localName, String qName) throws SAXException { contentHandler.endElement(uri, localName, qName); namespaceStack.decreaseLevel(); namespaceStack.popNamespaces(); | public void endElement(String localName) throws SAXException { endElement("", localName, localName); | public void endElement(String uri, String localName, String qName) throws SAXException { contentHandler.endElement(uri, localName, qName); // Inform namespaceStack to return to previous depth namespaceStack.decreaseLevel(); namespaceStack.popNamespaces(); } |
JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); | JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; | public HaploView(){ //menu setup JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; //file menu JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuIte... |
menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuItem); | JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); | public HaploView(){ //menu setup JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; //file menu JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuIte... |
menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuItem); | public HaploView(){ //menu setup JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; //file menu JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuIte... | |
readMarkerItem = new JMenuItem(READ_MARKERS); setAccelerator(readMarkerItem, 'I', false); readMarkerItem.addActionListener(this); readMarkerItem.setEnabled(false); fileMenu.add(readMarkerItem); | public HaploView(){ //menu setup JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; //file menu JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuIte... | |
readMarkerItem = new JMenuItem(READ_MARKERS); setAccelerator(readMarkerItem, 'I', false); readMarkerItem.addActionListener(this); readMarkerItem.setEnabled(false); fileMenu.add(readMarkerItem); | public HaploView(){ //menu setup JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; //file menu JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuIte... | |
fileMenu.addSeparator(); | public HaploView(){ //menu setup JMenuBar menuBar = new JMenuBar(); setJMenuBar(menuBar); JMenuItem menuItem; //file menu JMenu fileMenu = new JMenu("File"); menuBar.add(fileMenu); menuItem = new JMenuItem(READ_GENOTYPES); setAccelerator(menuItem, 'O', false); menuItem.addActionListener(this); fileMenu.add(menuIte... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.