bugged stringlengths 6 599k | fixed stringlengths 10 599k | __index_level_0__ int64 0 1.13M |
|---|---|---|
public UserLog findLastUserLog(String principal) { try { // two different queries to grant compatibility with all databases Date lastLogin = (Date) findUnique(LASTUSERLOGDATE_QUERY, principal); List<UserLog> userLogList = (ArrayList<UserLog>) find(LASTUSERLOG_QUERY, principal, last... | public UserLog findLastUserLog(String principal) { try { // two different queries to grant compatibility with all databases Date lastLogin = findLastIdentityLogDate(principal); List<UserLog> userLogList = (ArrayList<UserLog>) find(LASTUSERLOG_QUERY, principal, lastLogin ); ... | 1,116,282 |
public Object exp(Object param) throws ParseException { if (param instanceof Number) { return new Double(Math.exp(((Number)param).doubleValue())); } else if (param instanceof Complex) { Complex z = (Complex) param; double x = z.re(); double y = z.im(); double mod = Math.exp(x); return new Co... | public Object exp(Object param) throws ParseException { if (param instanceof Number) { return new Double(Math.exp(((Number)param).doubleValue())); } else if (param instanceof Complex) { Complex z = (Complex) param; double x = z.re(); double y = z.im(); double mod = Math.exp(x); return new Co... | 1,116,283 |
public synchronized void doLoginEntry( StaplerRequest req, StaplerResponse rsp ) throws IOException { rsp.sendRedirect(req.getContextPath()); } | public synchronized void doLoginEntry( StaplerRequest req, StaplerResponse rsp ) throws IOException { rsp.sendRedirect(req.getContextPath()+"/"); } | 1,116,285 |
public synchronized void doLogout( StaplerRequest req, StaplerResponse rsp ) throws IOException { HttpSession session = req.getSession(false); if(session!=null) session.invalidate(); rsp.sendRedirect(req.getContextPath()); } | public synchronized void doLogout( StaplerRequest req, StaplerResponse rsp ) throws IOException { HttpSession session = req.getSession(false); if(session!=null) session.invalidate(); rsp.sendRedirect(req.getContextPath()+"/"); } | 1,116,286 |
public synchronized void doReload( StaplerRequest req, StaplerResponse rsp ) throws IOException { if(!Hudson.adminCheck(req,rsp)) return; load(); rsp.sendRedirect(req.getContextPath()); } | public synchronized void doReload( StaplerRequest req, StaplerResponse rsp ) throws IOException { if(!Hudson.adminCheck(req,rsp)) return; load(); rsp.sendRedirect(req.getContextPath()+"/"); } | 1,116,287 |
public MatrixValueI calcValue(MatrixValueI res, MatrixValueI param1,MatrixValueI param2) throws ParseException {// Number num = (Number) rhs.getEle(0);// res.setEle(0,lhs.getEle(num.intValue()-1)); if(param1 instanceof MVector) { if(param2 instanceof Scaler) { int index = ((Double) param2.getEle(0)).intV... | public MatrixValueI calcValue(MatrixValueI res, MatrixValueI param1,MatrixValueI param2) throws ParseException {// Number num = (Number) rhs.getEle(0);// res.setEle(0,lhs.getEle(num.intValue()-1)); if(param1 instanceof MVector) { if(param2 instanceof Scaler) { int index = ((Number) param2.getEle(0)).intV... | 1,116,288 |
public MatrixValueI calcValue(MatrixValueI res, MatrixValueI param1,MatrixValueI param2) throws ParseException {// Number num = (Number) rhs.getEle(0);// res.setEle(0,lhs.getEle(num.intValue()-1)); if(param1 instanceof MVector) { if(param2 instanceof Scaler) { int index = ((Double) param2.getEle(0)).intV... | public MatrixValueI calcValue(MatrixValueI res, MatrixValueI param1,MatrixValueI param2) throws ParseException {// Number num = (Number) rhs.getEle(0);// res.setEle(0,lhs.getEle(num.intValue()-1)); if(param1 instanceof MVector) { if(param2 instanceof Scaler) { int index = ((Double) param2.getEle(0)).intV... | 1,116,289 |
public void run(Stack stack) throws ParseException { checkStack(stack); // check the stack Object param1,param2; // get the parameter from the stack param2 = stack.pop(); param1 = stack.pop(); if(param1 instanceof MVector) { if(param2 instanceof Double) { Object val = ((MVector)... | public void run(Stack stack) throws ParseException { checkStack(stack); // check the stack Object param1,param2; // get the parameter from the stack param2 = stack.pop(); param1 = stack.pop(); if(param1 instanceof MVector) { if(param2 instanceof Number) { Object val = ((MVector)... | 1,116,290 |
public void run(Stack stack) throws ParseException { checkStack(stack); // check the stack Object param1,param2; // get the parameter from the stack param2 = stack.pop(); param1 = stack.pop(); if(param1 instanceof MVector) { if(param2 instanceof Double) { Object val = ((MVector)... | public void run(Stack stack) throws ParseException { checkStack(stack); // check the stack Object param1,param2; // get the parameter from the stack param2 = stack.pop(); param1 = stack.pop(); if(param1 instanceof MVector) { if(param2 instanceof Double) { Object val = ((MVector)... | 1,116,291 |
public void run(Stack stack) throws ParseException { checkStack(stack); // check the stack Object param1,param2; // get the parameter from the stack param2 = stack.pop(); param1 = stack.pop(); if(param1 instanceof MVector) { if(param2 instanceof Double) { Object val = ((MVector)... | public void run(Stack stack) throws ParseException { checkStack(stack); // check the stack Object param1,param2; // get the parameter from the stack param2 = stack.pop(); param1 = stack.pop(); if(param1 instanceof MVector) { if(param2 instanceof Double) { Object val = ((MVector)... | 1,116,292 |
private void loadProperties() { try { String path = getPath(); File inputFile = new File(path + getSep() + type + ".ini"); if (inputFile.exists()){ props.load(new FileInputStream(inputFile)); Debug.print(type + ".ini file read: " + inputFile.getAbsolutePath() +". Contents:"); } } catch... | private void loadProperties() { try { String path = getPath(); File inputFile = new File(path + getSep() + type + ".ini"); if (inputFile.exists()){ props.load(new FileInputStream(inputFile)); Debug.print(type + ".ini file read: " + inputFile.getAbsolutePath() +". Contents:"); } } catch... | 1,116,293 |
public void saveProperties() { try{ String path = getPath(); Debug.print("Storing props: " + path); FileOutputStream out = new FileOutputStream(path + "\\" + type +".ini"); props.store(out, "/* properties updated */"); } catch (Exception e) { System.out.println(e); } } | public void saveProperties() { try{ String path = getPath(); Debug.print("Storing props: " + path); FileOutputStream out = new FileOutputStream(path + "\\" + type +".ini"); props.store(out, "/* properties updated */"); } catch (Exception e) { System.out.println(e); } } | 1,116,294 |
public AdvancedFilterAction() { super( Localizer.getString( "AdvancedSearchFilter" ), IconFactory.EMPTY_IMAGE_16, Localizer.getString( "TTTAdvancedSearchFilter" ) ); refreshActionState(); } | public AdvancedFilterAction() { super( Localizer.getString( "AdvancedSearchFilter" ), IconFactory.EMPTY_IMAGE_16, Localizer.getString( "TTTAdvancedSearchFilter" ) ); refreshActionState(); } | 1,116,295 |
public boolean equals(PNodeI node) { if(!(node instanceof POperator)) return false; POperator op = (POperator) node; if(!this.op.equals(op)) return false; if(args.length != op.args.length) return false; for(int i=0;i<args.length;++i) if(!args[i].equals(op.args[i])) return false; return true; } | public boolean equals(PNodeI node) { if(!(node instanceof POperator)) return false; POperator op = (POperator) node; if(!this.op.equals(op)) return false; if(args.length != op.args.length) return false; for(int i=0;i<args.length;++i) if(!args[i].equals(op.args[i])) return false; return true; } | 1,116,296 |
public boolean equals(PNodeI node) { if(!(node instanceof POperator)) return false; POperator op = (POperator) node; if(!this.op.equals(op)) return false; if(args.length != op.args.length) return false; for(int i=0;i<args.length;++i) if(!args[i].equals(op.args[i])) return false; return true; } | public boolean equals(PNodeI node) { if(!(node instanceof POperator)) return false; POperator op = (POperator) node; if(!this.op.equals(op)) return false; if(args.length != op.args.length) return false; for(int i=0;i<args.length;++i) if(!args[i].equals(nodeOp.args[i])) return false; return true; } | 1,116,297 |
private String checkFileType(File f) { if (f.getPath().endsWith(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines if (f.getPath().endsWith(".qbrew") || (f.getPath().endsWith(".xml"))) { try { FileReader in = new FileReader(f); BufferedReader inb = new BufferedRead... | private String checkFileType(File f) { if (f.getPath().endsWith(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines if (f.getPath().endsWith(".qbrew") || (f.getPath().endsWith(".xml"))) { try { FileReader in = new FileReader(f); BufferedReader inb = new BufferedRead... | 1,116,298 |
private String checkFileType(File f) { if (f.getPath().endsWith(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines if (f.getPath().endsWith(".qbrew") || (f.getPath().endsWith(".xml"))) { try { FileReader in = new FileReader(f); BufferedReader inb = new BufferedRead... | private String checkFileType(File f) { if (f.getPath().endsWith(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines if (f.getPath().endsWith(".qbrew") || (f.getPath().endsWith(".xml"))) { try { FileReader in = new FileReader(f); BufferedReader inb = new BufferedRead... | 1,116,299 |
public PNodeI div(PNodeI c) throws ParseException { if(this.isZero()) { if(c.isZero()) return pc.nanConstant; else return pc.zeroConstant; } if(c.isZero()) return pc.infConstant; if(c.isOne()) return this; if(c instanceof Constant) return new Constant(pc,pc.div(value,((Constant) c).value)); return ... | public PNodeI div(PNodeI c) throws ParseException { if(this.isZero()) { if(c.isZero()) return pc.nanConstant; return pc.zeroConstant; } if(c.isZero()) return pc.infConstant; if(c.isOne()) return this; if(c instanceof Constant) return new Constant(pc,pc.div(value,((Constant) c).value)); return super... | 1,116,300 |
public boolean equals(PNodeI node) { if(node instanceof Constant) return value.equals(((Constant)node).value); else return false; } | public boolean equals(PNodeI node) { if(node instanceof Constant) return value.equals(((Constant)node).value); else return false; } | 1,116,301 |
public PNodeI pow(PNodeI c) throws ParseException { if(this.isZero()){ if(c.isZero()) return pc.nanConstant; else return pc.zeroConstant; } if(this.isOne()) return pc.oneConstant; if(c.isZero()) return pc.oneConstant; if(c instanceof Constant) return new Constant(pc,pc.raise(value,((Constant) c).value));... | public PNodeI pow(PNodeI c) throws ParseException { if(this.isZero()){ if(c.isZero()) return pc.nanConstant; return pc.zeroConstant; } if(this.isOne()) return pc.oneConstant; if(c.isZero()) return pc.oneConstant; if(c instanceof Constant) return new Constant(pc,pc.raise(value,((Constant) c).value)); re... | 1,116,302 |
private void calcAlcohol(String method) { double oPlato = sGToPlato(estOg); double fPlato = sGToPlato(estFg); double q = 0.22 + 0.001 * oPlato; double re = (q * oPlato + fPlato) / (1.0 + q); // calculate by weight: alcohol = (oPlato - re) / (2.0665 - 0.010665 * oPlato); if (method == "Volume") // convert to by ... | private void calcAlcohol(String method) { double oPlato = sGToPlato(estOg); double fPlato = sGToPlato(estFg); double q = 0.22 + 0.001 * oPlato; double re = (q * oPlato + fPlato) / (1.0 + q); // calculate by weight: alcohol = (oPlato - re) / (2.0665 - 0.010665 * oPlato); if (method.equalsIgnoreCase("Volume")) //... | 1,116,304 |
public String toText(){ MessageFormat mf; StringBuffer sb = new StringBuffer(); sb.append("StrangeBrew J1.0 recipe text output\n\n"); sb.append("Details:\n"); sb.append("Name: " + name + "\n"); sb.append("Brewer: " + brewer + "\n"); sb.append("Size: " + SBStringUtils.df1.format(postBoilVol.getValue()) + " " + p... | public String toText(){ MessageFormat mf; StringBuffer sb = new StringBuffer(); sb.append("StrangeBrew J1.0 recipe text output\n\n"); sb.append("Details:\n"); sb.append("Name: " + name + "\n"); sb.append("Brewer: " + brewer + "\n"); sb.append("Size: " + SBStringUtils.df1.format(postBoilVol.getValue()) + " " + p... | 1,116,305 |
public static final int getPixel(int totalPixels, UnitRangeImpl range, double value) { return (int)Math.round(linearInterp(range.getMinValue(), 0, range.getMaxValue(), totalPixels, ... | public static final int getPixel(int totalPixels, UnitRangeImpl range, double value) { return (int)Math.round(linearInterp(range.getMinValue(), 0, range.getMaxValue(), totalPixels, ... | 1,116,307 |
public int compare(Object obj1, Object obj2) { if( obj1 == obj2 || obj1.equals( obj2 ) ) { return 0; } SearchResultElement sr1 = (SearchResultElement)obj1; SearchResultElement sr2 = (SearchResultElement)obj2; long diff; switch ( sortFiel... | public int compare( SearchResultElement sr1, SearchResultElement sr2 ) { if( obj1 == obj2 || obj1.equals( obj2 ) ) { return 0; } SearchResultElement sr1 = (SearchResultElement)obj1; SearchResultElement sr2 = (SearchResultElement)obj2; long diff... | 1,116,308 |
public int compare(Object obj1, Object obj2) { if( obj1 == obj2 || obj1.equals( obj2 ) ) { return 0; } SearchResultElement sr1 = (SearchResultElement)obj1; SearchResultElement sr2 = (SearchResultElement)obj2; long diff; switch ( sortFiel... | public int compare(Object obj1, Object obj2) { if( sr1 == sr2 || sr1.equals( sr2 ) ) { return 0; } SearchResultElement sr1 = (SearchResultElement)obj1; SearchResultElement sr2 = (SearchResultElement)obj2; long diff; switch ( sortField ) ... | 1,116,309 |
public int compare(Object obj1, Object obj2) { if( obj1 == obj2 || obj1.equals( obj2 ) ) { return 0; } SearchResultElement sr1 = (SearchResultElement)obj1; SearchResultElement sr2 = (SearchResultElement)obj2; long diff; switch ( sortFiel... | public int compare(Object obj1, Object obj2) { if( obj1 == obj2 || obj1.equals( obj2 ) ) { return 0; } SearchResultElement sr1 = (SearchResultElement)obj1; SearchResultElement sr2 = (SearchResultElement)obj2; long diff; switch ( sortFiel... | 1,116,310 |
public void testDefaultAuthorityResolution() { UserRole childUserRole = new UserRole(), parentUserRole = new UserRole(); childUserRole.setServiceExtension("1"); parentUserRole.setServiceExtension("2"); User user = userDetailsAdapter.getUser(); user.setParent(new UserGroup()); ... | public void testDefaultAuthorityResolution() { UserRole childUserRole = new UserRole(), parentUserRole = new UserRole(); childUserRole.setServiceExtension("1"); parentUserRole.setServiceExtension("2"); User user = userDetailsAdapter.getUser(); user.setParent(new UserGroup()); ... | 1,116,311 |
public void testDuplicateDefaultAuthorityResolution() { UserRole childUserRole = new UserRole(), parentUserRole = new UserRole(); childUserRole.setServiceExtension("1"); parentUserRole.setServiceExtension("2"); User user = userDetailsAdapter.getUser(); user.setParent(new UserGroup... | public void testDuplicateDefaultAuthorityResolution() { UserRole childUserRole = new UserRole(), parentUserRole = new UserRole(); childUserRole.setServiceExtension("1"); parentUserRole.setServiceExtension("2"); User user = userDetailsAdapter.getUser(); user.setParent(new UserGroup... | 1,116,312 |
public ConnectionEngine( Host connectedHost ) { this.connectedHost = connectedHost; connection = connectedHost.getConnection(); shareMgr = ShareManager.getInstance(); queryHistory = QueryManager.getInstance().getQueryHistoryMonitor(); messageMgr = MsgManager.getInstance(); ... | public ConnectionEngine( Host connectedHost ) { this.connectedHost = connectedHost; connection = connectedHost.getConnection(); shareMgr = ShareManager.getInstance(); queryHistory = QueryManager.getInstance().getQueryHistoryMonitor(); messageMgr = MsgManager.getInstance(); ... | 1,116,313 |
public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | 1,116,315 |
public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | 1,116,316 |
public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | 1,116,317 |
public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | 1,116,318 |
public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | 1,116,319 |
public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | 1,116,320 |
public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | public void processIncomingData() throws IOException { headerBuffer = new byte[ MsgHeader.DATA_LENGTH ]; try { while ( true ) { MsgHeader header = readHeader(); byte[] body = MessageProcessor.readMessageBody( connection, ... | 1,116,321 |
private SearchResultsDataModel( Search search ) { this.search = search; allRemoteFiles = new ArrayList(); allSearchResultSHA1Set = new HashSet(); allSearchResultCount = 0; displayedSearchResults = new ArrayList(); displayedSearchResultSHA1Map = new HashMap(); sear... | private SearchResultsDataModel( Search search ) { this.search = search; allRemoteFiles = new ArrayList(); allSearchResultSHA1Set = new HashSet(); allSearchResultCount = 0; displayedSearchResults = new ArrayList(); displayedSearchResultSHA1Map = new HashMap(); sear... | 1,116,323 |
private SearchResultsDataModel( Search search ) { this.search = search; allRemoteFiles = new ArrayList(); allSearchResultSHA1Set = new HashSet(); allSearchResultCount = 0; displayedSearchResults = new ArrayList(); displayedSearchResultSHA1Map = new HashMap(); sear... | private SearchResultsDataModel( Search search ) { this.search = search; allRemoteFiles = new ArrayList(); allSearchResultSHA1Set = new HashSet(); allSearchResultCount = 0; displayedSearchResults = new ArrayList(); displayedSearchResultSHA1Map = new HashMap(); sear... | 1,116,324 |
private SearchResultsDataModel( Search search ) { this.search = search; allRemoteFiles = new ArrayList(); allSearchResultSHA1Set = new HashSet(); allSearchResultCount = 0; displayedSearchResults = new ArrayList(); displayedSearchResultSHA1Map = new HashMap(); sear... | private SearchResultsDataModel( Search search ) { this.search = search; allRemoteFiles = new ArrayList(); allSearchResultSHA1Set = new HashSet(); allSearchResultCount = 0; displayedSearchResults = new ArrayList(); displayedSearchResultSHA1Map = new HashMap(); sear... | 1,116,325 |
private void addSearchResultForDisplay(RemoteFile remoteFile) { SearchResultElement resultElement = null; String sha1 = remoteFile.getSHA1(); if ( sha1 != null ) { resultElement = (SearchResultElement)displayedSearchResultSHA1Map.get( sha1 ); } if ( resultElem... | private void addSearchResultForDisplay(RemoteFile remoteFile) { SearchResultElement resultElement = null; String sha1 = remoteFile.getSHA1(); if ( sha1 != null ) { resultElement = displayedSearchResultSHA1Map.get( sha1 ); } if ( resultElement != null ) ... | 1,116,326 |
public SearchResultElement getSearchElementAt( int index ) { if ( index < 0 || index >= displayedSearchResults.size() ) { return null; } return (SearchResultElement)displayedSearchResults.get( index ); } | public SearchResultElement getSearchElementAt( int index ) { if ( index < 0 || index >= displayedSearchResults.size() ) { return null; } return displayedSearchResults.get( index ); } | 1,116,327 |
private void processFilterRules( RemoteFile[] remoteFiles ) { if ( searchFilterRuleSet == null ) { return; } if ( quickFilterRule != null ) { quickFilterRule.process(search, remoteFiles); } Iterator iterator = searchFilterRuleSet.iterator(); ... | private void processFilterRules( RemoteFile[] remoteFiles ) { if ( searchFilterRuleSet == null ) { return; } if ( quickFilterRule != null ) { quickFilterRule.process(search, remoteFiles); } Iterator iterator = searchFilterRuleSet.iterator(); ... | 1,116,328 |
private void processFilterRules( RemoteFile[] remoteFiles ) { if ( searchFilterRuleSet == null ) { return; } if ( quickFilterRule != null ) { quickFilterRule.process(search, remoteFiles); } Iterator iterator = searchFilterRuleSet.iterator(); ... | private void processFilterRules( RemoteFile[] remoteFiles ) { if ( searchFilterRuleSet == null ) { return; } if ( quickFilterRule != null ) { quickFilterRule.process(search, remoteFiles); } Iterator iterator = searchFilterRuleSet.iterator(); ... | 1,116,329 |
private void updateSecurityFilteredQueryList( IPAccessRule rule ) { // the code is basically the same as updateFilteredQueryList // except that is using a list for better performance. synchronized( allRemoteFiles ) { synchronized( displayedSearchResults ) { //... | private void updateSecurityFilteredQueryList( IPAccessRule rule ) { // the code is basically the same as updateFilteredQueryList // except that is using a list for better performance. synchronized( allRemoteFiles ) { synchronized( displayedSearchResults ) { //... | 1,116,330 |
private void updateSecurityFilteredQueryList( IPAccessRule rule ) { // the code is basically the same as updateFilteredQueryList // except that is using a list for better performance. synchronized( allRemoteFiles ) { synchronized( displayedSearchResults ) { //... | private void updateSecurityFilteredQueryList( IPAccessRule rule ) { // the code is basically the same as updateFilteredQueryList // except that is using a list for better performance. synchronized( allRemoteFiles ) { synchronized( displayedSearchResults ) { //... | 1,116,331 |
private void updateSecurityFilteredQueryList( IPAccessRule rule ) { // the code is basically the same as updateFilteredQueryList // except that is using a list for better performance. synchronized( allRemoteFiles ) { synchronized( displayedSearchResults ) { //... | private void updateSecurityFilteredQueryList( IPAccessRule rule ) { // the code is basically the same as updateFilteredQueryList // except that is using a list for better performance. synchronized( allRemoteFiles ) { synchronized( displayedSearchResults ) { //... | 1,116,332 |
public Object power(Object param1, Object param2) throws ParseException { if (param1 instanceof Number) { if (param2 instanceof Number) { return power((Number)param1, (Number)param2); } else if (param2 instanceof Complex) { return power((Number)param1, (Complex)param2); } } else if (param1 instanceof Co... | public Object power(Object param1, Object param2) throws ParseException { if (param1 instanceof Number) { if (param2 instanceof Number) { return power((Number)param1, (Number)param2); } else if (param2 instanceof Complex) { return power((Number)param1, (Complex)param2); } } else if (param1 instanceof Co... | 1,116,333 |
public Object power(Object param1, Object param2) throws ParseException { if (param1 instanceof Number) { if (param2 instanceof Number) { return power((Number)param1, (Number)param2); } else if (param2 instanceof Complex) { return power((Number)param1, (Complex)param2); } } else if (param1 instanceof Co... | public Object power(Object param1, Object param2) throws ParseException { if (param1 instanceof Number) { if (param2 instanceof Number) { return power((Number)param1, (Number)param2); } else if (param2 instanceof Complex) { return power((Number)param1, (Complex)param2); } } else if (param1 instanceof Co... | 1,116,334 |
public void setAsText(String id) throws IllegalArgumentException { setAsText(id, ExternalDocument.class); } | public void setAsText(String id) throws IllegalArgumentException { if (logger.isDebugEnabled()) { logger.debug("Loaded ExternalDocument property editor"); } try { Object value = getHibernateTemplate().load(ExternalDocument.class, Long.parseLong(id)); super.setValue(value); if (logger.isDebugEnabled()... | 1,116,335 |
public int getDownloadFileCount( int status ) { int count = 0; synchronized( downloadList ) { for ( SWDownloadFile file : downloadList ) { if ( file.getStatus() == status ) { count ++; } } ... | public int getDownloadFileCount() { int count = 0; synchronized( downloadList ) { for ( SWDownloadFile file : downloadList ) { if ( file.getStatus() == status ) { count ++; } } } re... | 1,116,337 |
public int getDownloadFileCount( int status ) { int count = 0; synchronized( downloadList ) { for ( SWDownloadFile file : downloadList ) { if ( file.getStatus() == status ) { count ++; } } ... | public int getDownloadFileCount( int status ) { int count = 0; synchronized( downloadList ) { for ( SWDownloadFile file : downloadList ) { if ( file.getStatus() == status ) { count ++; } } ... | 1,116,338 |
private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | 1,116,339 |
private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | 1,116,340 |
private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | 1,116,341 |
private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | private void readHeader() throws IOException{ /**Variable Header Length**/ //varHeadLength = dis.readInt(); varHeadLength = SacTimeSeries.swapBytes(dis.readInt()); //System.out.println("varHeadLength = " + Integer.toHexString(varHeadLength) + " or " + varHeadLength); dateTime = n... | 1,116,342 |
MutiableMonomial toMutiableMonomial() throws ParseException { PNodeI newTerms[] = new PNodeI[vars.length]; PNodeI newPows[] = new PNodeI[vars.length]; for(int i=0;i<vars.length;++i){ newTerms[i] = vars[i]; newPows[i] = powers[i]; } return new MutiableMonomial(pc,coeff,newTerms,newPows); } | MutiableMonomial toMutiableMonomial() { PNodeI newTerms[] = new PNodeI[vars.length]; PNodeI newPows[] = new PNodeI[vars.length]; for(int i=0;i<vars.length;++i){ newTerms[i] = vars[i]; newPows[i] = powers[i]; } return new MutiableMonomial(pc,coeff,newTerms,newPows); } | 1,116,343 |
PNodeI valueOf(Constant coeff,PNodeI terms[],PNodeI pows[]) throws ParseException { if(coeff.isZero()) return pc.zeroConstant; if(terms.length ==0) return coeff; return new Monomial(pc,coeff,terms,pows); } | PNodeI valueOf(Constant coefficient,PNodeI terms[],PNodeI pows[]) { if(coeff.isZero()) return pc.zeroConstant; if(terms.length ==0) return coeff; return new Monomial(pc,coeff,terms,pows); } | 1,116,344 |
PNodeI valueOf(Constant coeff,PNodeI terms[],PNodeI pows[]) throws ParseException { if(coeff.isZero()) return pc.zeroConstant; if(terms.length ==0) return coeff; return new Monomial(pc,coeff,terms,pows); } | PNodeI valueOf(Constant coeff,PNodeI terms[],PNodeI pows[]) throws ParseException { if(coeff.isZero()) return pc.zeroConstant; if(terms.length ==0) return coeff; return new Monomial(pc,coeff,terms,pows); } | 1,116,345 |
private StationId[] extractAll(PreparedStatement query) throws SQLException { System.out.println(query); ResultSet rs = query.executeQuery(); List aList = new ArrayList(); try { while(rs.next()) aList.add(extractId(rs, netTable, time)); } catch(NotFound e... | private StationId[] extractAll(PreparedStatement query) throws SQLException { ResultSet rs = query.executeQuery(); List aList = new ArrayList(); try { while(rs.next()) aList.add(extractId(rs, netTable, time)); } catch(NotFound e) { return new ... | 1,116,346 |
public synchronized void doConfigSubmit( StaplerRequest req, StaplerResponse rsp ) throws IOException { useSecurity = req.getParameter("use_security")!=null; numExecutors = Integer.parseInt(req.getParameter("numExecutors")); for( Executor e : executors ) e.interrupt(); while(e... | public synchronized void doConfigSubmit( StaplerRequest req, StaplerResponse rsp ) throws IOException { useSecurity = req.getParameter("use_security")!=null; numExecutors = Integer.parseInt(req.getParameter("numExecutors")); for( Executor e : executors ) e.interrupt(); while(e... | 1,116,347 |
public synchronized void doConfigSubmit( StaplerRequest req, StaplerResponse rsp ) throws IOException { useSecurity = req.getParameter("use_security")!=null; numExecutors = Integer.parseInt(req.getParameter("numExecutors")); for( Executor e : executors ) e.interrupt(); while(e... | public synchronized void doConfigSubmit( StaplerRequest req, StaplerResponse rsp ) throws IOException { useSecurity = req.getParameter("use_security")!=null; numExecutors = Integer.parseInt(req.getParameter("numExecutors")); for( Executor e : executors ) e.interrupt(); while(e... | 1,116,348 |
private void load() throws IOException { if(getConfigFile().exists()) { Reader r = new InputStreamReader(new FileInputStream(getConfigFile()),"UTF-8"); createConfiguredStream().unmarshal(new XppReader(r),this); r.close(); } File projectsDir = new File(root,"jobs... | private void load() throws IOException { if(getConfigFile().exists()) { Reader r = new InputStreamReader(new FileInputStream(getConfigFile()),"UTF-8"); createConfiguredStream().unmarshal(new XppReader(r),this); r.close(); } File projectsDir = new File(root,"jobs... | 1,116,349 |
private void load() throws IOException { if(getConfigFile().exists()) { Reader r = new InputStreamReader(new FileInputStream(getConfigFile()),"UTF-8"); createConfiguredStream().unmarshal(new XppReader(r),this); r.close(); } File projectsDir = new File(root,"jobs... | private void load() throws IOException { if(getConfigFile().exists()) { Reader r = new InputStreamReader(new FileInputStream(getConfigFile()),"UTF-8"); createConfiguredStream().unmarshal(new XppReader(r),this); r.close(); } File projectsDir = new File(root,"jobs... | 1,116,350 |
public Object cosh(Object param) throws ParseException { if (param instanceof Number) { double value = ((Number)param).doubleValue(); return new Double((Math.exp(value) + Math.exp(-value))/2); } else if (param instanceof Complex) { return ((Complex)param).cosh(); } throw new ParseException("Invalid param... | public Object cosh(Object param) throws ParseException { if (param instanceof Complex) { return ((Complex)param).cosh(); } else if (param instanceof Number) { double value = ((Number)param).doubleValue(); return new Double((Math.exp(value) + Math.exp(-value))/2); } else if (param instanceof Complex) { retu... | 1,116,351 |
public Object cosh(Object param) throws ParseException { if (param instanceof Number) { double value = ((Number)param).doubleValue(); return new Double((Math.exp(value) + Math.exp(-value))/2); } else if (param instanceof Complex) { return ((Complex)param).cosh(); } throw new ParseException("Invalid param... | public Object cosh(Object param) throws ParseException { if (param instanceof Number) { double value = ((Number)param).doubleValue(); return new Double((Math.exp(value) + Math.exp(-value))/2); } else if (param instanceof Complex) { return ((Complex)param).cosh(); } throw new ParseException("Invalid param... | 1,116,352 |
public boolean hasFreeLeafSlots() { if ( !ggepBlock.isExtensionAvailable( GGEPBlock.ULTRAPEER_ID ) ) { return false; } byte[] data = ggepBlock.getExtensionData( GGEPBlock.ULTRAPEER_ID ); if ( data != null ) { if( data.length >= 3 ) { ... | public boolean hasFreeLeafSlots() { if ( ggepBlock == null || !ggepBlock.isExtensionAvailable( GGEPBlock.ULTRAPEER_ID ) ) { return false; } byte[] data = ggepBlock.getExtensionData( GGEPBlock.ULTRAPEER_ID ); if ( data != null ) { if( data.length >= ... | 1,116,353 |
public boolean hasFreeUPSlots() { if ( !ggepBlock.isExtensionAvailable( GGEPBlock.ULTRAPEER_ID ) ) { return false; } byte[] data = ggepBlock.getExtensionData( GGEPBlock.ULTRAPEER_ID ); if ( data != null ) { if( data.length >= 3 ) { ... | public boolean hasFreeUPSlots() { if ( ggepBlock == null || !ggepBlock.isExtensionAvailable( GGEPBlock.ULTRAPEER_ID ) ) { return false; } byte[] data = ggepBlock.getExtensionData( GGEPBlock.ULTRAPEER_ID ); if ( data != null ) { if( data.length >= 3 ... | 1,116,354 |
public void doBuildStatus( StaplerRequest req, StaplerResponse rsp ) throws IOException { rsp.sendRedirect(req.getContextPath()+"/images/48x48/"+getBuildStatusUrl()); } | public void doBuildStatus( StaplerRequest req, StaplerResponse rsp ) throws IOException { rsp.sendRedirect(req.getContextPath()+"/nocacheImages/48x48/"+getBuildStatusUrl()); } | 1,116,355 |
public Node deepCopy(Node node,XJep xjep) throws ParseException { this.xjep = xjep; Node res = (Node) node.jjtAccept(this,null); return res; } | public Node deepCopy(Node node,XJep xj) throws ParseException { this.xjep = xjep; Node res = (Node) node.jjtAccept(this,null); return res; } | 1,116,360 |
public Node deepCopy(Node node,XJep xjep) throws ParseException { this.xjep = xjep; Node res = (Node) node.jjtAccept(this,null); return res; } | public Node deepCopy(Node node,XJep xjep) throws ParseException { this.xjep = xj; Node res = (Node) node.jjtAccept(this,null); return res; } | 1,116,361 |
public void endElement(String namespaceURI, String sName, // simple name String qName // qualified name ) throws SAXException { if (importType == "STRANGEBREW") { if (qName.equalsIgnoreCase("ITEM") && currentList.equalsIgnoreCase("FERMENTABLES")) { r.addMalt(m); m = null; } else if (qName.equalsIgnore... | public void endElement(String namespaceURI, String sName, // simple name String qName // qualified name ) throws SAXException { if (importType == "STRANGEBREW") { if (qName.equalsIgnoreCase("ITEM") && currentList.equalsIgnoreCase("FERMENTABLES")) { r.addMalt(m); m = null; } else if (qName.equalsIgnore... | 1,116,362 |
void sbStartElement(String eName) { if (eName.equalsIgnoreCase("DETAILS")) { currentList = "DETAILS"; } else if (eName.equalsIgnoreCase("FERMENTABLES")) { currentList = "FERMENTABLES"; } else if (eName.equalsIgnoreCase("HOPS")) { currentList = "HOPS"; } else if (eName.equalsIgnoreCase("MASH") && currentList.... | void sbStartElement(String eName) { if (eName.equalsIgnoreCase("DETAILS")) { currentList = "DETAILS"; } else if (eName.equalsIgnoreCase("FERMENTABLES")) { currentList = "FERMENTABLES"; } else if (eName.equalsIgnoreCase("HOPS")) { currentList = "HOPS"; } else if (eName.equalsIgnoreCase("MASH") && currentList.... | 1,116,363 |
public Object locateService(String name) { Reference ref = config.getReference(name); return ref.getService(); } | public Object locateService(Object bindObject, String name) { Reference ref = config.getReference(name); return ref.getService(); } | 1,116,364 |
public Object locateService(String name) { Reference ref = config.getReference(name); return ref.getService(); } | public Object locateService(String name) { Reference ref = config.getReference(name); return ref.getService(bindObject); } | 1,116,365 |
public Object[] locateServices(String name) { Reference ref = config.getReference(name); return ref.getServiceReferences(); } | public Object[] locateServices(Object bindObject, String name) { Reference ref = config.getReference(name); return ref.getServiceReferences(); } | 1,116,366 |
public Object[] locateServices(String name) { Reference ref = config.getReference(name); return ref.getServiceReferences(); } | public Object[] locateServices(String name) { Reference ref = config.getReference(name); ServiceReference[] refs = ref.getServiceReferences(); Object[] ret = new Object[refs.length]; for (int i = 0; i < refs.length; i++) { ret[i] = ref.getService(bindObject, refs[i]); } return ret; ... | 1,116,367 |
public synchronized void activate() { // this method is described on page 297 r4 // Synchronized because the service is registered before activation, // enabling another thread to get the service and thereby trigger a // second activate() call. if (!config.isEnabled() || !config.i... | public synchronized void activate() { // this method is described on page 297 r4 // Synchronized because the service is registered before activation, // enabling another thread to get the service and thereby trigger a // second activate() call. if (!config.isEnabled() || !config.i... | 1,116,369 |
public synchronized void activate() { // this method is described on page 297 r4 // Synchronized because the service is registered before activation, // enabling another thread to get the service and thereby trigger a // second activate() call. if (!config.isEnabled() || !config.i... | public synchronized void activate() { // this method is described on page 297 r4 // Synchronized because the service is registered before activation, // enabling another thread to get the service and thereby trigger a // second activate() call. if (!config.isEnabled() || !config.i... | 1,116,370 |
public synchronized void deactivate() { // this method is described on page 432 r4 if (!isActivated()) return; try { Class klass = instance.getClass(); Method method = klass.getDeclaredMethod("deactivate", new Class[] { ComponentContext.class ... | public synchronized void deactivate() { // this method is described on page 432 r4 if (!isActivated()) return; try { Class klass = instance.getClass(); Method method = klass.getDeclaredMethod("deactivate", new Class[] { ComponentContext.class ... | 1,116,371 |
public void registerService() { if (Activator.log.doDebug()) { Activator.log.debug("registerService() got BundleContext: " + bundleContext); } if (!config.getShouldRegisterService()) return; String[] interfaces = config.getServices(); if (i... | public void registerService() { if (Activator.log.doDebug()) { Activator.log.debug("registerService() got BundleContext: " + bundleContext); } if (!config.getShouldRegisterService()) return; String[] interfaces = config.getServices(); if (i... | 1,116,372 |
public void bindReferences(Object instance, Bundle bundle) { for (int i = 0; i < references.size(); i++) { ((Reference) references.get(i)).bind(instance); } for (DuplexReference ref : this.duplexReferences) { ref.bind(instance, bundle); } } | public void bindReferences(Object instance, Object duplexObject) { for (int i = 0; i < references.size(); i++) { ((Reference) references.get(i)).bind(instance); } for (DuplexReference ref : this.duplexReferences) { ref.bind(instance, bundle); } } | 1,116,373 |
public void bindReferences(Object instance, Bundle bundle) { for (int i = 0; i < references.size(); i++) { ((Reference) references.get(i)).bind(instance); } for (DuplexReference ref : this.duplexReferences) { ref.bind(instance, bundle); } } | public void bindReferences(Object instance, Bundle bundle) { for (int i = 0; i < references.size(); i++) { ((Reference) references.get(i)).bind(instance); } for (DuplexReference ref : this.duplexReferences) { ref.bind(instance, duplexObject); } } | 1,116,374 |
public void unbindReferences(Object instance) { for (int i = references.size() - 1; i >= 0; i--) { ((Reference) references.get(i)).unbind(instance); } for (DuplexReference ref : this.duplexReferences) { ref.unbind(instance); } } | public void unbindReferences(Object instance, Object duplexObject) { for (int i = this.duplexReferences.size() - 1; i >= 0; i--) { this.duplexReferences.get(i).unbind(instance, duplexObject); } for (int i = references.size() - 1; i >= 0; i--) { ((Reference) references.get(i)).unbind(instance); ... | 1,116,375 |
public void unbindReferences(Object instance) { for (int i = references.size() - 1; i >= 0; i--) { ((Reference) references.get(i)).unbind(instance); } for (DuplexReference ref : this.duplexReferences) { ref.unbind(instance); } } | public void unbindReferences(Object instance) { for (int i = references.size() - 1; i >= 0; i--) { ((Reference) references.get(i)).unbind(instance); } for (DuplexReference ref : this.duplexReferences) { ref.unbind(instance); } } | 1,116,376 |
public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | 1,116,377 |
public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | 1,116,378 |
public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | 1,116,379 |
public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | 1,116,380 |
public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | public int compare( String key1, String key2 ) { if ( key1 == key2 || key1.equals( key2 ) ) { return 0; } int idx1 = key1.lastIndexOf( LIST_POSTFIX ) + LIST_POSTFIX.length(); String val1Str = key1.substring( idx1 ); int val1... | 1,116,381 |
private static List<String> deserializeList( String name, Preferences preferences ) { List<String> list = new ArrayList<String>(); List<String> names = preferences.getPrefixedPropertyNames( name + LIST_POSTFIX ); Collections.sort( names, new ListPostfixKeyComparator() ); for ( String ... | private static List<String> deserializeList( String name, Preferences preferences ) { List<String> list = new ArrayList<String>(); List<String> names = preferences.getPrefixedPropertyNames( name + LIST_DESER_POSTFIX ); Collections.sort( names, new ListPostfixKeyComparator() ); for ( S... | 1,116,382 |
private static Set<String> deserializeSet( String name, Preferences preferences ) { Set<String> set = new HashSet<String>(); String prefix = new String ( name + SET_POSTFIX ); List<String> names = preferences.getPrefixedPropertyNames( prefix ); for ( String key : names ) ... | private static Set<String> deserializeSet( String name, Preferences preferences ) { Set<String> set = new HashSet<String>(); String prefix = new String ( name + SET_DESER_POSTFIX ); List<String> names = preferences.getPrefixedPropertyNames( prefix ); for ( String key : names )... | 1,116,383 |
public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | 1,116,384 |
public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | 1,116,385 |
public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | 1,116,386 |
public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | public static void serializeSetting( Setting setting, Properties properties ) { String name = setting.getName(); Object value = setting.get(); if ( value instanceof String ) { properties.setProperty( name, (String)value ); } else if ( value instanceof Number )... | 1,116,387 |
public Rational(BigInteger num) { numerator = num; denominator = BigInteger.ONE; } | public Rational(BigInteger num) { numerator = num; denominator = BigInteger.ONE; } | 1,116,388 |
public String toString() { if(denominator.equals(BigInteger.ONE)) return numerator.toString(); else return numerator.toString() +"/" + denominator.toString(); } | public String toString() { if(denominator.equals(BigInteger.ONE)) return numerator.toString(); else return numerator.toString() +"/" + denominator.toString(); } | 1,116,389 |
public static Number valueOf(String s) { int pos = s.indexOf('/'); if(pos==-1) return new Rational(new BigInteger(s)); else return new Rational( new BigInteger(s.substring(pos-1)), new BigInteger(s.substring(pos+1,-1))); } | public static Number valueOf(String s) { int pos = s.indexOf('/'); if(pos==-1) return new Rational(new BigInteger(s)); else return new Rational( new BigInteger(s.substring(pos-1)), new BigInteger(s.substring(pos+1,-1))); } | 1,116,390 |
private String checkFileType(File f){ String suff = f.getPath().substring(f.getPath().length()-3, f.getPath().length()); Debug.print(suff); if (suff.equalsIgnoreCase(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines try { FileReader in = new FileReader(f); Buf... | private String checkFileType(File f){ String suff = f.getPath().substring(f.getPath().length()-3, f.getPath().length()); Debug.print(suff); if (suff.equalsIgnoreCase(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines try { FileReader in = new FileReader(f); Buf... | 1,116,392 |
private String checkFileType(File f){ String suff = f.getPath().substring(f.getPath().length()-3, f.getPath().length()); Debug.print(suff); if (suff.equalsIgnoreCase(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines try { FileReader in = new FileReader(f); Buf... | private String checkFileType(File f){ String suff = f.getPath().substring(f.getPath().length()-3, f.getPath().length()); Debug.print(suff); if (suff.equalsIgnoreCase(".rec")) return "promash"; // let's open it up and have a peek // we'll only read 10 lines try { FileReader in = new FileReader(f); Buf... | 1,116,393 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.