content
stringlengths
40
137k
"protected String getNeededModulesJarStr() {\n final boolean exportingJob = ProcessorUtilities.isExportConfig();\n final String classPathSeparator = extractClassPathSeparator();\n final String libPrefixPath = getLibPrefixPath(true);\n final File libDir = JavaProcessorUtilities.getJavaProjectLibFolder();\n Set<ModuleNeeded> neededModules = getNeededModules();\n JavaProcessorUtilities.checkJavaProjectLib(neededModules);\n Set<String> neededLibraries = new HashSet<String>();\n for (ModuleNeeded neededModule : neededModules) {\n neededLibraries.add(neededModule.getModuleName());\n }\n File[] jarFiles = libDir.listFiles(FilesUtils.getAcceptJARFilesFilter());\n StringBuffer libPath = new StringBuffer();\n if (jarFiles != null && jarFiles.length > 0) {\n for (File jarFile : jarFiles) {\n if (jarFile.isFile() && neededLibraries.contains(jarFile.getName())) {\n libPath.append(libPrefixPath);\n String singleLibPath = new Path(jarFile.getAbsolutePath()).toPortableString();\n if (exportingJob) {\n singleLibPath = singleLibPath.replace(new Path(libDir.getAbsolutePath()).toPortableString(), getBaseLibPath());\n }\n libPath.append(singleLibPath).append(classPathSeparator);\n }\n }\n }\n final int lastSep = libPath.length() - 1;\n if (libPath.length() != 0 && classPathSeparator.equals(String.valueOf(libPath.charAt(lastSep)))) {\n libPath.deleteCharAt(lastSep);\n }\n return libPath.toString();\n}\n"
"public void actionPerformed(ActionEvent e) {\n if (!list.isSelectionEmpty()) {\n String folder = folderlist.get(list.getSelectedIndex());\n openInFilebrowser(folder);\n}\n"
"protected String getJavaExecutable(Integer version) {\n StringBuilder builder = new StringBuilder();\n String javaHome;\n if (version == NO_JVM_VERSION) {\n javaHome = SystemProperty.INSTANCE.getProperty(\"String_Node_Str\");\n } else {\n String envName = \"String_Node_Str\" + version + \"String_Node_Str\";\n javaHome = SystemProperty.INSTANCE.getEnv(envName);\n }\n if (javaHome == null) {\n return null;\n }\n builder.append(javaHome);\n builder.append(File.separatorChar);\n builder.append(\"String_Node_Str\");\n builder.append(File.separatorChar);\n builder.append(\"String_Node_Str\");\n if (SystemProperty.INSTANCE.getProperty(\"String_Node_Str\").contains(\"String_Node_Str\")) {\n builder.append(\"String_Node_Str\");\n }\n return builder.toString();\n}\n"
"static void savePorts(Map<Integer, TravelPort> travelPorts, File csvFile) throws IOException {\n BufferedWriter writer = new BufferedWriter(new FileWriter(csvFile));\n for (TravelPort port : travelPorts.values()) {\n StringBuilder line = new StringBuilder();\n for (int index = 0; index < CSV_COLUMNS; ++index) {\n switch(index) {\n case INDEX_ID:\n line.append(port.getId());\n break;\n case INDEX_NAME:\n line.append(port.getName());\n break;\n case INDEX_TARGET:\n line.append(port.getTargetId());\n break;\n case INDEX_OWNER:\n line.append(port.getOwner());\n break;\n case INDEX_ALLOWED:\n if (port.isAllowedToEverybody()) {\n line.append(\"String_Node_Str\");\n } else {\n line.append(StringHelper.encode(port.getAllowed()));\n }\n break;\n case INDEX_PASSWORD:\n line.append(port.getPassword());\n break;\n case INDEX_PRICE:\n line.append(port.getPrice());\n break;\n case INDEX_WORLD:\n line.append(port.getEdge1().getWorld().getName());\n break;\n case INDEX_EDGE1_X:\n line.append(port.getEdge1().getX());\n break;\n case INDEX_EDGE1_Y:\n line.append(port.getEdge1().getBlockY());\n break;\n case INDEX_EDGE1_Z:\n line.append(port.getEdge1().getBlockZ());\n break;\n case INDEX_EDGE2_X:\n line.append(port.getEdge2().getBlockX());\n break;\n case INDEX_EDGE2_Y:\n line.append(port.getEdge2().getBlockY());\n break;\n case INDEX_EDGE2_Z:\n line.append(port.getEdge2().getBlockY());\n break;\n case INDEX_DESTINATION_X:\n line.append(port.getDestination().getBlockX());\n break;\n case INDEX_DESTINATION_Y:\n line.append(port.getDestination().getBlockY());\n break;\n case INDEX_DESTINATION_Z:\n line.append(port.getDestination().getBlockY());\n break;\n default:\n throw new RuntimeException(\"String_Node_Str\");\n }\n if (index + 1 < CSV_COLUMNS) {\n line.append(\"String_Node_Str\");\n }\n }\n writer.append(line.toString());\n writer.newLine();\n }\n writer.close();\n}\n"
"public static boolean validateImsManifest(QTI21ContentPackage cp, ResourceLocator resourceLocator) {\n try {\n if (cp.hasTest()) {\n URI test = cp.getTest().toUri();\n ResourceLocator chainedResourceLocator = createResolvingResourceLocator(resourceLocator);\n XmlReadResult result = new QtiXmlReader().read(chainedResourceLocator, test, true);\n return result != null && result.isSchemaValid();\n }\n return false;\n } catch (Exception e) {\n log.error(\"String_Node_Str\", e);\n return false;\n }\n}\n"
"public static void quickToast(final Context context, final String text, final int duration) {\n AndroidApi.UI_THREAD_HANDLER.post(new Runnable() {\n\n public void run() {\n Toast.makeText(context, text, duration).show();\n }\n });\n}\n"
"public void endVisit(SingleNameReference ref, BlockScope scope) {\n if (isRef(ref, thisJoinPointDec)) {\n needsDynamic = true;\n else if (isRef(ref, thisJoinPointStaticPartDec))\n needsStatic = true;\n else if (isRef(ref, thisEnclosingJoinPointStaticPartDec))\n needsStaticEnclosing = true;\n}\n"
"public DeviceContext createContext(ConfigElement cfg) throws DeviceContextException {\n authComponent.setCurrentUser(authComponent.getSystemUserName());\n UserTransaction tx = transactionService.getUserTransaction(true);\n ContentContext context = null;\n try {\n if (tx != null)\n tx.begin();\n ConfigElement storeElement = cfg.getChild(KEY_STORE);\n if (storeElement == null || storeElement.getValue() == null || storeElement.getValue().length() == 0) {\n throw new DeviceContextException(\"String_Node_Str\" + KEY_STORE);\n }\n String storeValue = storeElement.getValue();\n StoreRef storeRef = new StoreRef(storeValue);\n if (!nodeService.exists(storeRef)) {\n throw new DeviceContextException(\"String_Node_Str\" + storeRef);\n }\n NodeRef storeRootNodeRef = nodeService.getRootNode(storeRef);\n ConfigElement rootPathElement = cfg.getChild(KEY_ROOT_PATH);\n if (rootPathElement == null || rootPathElement.getValue() == null || rootPathElement.getValue().length() == 0) {\n throw new DeviceContextException(\"String_Node_Str\" + KEY_ROOT_PATH);\n }\n String rootPath = rootPathElement.getValue();\n List<NodeRef> nodeRefs = searchService.selectNodes(storeRootNodeRef, rootPath, null, namespaceService, false);\n NodeRef rootNodeRef = null;\n if (nodeRefs.size() > 1) {\n throw new DeviceContextException(\"String_Node_Str\" + \"String_Node_Str\" + rootPath + \"String_Node_Str\" + \"String_Node_Str\" + nodeRefs);\n } else if (nodeRefs.size() == 0) {\n throw new DeviceContextException(\"String_Node_Str\" + \"String_Node_Str\" + rootPath);\n } else {\n rootNodeRef = nodeRefs.get(0);\n }\n ConfigElement relativePathElement = cfg.getChild(KEY_RELATIVE_PATH);\n if (relativePathElement != null) {\n String relPath = relativePathElement.getValue().replace('/', FileName.DOS_SEPERATOR);\n NodeRef relPathNode = cifsHelper.getNodeRef(rootNodeRef, relPath);\n if (cifsHelper.isDirectory(relPathNode) == false)\n throw new DeviceContextException(\"String_Node_Str\" + relativePathElement.getValue());\n rootNodeRef = relPathNode;\n }\n tx.commit();\n tx = null;\n context = new ContentContext(storeValue, rootPath, rootNodeRef);\n context.setDiskInformation(new SrvDiskInfo(2560000, 64, 512, 2304000));\n context.setFilesystemAttributes(FileSystem.CasePreservedNames);\n } catch (Exception ex) {\n logger.error(\"String_Node_Str\", ex);\n } finally {\n if (tx != null) {\n try {\n tx.rollback();\n } catch (Exception ex) {\n logger.warn(\"String_Node_Str\", ex);\n }\n }\n }\n try {\n Object ioctlObj = Class.forName(\"String_Node_Str\").newInstance();\n if (ioctlObj instanceof IOControlHandler) {\n m_ioHandler = (IOControlHandler) ioctlObj;\n m_ioHandler.initialize(this, cifsHelper, transactionService, nodeService, checkInOutService);\n }\n if (m_ioHandler != null) {\n ConfigElement dragDropElem = cfg.getChild(\"String_Node_Str\");\n if (dragDropElem != null) {\n ConfigElement pseudoName = dragDropElem.getChild(\"String_Node_Str\");\n ConfigElement appPath = dragDropElem.getChild(\"String_Node_Str\");\n if (pseudoName != null && appPath != null) {\n URL appURL = this.getClass().getClassLoader().getResource(appPath.getValue());\n if (appURL == null)\n throw new DeviceContextException(\"String_Node_Str\" + appPath.getValue());\n File appFile = new File(appURL.getFile());\n if (appFile.exists() == false)\n throw new DeviceContextException(\"String_Node_Str\" + appPath.getValue());\n PseudoFile dragDropPseudo = new LocalPseudoFile(pseudoName.getValue(), appFile.getAbsolutePath());\n context.setDragAndDropApp(dragDropPseudo);\n }\n }\n }\n } catch (Exception ex) {\n if (logger.isDebugEnabled())\n logger.debug(\"String_Node_Str\");\n }\n ConfigElement urlFileElem = cfg.getChild(\"String_Node_Str\");\n if (urlFileElem != null) {\n ConfigElement pseudoName = urlFileElem.getChild(\"String_Node_Str\");\n ConfigElement webPath = urlFileElem.getChild(\"String_Node_Str\");\n if (pseudoName != null && webPath != null) {\n String path = webPath.getValue();\n if (path.endsWith(\"String_Node_Str\") == false)\n path = path + \"String_Node_Str\";\n if (pseudoName.getValue().endsWith(\"String_Node_Str\") == false)\n throw new DeviceContextException(\"String_Node_Str\" + pseudoName.getValue());\n context.setURLFileName(pseudoName.getValue());\n context.setURLPrefix(path);\n }\n }\n if (context.hasDragAndDropApp() || context.hasURLFile()) {\n m_pseudoFiles = new ContentPseudoFileImpl();\n }\n ConfigElement offlineFiles = cfg.getChild(\"String_Node_Str\");\n if (offlineFiles != null) {\n cifsHelper.setMarkLockedFilesAsOffline(true);\n logger.info(\"String_Node_Str\");\n }\n return context;\n}\n"
"private void releaseCommands(int param) {\n LockReleaser.getManager().releaseLocks();\n}\n"
"private Vec3f determinePosRecGenes(ClusterNode currentNode) {\n Vec3f pos = new Vec3f();\n if (tree.hasChildren(currentNode)) {\n ArrayList<ClusterNode> alChilds = tree.getChildren(currentNode);\n int iNrChildsNode = alChilds.size();\n Vec3f[] positions = new Vec3f[iNrChildsNode];\n for (int i = 0; i < iNrChildsNode; i++) {\n ClusterNode node = (ClusterNode) alChilds.get(i);\n positions[i] = determinePosRecGenes(node);\n }\n float fXmin = Float.MAX_VALUE;\n float fYmax = Float.MIN_VALUE;\n float fYmin = Float.MAX_VALUE;\n for (Vec3f vec : positions) {\n fXmin = Math.min(fXmin, vec.x());\n fYmax = Math.max(fYmax, vec.y());\n fYmin = Math.min(fYmin, vec.y());\n }\n float fCoeff = currentNode.getCoefficient();\n pos.setX(fXmin - fLevelWidth * (1 - fCoeff));\n pos.setY(fYmin + (fYmax - fYmin) / 2);\n pos.setZ(DENDROGRAM_Z);\n } else {\n pos.setY(yPosInit);\n yPosInit -= fSampleHeight;\n pos.setX(xGlobalMax - fLevelWidth);\n pos.setZ(DENDROGRAM_Z);\n }\n currentNode.setPos(pos);\n return pos;\n}\n"
"private void applyContainerTopBorder(Rule rule, int pos) {\n if (engine.getContainers().size() == 0) {\n return;\n }\n XlsContainer container = engine.getCurrentContainer();\n StyleEntry entry = container.getStyle();\n int col = engine.getAxis().getCoordinateIndex(rule.getStart());\n int span = engine.getAxis().getCoordinateIndex(rule.getEnd()) - col;\n for (int i = col; i < span + col; i++) {\n Data data = engine.getData(i, pos);\n if (data == null || data == engine.waste) {\n continue;\n }\n StyleBuilder.applyTopBorder(entry, data.style);\n }\n}\n"
"public void inject(ClassNode classNode, String artifactType) {\n classNode.addProperty(APP, ACC_PUBLIC, GRIFFON_APPLICATION_CLASS, null, null, null);\n FieldNode _metaClass = classNode.addField(\"String_Node_Str\", ACC_PRIVATE | ACC_SYNTHETIC, ClassHelper.METACLASS_TYPE, ConstantExpression.NULL);\n classNode.addMethod(new MethodNode(\"String_Node_Str\", ACC_PUBLIC, ClassHelper.METACLASS_TYPE, Parameter.EMPTY_ARRAY, ClassNode.EMPTY_ARRAY, block(ifs(ne(field(_metaClass), ConstantExpression.NULL), field(_metaClass)), decls(var(\"String_Node_Str\", ClassHelper.METACLASS_TYPE), ConstantExpression.NULL), ifs_no_return(iof(THIS, EXPANDO_METACLASS_CLASS), assigns(field(_metaClass), var(\"String_Node_Str\")), assigns(field(_metaClass), call(ABSTRACT_GRIFFON_ARTIFACT_CLASS, \"String_Node_Str\", args(THIS)))), returns(field(_metaClass)))));\n classNode.addMethod(new MethodNode(\"String_Node_Str\", ACC_PUBLIC, ClassHelper.VOID_TYPE, params(param(ClassHelper.METACLASS_TYPE, \"String_Node_Str\")), ClassNode.EMPTY_ARRAY, block(assigns(field(_metaClass), var(\"String_Node_Str\")), stmnt(call(call(GROOVY_SYSTEM_CLASS, \"String_Node_Str\", NO_ARGS), \"String_Node_Str\", args(call(THIS, \"String_Node_Str\", NO_ARGS), var(\"String_Node_Str\")))))));\n classNode.addMethod(new MethodNode(\"String_Node_Str\", ACC_PUBLIC, GRIFFON_CLASS_CLASS, Parameter.EMPTY_ARRAY, ClassNode.EMPTY_ARRAY, returns(call(call(call(THIS, \"String_Node_Str\", NO_ARGS), \"String_Node_Str\", NO_ARGS), \"String_Node_Str\", args(classx(classNode))))));\n classNode.addMethod(new MethodNode(\"String_Node_Str\", ACC_PUBLIC, ClassHelper.OBJECT_TYPE, params(param(ClassHelper.CLASS_Type, \"String_Node_Str\"), param(ClassHelper.STRING_TYPE, \"String_Node_Str\")), ClassNode.EMPTY_ARRAY, returns(call(GAH_CLASS, \"String_Node_Str\", vars(APP, \"String_Node_Str\", \"String_Node_Str\")))));\n String loggerCategory = \"String_Node_Str\" + artifactType + \"String_Node_Str\" + classNode.getName();\n FieldNode loggerField = classNode.addField(\"String_Node_Str\", ACC_FINAL | ACC_PRIVATE | ACC_SYNTHETIC, LOGGER_CLASS, call(LOGGER_FACTORY_CLASS, \"String_Node_Str\", args(constx(loggerCategory))));\n classNode.addMethod(new MethodNode(\"String_Node_Str\", ACC_PUBLIC, LOGGER_CLASS, Parameter.EMPTY_ARRAY, ClassNode.EMPTY_ARRAY, returns(field(loggerField))));\n ThreadingAwareASTTransformation.apply(classNode);\n MVCAwareASTTransformation.apply(classNode);\n}\n"
"private void cancel() {\n if (progressing) {\n if (source != null)\n source.revertBlock();\n progressing = false;\n }\n BendingPlayer bPlayer = GeneralMethods.getBendingPlayer(player.getName());\n if (bPlayer != null) {\n bPlayer.addCooldown(\"String_Node_Str\", cooldown);\n }\n instances.remove(id);\n}\n"
"public static MenuItemEntity[] generate(EIndicatorChartType chartTableType, Analysis analysis, ChartDataEntity entity) {\n IDataExplorer explorer = null;\n switch(chartTableType) {\n case FREQUENCE_STATISTICS:\n explorer = new FrequencyStatisticsExplorer();\n break;\n case SQL_PATTERN_MATCHING:\n case PATTERN_MATCHING:\n explorer = new PatternExplorer();\n break;\n case SIMPLE_STATISTICS:\n explorer = new SimpleStatisticsExplorer();\n break;\n case TEXT_STATISTICS:\n explorer = new TextStatisticsExplorer();\n break;\n case SUMMARY_STATISTICS:\n explorer = new SummaryStastictisExplorer();\n break;\n default:\n }\n if (explorer != null) {\n explorer.setAnalysis(analysis);\n explorer.setEnitty(entity);\n Map<String, String> queryMap = explorer.getQueryMap();\n List<MenuItemEntity> retrunList = new ArrayList<MenuItemEntity>();\n for (String key : queryMap.keySet()) {\n MenuItemEntity itemEntity = new MenuItemEntity(key, null, queryMap.get(key));\n retrunList.add(itemEntity);\n }\n return retrunList.toArray(new MenuItemEntity[queryMap.size()]);\n } else {\n return new MenuItemEntity[0];\n }\n return retrunList.toArray(new MenuItemEntity[queryMap.size()]);\n}\n"
"public Fragment getItem(int position) {\n activeTab = position;\n FragmentHistoryPanel res = new FragmentHistoryPanel();\n Bundle args = new Bundle();\n args.putInt(FragmentHistoryPanel.PARAM_TYPE, position);\n res.setArguments(args);\n return res;\n}\n"
"private void upgradeEgressFirewallRules(Connection conn) {\n try (PreparedStatement updateNwpstmt = conn.prepareStatement(\"String_Node_Str\" + \"String_Node_Str\")) {\n updateNwpstmt.executeUpdate();\n s_logger.debug(\"String_Node_Str\" + updateNwpstmt);\n } catch (SQLException e) {\n throw new CloudRuntimeException(\"String_Node_Str\", e);\n }\n try (PreparedStatement vrNwpstmt = conn.prepareStatement(\"String_Node_Str\");\n ResultSet vrNwsRs = vrNwpstmt.executeQuery()) {\n while (vrNwsRs.next()) {\n long netId = vrNwsRs.getLong(1);\n try (PreparedStatement NwAcctDomIdpstmt = conn.prepareStatement(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\")) {\n NwAcctDomIdpstmt.setLong(1, netId);\n try (ResultSet NwAcctDomIdps = NwAcctDomIdpstmt.executeQuery()) {\n s_logger.debug(\"String_Node_Str\" + NwAcctDomIdpstmt);\n if (NwAcctDomIdps.next()) {\n long accountId = NwAcctDomIdps.getLong(1);\n long domainId = NwAcctDomIdps.getLong(2);\n s_logger.debug(\"String_Node_Str\" + netId);\n try (PreparedStatement fwRulespstmt = conn.prepareStatement(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\")) {\n fwRulespstmt.setString(1, UUID.randomUUID().toString());\n fwRulespstmt.setLong(2, accountId);\n fwRulespstmt.setLong(3, domainId);\n fwRulespstmt.setLong(4, netId);\n fwRulespstmt.setString(5, UUID.randomUUID().toString());\n s_logger.debug(\"String_Node_Str\" + fwRulespstmt);\n fwRulespstmt.executeUpdate();\n } catch (SQLException e) {\n throw new CloudRuntimeException(\"String_Node_Str\", e);\n }\n try (PreparedStatement protoAllpstmt = conn.prepareStatement(\"String_Node_Str\")) {\n protoAllpstmt.setLong(1, netId);\n try (ResultSet protoAllRs = protoAllpstmt.executeQuery()) {\n long firewallRuleId;\n if (protoAllRs.next()) {\n firewallRuleId = protoAllRs.getLong(1);\n try (PreparedStatement fwCidrsPstmt = conn.prepareStatement(\"String_Node_Str\")) {\n fwCidrsPstmt.setLong(1, firewallRuleId);\n s_logger.debug(\"String_Node_Str\" + firewallRuleId + \"String_Node_Str\" + fwCidrsPstmt);\n fwCidrsPstmt.executeUpdate();\n } catch (SQLException e) {\n throw new CloudRuntimeException(\"String_Node_Str\", e);\n }\n }\n } catch (SQLException e) {\n throw new CloudRuntimeException(\"String_Node_Str\", e);\n }\n } catch (SQLException e) {\n throw new CloudRuntimeException(\"String_Node_Str\", e);\n }\n }\n } catch (SQLException e) {\n throw new CloudRuntimeException(\"String_Node_Str\", e);\n }\n }\n }\n } catch (SQLException e) {\n throw new CloudRuntimeException(\"String_Node_Str\", e);\n } finally {\n try {\n if (rs != null) {\n rs.close();\n }\n if (pstmt != null) {\n pstmt.close();\n }\n } catch (SQLException e) {\n }\n }\n}\n"
"public void destroy() {\n synchronized (getServletContext()) {\n if (startTimer != null) {\n startTimer.cancel();\n startTimer = null;\n } else if (started && portletContext != null) {\n started = false;\n contextService.unregister(portletContext);\n if (portlet != null) {\n try {\n portlet.destroy();\n } catch (Exception e) {\n }\n portlet = null;\n }\n }\n super.destroy();\n }\n}\n"
"private void saveSPOTHistory() throws InPUTException {\n runCommand(\"String_Node_Str\" + studyId + \"String_Node_Str\" + File.separator + \"String_Node_Str\", false);\n}\n"
"public Object clone() {\n ChainImpl n = new ChainImpl();\n n.setChainID(getChainID());\n n.setSwissprotId(getSwissprotId());\n n.setCompound(this.mol);\n n.setInternalChainID(internalChainID);\n for (int i = 0; i < groups.size(); i++) {\n Group g = groups.get(i);\n n.addGroup((Group) g.clone());\n }\n if (seqResGroups.size() > 0) {\n List<Group> tmpSeqRes = new ArrayList<Group>();\n for (int i = 0; i < seqResGroups.size(); i++) {\n Group g = (Group) seqResGroups.get(i).clone();\n tmpSeqRes.add(g);\n }\n Chain tmp = new ChainImpl();\n tmp.setAtomGroups(tmpSeqRes);\n SeqRes2AtomAligner seqresaligner = new SeqRes2AtomAligner();\n seqresaligner.mapSeqresRecords(n, tmp);\n }\n return n;\n}\n"
"protected Object doInBackground() throws Exception {\n try (OutputStream fos = new BufferedOutputStream(new FileOutputStream(fTempFile))) {\n swf.saveTo(fos);\n }\n SWF instrSWF = null;\n try (FileInputStream fis = new FileInputStream(fTempFile)) {\n instrSWF = new SWF(fis, false, false);\n } catch (InterruptedException ex) {\n Logger.getLogger(MainFrameMenu.class.getName()).log(Level.SEVERE, null, ex);\n }\n if (instrSWF != null) {\n if (instrSWF.isAS3() && Configuration.autoOpenLoadedSWFs.get()) {\n DebuggerTools.injectDebugLoader(instrSWF);\n }\n try (OutputStream fos = new BufferedOutputStream(new FileOutputStream(fTempFile))) {\n instrSWF.saveTo(fos);\n }\n }\n return null;\n}\n"
"private void loadPresets(ConfigurationSection section, ConfigurationLoader loader) {\n for (String key : section.getKeys(false)) {\n try {\n PresetQuery query = presetParser.parse(key);\n Configuration data = loadPreset(section.getConfigurationSection(key), loader);\n if (data != null) {\n data.setPreset(query.hasPresetNames());\n presets.put(query, data);\n } catch (ParsingException ex) {\n if (logger != null)\n logger.printWarning(this, \"String_Node_Str\", ex.getMessage());\n }\n }\n}\n"
"DataLoader getDataLoader() {\n if (_dataLoader == null) {\n final String loadercls = (String) getAttribute(\"String_Node_Str\");\n try {\n _dataLoader = _rod && loadercls != null ? (DataLoader) Classes.forNameByThread(loadercls).newInstance() : new GridDataLoader();\n } catch (Exception e) {\n throw UiException.Aide.wrap(e);\n }\n _dataLoader.init(this);\n }\n return _dataLoader;\n}\n"
"public SqlConvertible createQuery(List<ExecutionInfoToken> tokens) throws VerdictDBException {\n if (tokens == null) {\n return null;\n }\n if (tokens.size() < placeholderRecords.size()) {\n throw new VerdictDBValueException(\"String_Node_Str\");\n }\n for (ExecutionInfoToken token : tokens) {\n String actualSchemaName = (String) token.getValue(\"String_Node_Str\");\n String actualTableName = (String) token.getValue(\"String_Node_Str\");\n Integer channel = (Integer) token.getValue(\"String_Node_Str\");\n if (actualSchemaName == null || actualTableName == null || channel == null) {\n continue;\n }\n for (PlaceHolderRecord record : placeholderRecords) {\n BaseTable placeholderTable = record.getPlaceholderTable();\n int registeredChannel = record.getSubscriptionChannel();\n if (registeredChannel == channel) {\n BaseTable newBaseTable = new BaseTable(actualSchemaName, actualTableName);\n findPlaceHolderAndReplace(placeholderTable, newBaseTable);\n }\n }\n }\n return selectQuery;\n}\n"
"Transaction transaction(Purchase purchase) {\n SkuDetails skuDetails = inventory.getSkuDetails(purchase.getSku());\n Transaction transaction = new Transaction();\n transaction.setIdentifier(purchase.getSku());\n transaction.setStoreName(storeNameFromOpenIAB(purchase.getAppstoreName()));\n transaction.setOrderId(purchase.getOrderId());\n transaction.setPurchaseTime(new Date(purchase.getPurchaseTime()));\n transaction.setPurchaseText((skuDetails != null ? \"String_Node_Str\" + skuDetails.getTitle() + \"String_Node_Str\" + skuDetails.getPrice() + \"String_Node_Str\" + skuDetails.getDescription() : \"String_Node_Str\"));\n transaction.setPurchaseCost(-1);\n transaction.setPurchaseCostCurrency(null);\n if (purchase.getPurchaseState() != 0) {\n transaction.setReversalTime(new Date());\n transaction.setReversalText(purchase.getPurchaseState() == 1 ? \"String_Node_Str\" : \"String_Node_Str\");\n } else {\n transaction.setReversalTime(null);\n transaction.setReversalText(null);\n }\n transaction.setTransactionData(purchase.getOriginalJson());\n transaction.setTransactionDataSignature(purchase.getSignature());\n return transaction;\n}\n"
"public boolean createInstanceAndStartDependencyAtStartup(Group group, List<String> parentInstanceIds) throws TopologyInConsistentException {\n boolean initialStartup = true;\n List<String> instanceIdsToStart = new ArrayList<String>();\n for (String parentInstanceId : parentInstanceIds) {\n Instance parentInstanceContext = getParentInstanceContext(parentInstanceId);\n GroupLevelNetworkPartitionContext groupLevelNetworkPartitionContext = getGroupLevelNetworkPartitionContext(group.getUniqueIdentifier(), this.appId, parentInstanceContext);\n addPartitionContext(parentInstanceContext, groupLevelNetworkPartitionContext);\n String groupInstanceId;\n PartitionContext partitionContext;\n String parentPartitionId = parentInstanceContext.getPartitionId();\n int groupMin = group.getGroupMinInstances();\n List<Instance> existingGroupInstances = group.getInstanceContextsWithParentId(parentInstanceId);\n for (Instance instance : existingGroupInstances) {\n initialStartup = false;\n partitionContext = groupLevelNetworkPartitionContext.getPartitionContextById(parentPartitionId);\n groupInstanceId = createGroupInstanceAndAddToMonitor(group, parentInstanceContext, partitionContext, groupLevelNetworkPartitionContext, null);\n instanceIdsToStart.add(groupInstanceId);\n }\n if (existingGroupInstances.size() <= groupMin) {\n for (int i = 0; i < groupMin - existingGroupInstances.size(); i++) {\n if (parentPartitionId == null) {\n AutoscaleAlgorithm algorithm = this.getAutoscaleAlgorithm(groupLevelNetworkPartitionContext.getPartitionAlgorithm());\n partitionContext = algorithm.getNextScaleUpPartitionContext((PartitionContext[]) groupLevelNetworkPartitionContext.getPartitionCtxts().toArray());\n } else {\n partitionContext = groupLevelNetworkPartitionContext.getPartitionContextById(parentPartitionId);\n }\n groupInstanceId = createGroupInstanceAndAddToMonitor(group, parentInstanceContext, partitionContext, groupLevelNetworkPartitionContext, null);\n instanceIdsToStart.add(groupInstanceId);\n }\n }\n }\n startDependency(group, instanceIdsToStart);\n return initialStartup;\n}\n"
"public void onMessageReceived(MessageReceivedEvent event) {\n final JDA jda = event.getJDA();\n final User author = event.getAuthor();\n if (author.isBot())\n return;\n if (author.getIdLong() == jda.getSelfUser().getIdLong())\n return;\n final Message message = event.getMessage();\n final String prefix;\n if (message.getGuild() == null) {\n prefix = shardUtil.getPrefixStore().getDefaultPrefix();\n } else {\n prefix = shardUtil.getPrefixStore().getPrefix(message.getGuild().getIdLong());\n }\n final String content = message.getRawContent();\n final MessageChannel channel = event.getChannel();\n if (content.startsWith(prefix)) {\n String[] split = content.substring(prefix.length()).split(\"String_Node_Str\");\n List<String> args = new ArrayList<>(split.length - 1);\n for (int i = 1; i < split.length; i++) args.add(split[i]);\n String cmdName = split[0].toLowerCase();\n if (commands.containsKey(cmdName)) {\n Command command = commands.get(cmdName);\n try {\n command.invoke(this, event, args, prefix, cmdName);\n } catch (IllegalAccessException e) {\n logger.error(\"String_Node_Str\", cmdName, e);\n channel.sendMessage(\"String_Node_Str\").queue();\n } catch (InvocationTargetException e) {\n Throwable cause = e.getCause();\n if (cause == null) {\n logger.error(\"String_Node_Str\", cmdName, e);\n channel.sendMessage(\"String_Node_Str\").queue();\n } else if (cause instanceof PassException) {\n } else {\n logger.error(\"String_Node_Str\", cmdName, cause);\n channel.sendMessage(format(\"String_Node_Str\", prefix, cmdName, vagueTrace(cause))).queue();\n if (command.reportErrors)\n reportErrorToOwner(cause, message, command);\n }\n } catch (PermissionError e) {\n channel.sendMessage(format(\"String_Node_Str\", author.getAsMention(), prefix, cmdName, Strings.smartJoin(e.getFriendlyPerms(), \"String_Node_Str\"))).queue();\n } catch (GuildOnlyError e) {\n channel.sendMessage(\"String_Node_Str\").queue();\n } catch (CheckFailure e) {\n channel.sendMessage(format(\"String_Node_Str\", author.getAsMention(), prefix, cmdName)).queue();\n } catch (Exception e) {\n logger.error(\"String_Node_Str\", cmdName, e);\n channel.sendMessage(\"String_Node_Str\").queue();\n }\n if (commandCalls.containsKey(command.name)) {\n commandCalls.get(command.name).incrementAndGet();\n } else {\n commandCalls.put(command.name, new AtomicInteger(1));\n }\n }\n } else {\n String mention = message.getGuild() == null ? jda.getSelfUser().getAsMention() : message.getGuild().getSelfMember().getAsMention();\n if (content.startsWith(mention)) {\n if (content.substring(mention.length()).trim().equalsIgnoreCase(\"String_Node_Str\")) {\n channel.sendMessage(\"String_Node_Str\" + prefix + \"String_Node_Str\").queue();\n } else {\n channel.sendMessage(\"String_Node_Str\" + Cog.getTag(jda.getSelfUser()) + \"String_Node_Str\").queue();\n }\n }\n }\n}\n"
"public void setUp() throws Exception {\n final MetaClientConfig metaClientConfig = new MetaClientConfig();\n metaClientConfig.setDiamondZKDataId(\"String_Node_Str\");\n messageSessionFactory = new MetaMessageSessionFactory(metaClientConfig);\n}\n"
"public FacetsResource getFacets(String query, String dsoType, String dsoScope, String configurationName, List<SearchFilter> searchFilters, Pageable page) throws Exception {\n if (log.isTraceEnabled()) {\n log.trace(\"String_Node_Str\" + StringUtils.trimToEmpty(dsoScope) + \"String_Node_Str\" + StringUtils.trimToEmpty(configurationName) + \"String_Node_Str\" + StringUtils.trimToEmpty(dsoType) + \"String_Node_Str\" + StringUtils.trimToEmpty(dsoType) + \"String_Node_Str\" + Objects.toString(searchFilters));\n }\n SearchResultsRest searchResultsRest = discoveryRestRepository.getAllFacets(query, dsoType, dsoScope, configurationName, searchFilters, page);\n FacetsResource facetsResource = new FacetsResource(searchResultsRest);\n halLinkService.addLinks(facetsResource);\n return facetsResource;\n}\n"
"private String getResultLine(final Measurement measurement) {\n final StringBuilder sb = new StringBuilder();\n boolean missingAttributes = false;\n sb.append(chart.getBaseName());\n sb.append(\"String_Node_Str\");\n switch(chart.getxAxisType()) {\n case TIME:\n sb.append(measurement.getTime());\n break;\n case ITERATION:\n sb.append(measurement.getIteration());\n break;\n case PERCENTAGE:\n sb.append(measurement.getPercentage());\n break;\n }\n boolean isWarmUp = measurement.get(PerfCakeConst.WARM_UP_TAG) != null ? (Boolean) measurement.get(PerfCakeConst.WARM_UP_TAG) : false;\n for (final String attr : chart.getAttributes()) {\n if (chart.getAttributes().indexOf(attr) > 0) {\n boolean warmUpAttr = attr.endsWith(PerfCakeConst.WARM_UP_TAG);\n String pureAttr = warmUpAttr ? attr.substring(0, attr.length() - PerfCakeConst.WARM_UP_TAG.length() - 1) : attr;\n sb.append(\"String_Node_Str\");\n if (!warmUpAttr && !measurement.getAll().containsKey(attr)) {\n missingAttributes = true;\n if (firstResultsLine) {\n log.warn(String.format(\"String_Node_Str\", attr));\n }\n } else {\n final Object data = measurement.get(pureAttr);\n if (isWarmUp ^ warmUpAttr) {\n sb.append(\"String_Node_Str\");\n } else {\n if (data instanceof String) {\n sb.append(\"String_Node_Str\");\n sb.append(((String) data).replaceAll(\"String_Node_Str\", \"String_Node_Str\"));\n sb.append(\"String_Node_Str\");\n } else if (data instanceof Quantity) {\n sb.append(((Quantity) data).getNumber().toString());\n } else {\n sb.append(data == null ? \"String_Node_Str\" : data.toString());\n }\n }\n }\n }\n }\n firstResultsLine = false;\n if (missingAttributes) {\n return \"String_Node_Str\";\n }\n sb.append(\"String_Node_Str\");\n return sb.toString();\n}\n"
"private void test(Compiler compiler, String[] expected, DiagnosticType error, DiagnosticType warning, String description) {\n RecentChange recentChange = new RecentChange();\n compiler.addChangeHandler(recentChange);\n Node root = compiler.parseInputs();\n assertTrue(\"String_Node_Str\" + Joiner.on(\"String_Node_Str\").join(compiler.getErrors()), root != null);\n if (astValidationEnabled) {\n (new AstValidator()).validateRoot(root);\n }\n Node externsRoot = root.getFirstChild();\n Node mainRoot = root.getLastChild();\n Node rootClone = root.cloneTree();\n Node externsRootClone = rootClone.getFirstChild();\n Node mainRootClone = rootClone.getLastChild();\n int numRepetitions = getNumRepetitions();\n ErrorManager[] errorManagers = new ErrorManager[numRepetitions];\n int aggregateWarningCount = 0;\n List<JSError> aggregateWarnings = Lists.newArrayList();\n boolean hasCodeChanged = false;\n assertFalse(\"String_Node_Str\", recentChange.hasCodeChanged());\n for (int i = 0; i < numRepetitions; ++i) {\n if (compiler.getErrorCount() == 0) {\n errorManagers[i] = new BlackHoleErrorManager(compiler);\n if (closurePassEnabled && i == 0) {\n recentChange.reset();\n new ProcessClosurePrimitives(compiler, null, CheckLevel.ERROR).process(null, mainRoot);\n hasCodeChanged = hasCodeChanged || recentChange.hasCodeChanged();\n }\n if (typeCheckEnabled && i == 0) {\n TypeCheck check = createTypeCheck(compiler, typeCheckLevel);\n check.processForTesting(externsRoot, mainRoot);\n }\n if (normalizeEnabled && i == 0) {\n normalizeActualCode(compiler, externsRoot, mainRoot);\n }\n if (markNoSideEffects && i == 0) {\n MarkNoSideEffectCalls mark = new MarkNoSideEffectCalls(compiler);\n mark.process(externsRoot, mainRoot);\n }\n recentChange.reset();\n getProcessor(compiler).process(externsRoot, mainRoot);\n if (astValidationEnabled) {\n (new AstValidator()).validateRoot(root);\n }\n if (checkLineNumbers) {\n (new LineNumberCheck(compiler)).process(externsRoot, mainRoot);\n }\n hasCodeChanged = hasCodeChanged || recentChange.hasCodeChanged();\n aggregateWarningCount += errorManagers[i].getWarningCount();\n aggregateWarnings.addAll(Lists.newArrayList(compiler.getWarnings()));\n if (normalizeEnabled) {\n boolean verifyDeclaredConstants = true;\n new Normalize.VerifyConstants(compiler, verifyDeclaredConstants).process(externsRoot, mainRoot);\n }\n }\n }\n if (error == null) {\n assertEquals(\"String_Node_Str\" + Joiner.on(\"String_Node_Str\").join(compiler.getErrors()), 0, compiler.getErrorCount());\n ErrorManager symbolTableErrorManager = new BlackHoleErrorManager(compiler);\n Node expectedRoot = null;\n if (expected != null) {\n expectedRoot = parseExpectedJs(expected);\n expectedRoot.detachFromParent();\n }\n JSError[] stErrors = symbolTableErrorManager.getErrors();\n if (expectedSymbolTableError != null) {\n assertEquals(\"String_Node_Str\", 1, stErrors.length);\n assertEquals(expectedSymbolTableError, stErrors[0].getType());\n } else {\n assertEquals(\"String_Node_Str\" + Joiner.on(\"String_Node_Str\").join(stErrors), 0, stErrors.length);\n }\n if (warning == null) {\n assertEquals(\"String_Node_Str\" + Joiner.on(\"String_Node_Str\").join(aggregateWarnings), 0, aggregateWarningCount);\n } else {\n assertEquals(\"String_Node_Str\" + numRepetitions + \"String_Node_Str\", numRepetitions, aggregateWarningCount);\n for (int i = 0; i < numRepetitions; ++i) {\n JSError[] warnings = errorManagers[i].getWarnings();\n JSError actual = warnings[0];\n assertEquals(warning, actual.getType());\n if (!allowSourcelessWarnings) {\n assertTrue(\"String_Node_Str\", actual.sourceName != null && !actual.sourceName.isEmpty());\n assertTrue(\"String_Node_Str\", -1 != actual.lineNumber);\n assertTrue(\"String_Node_Str\", -1 != actual.getCharno());\n }\n if (description != null) {\n assertEquals(description, actual.description);\n }\n }\n }\n if (normalizeEnabled) {\n normalizeActualCode(compiler, externsRootClone, mainRootClone);\n }\n boolean codeChange = !mainRootClone.isEquivalentTo(mainRoot);\n boolean externsChange = !externsRootClone.isEquivalentTo(externsRoot);\n if (externsChange && !allowExternsChanges) {\n String explanation = externsRootClone.checkTreeEquals(externsRoot);\n fail(\"String_Node_Str\" + \"String_Node_Str\" + compiler.toSource(externsRootClone) + \"String_Node_Str\" + compiler.toSource(externsRoot) + \"String_Node_Str\" + explanation);\n }\n if (!codeChange && !externsChange) {\n assertFalse(\"String_Node_Str\" + \"String_Node_Str\", hasCodeChanged);\n } else {\n assertTrue(\"String_Node_Str\", hasCodeChanged);\n }\n if (expected != null) {\n if (compareAsTree) {\n String explanation = expectedRoot.checkTreeEquals(mainRoot);\n assertNull(\"String_Node_Str\" + compiler.toSource(expectedRoot) + \"String_Node_Str\" + compiler.toSource(mainRoot) + \"String_Node_Str\" + explanation, explanation);\n } else if (expected != null) {\n assertEquals(Joiner.on(\"String_Node_Str\").join(expected), compiler.toSource(mainRoot));\n }\n }\n Node normalizeCheckRootClone = root.cloneTree();\n Node normalizeCheckExternsRootClone = normalizeCheckRootClone.getFirstChild();\n Node normalizeCheckMainRootClone = normalizeCheckRootClone.getLastChild();\n new PrepareAst(compiler).process(normalizeCheckExternsRootClone, normalizeCheckMainRootClone);\n String explanation = normalizeCheckMainRootClone.checkTreeEquals(mainRoot);\n assertNull(\"String_Node_Str\" + compiler.toSource(normalizeCheckMainRootClone) + \"String_Node_Str\" + compiler.toSource(mainRoot) + \"String_Node_Str\" + explanation, explanation);\n if (normalizeEnabled) {\n new Normalize(compiler, true).process(normalizeCheckExternsRootClone, normalizeCheckMainRootClone);\n explanation = normalizeCheckMainRootClone.checkTreeEquals(mainRoot);\n assertNull(\"String_Node_Str\" + compiler.toSource(normalizeCheckMainRootClone) + \"String_Node_Str\" + compiler.toSource(mainRoot) + \"String_Node_Str\" + explanation, explanation);\n }\n } else {\n String errors = \"String_Node_Str\";\n for (JSError actualError : compiler.getErrors()) {\n errors += actualError.description + \"String_Node_Str\";\n }\n assertEquals(\"String_Node_Str\" + errors, 1, compiler.getErrorCount());\n assertEquals(errors, error, compiler.getErrors()[0].getType());\n if (warning != null) {\n String warnings = \"String_Node_Str\";\n for (JSError actualError : compiler.getWarnings()) {\n warnings += actualError.description + \"String_Node_Str\";\n }\n assertEquals(\"String_Node_Str\" + warnings, 1, compiler.getWarningCount());\n assertEquals(warnings, warning, compiler.getWarnings()[0].getType());\n }\n }\n}\n"
"private Block getSameParent(Block block1, Block block2) {\n Block b1 = block1;\n Block b2 = block2;\n while (b1 != null && b2 != null && !Arrays.equals(b1.getBlockHash(), b2.getBlockHash())) {\n b1 = BlockProvider.getInstance().getBlock(b1.getBlockPrev());\n if (b1.getBlockNo() < b2.getBlockNo()) {\n b2 = BlockProvider.getInstance().getBlock(b2.getBlockPrev());\n }\n }\n return b1;\n}\n"
"public ValueKind getValueKind(int nsKind, GraphTargetItem type, GraphTargetItem val) {\n if (val instanceof BooleanAVM2Item) {\n BooleanAVM2Item bi = (BooleanAVM2Item) val;\n if (bi.value) {\n return new ValueKind(0, ValueKind.CONSTANT_True);\n } else {\n return new ValueKind(0, ValueKind.CONSTANT_False);\n }\n }\n boolean isNs = false;\n if (type instanceof NameAVM2Item) {\n if (((NameAVM2Item) type).getVariableName().equals(\"String_Node_Str\")) {\n isNs = true;\n }\n }\n if ((type instanceof TypeItem) && (((TypeItem) type).fullTypeName.equals(\"String_Node_Str\"))) {\n isNs = true;\n }\n if (val instanceof StringAVM2Item) {\n StringAVM2Item sval = (StringAVM2Item) val;\n if (isNs) {\n return new ValueKind(namespace(nsKind, sval.value), Namespace.KIND_NAMESPACE);\n } else {\n return new ValueKind(str(sval.value), ValueKind.CONSTANT_Utf8);\n }\n }\n if (val instanceof IntegerValueAVM2Item) {\n return new ValueKind(abc.constants.getIntId(((IntegerValueAVM2Item) val).value, true), ValueKind.CONSTANT_Int);\n }\n if (val instanceof FloatValueAVM2Item) {\n return new ValueKind(abc.constants.getDoubleId(((FloatValueAVM2Item) val).value, true), ValueKind.CONSTANT_Double);\n }\n if (val instanceof NullAVM2Item) {\n return new ValueKind(0, ValueKind.CONSTANT_Null);\n }\n if (val instanceof UndefinedAVM2Item) {\n return new ValueKind(0, ValueKind.CONSTANT_Undefined);\n }\n return null;\n}\n"
"protected ProtocolDecl<?> getTargetProtocolDecl(Do<?> parent, NameDisambiguator disamb) throws ScribbleException {\n ModuleContext mc = disamb.getModuleContext();\n JobContext jc = disamb.getJobContext();\n Do<?> doo = (Do<?>) parent;\n ProtocolName<?> pn = doo.proto.toName();\n ProtocolName<?> fullname = mc.getVisibleProtocolDeclFullName(pn);\n return jc.getModule(fullname.getPrefix()).getProtocolDecl(pn.getSimpleName());\n}\n"
"public void metaContactAdded(MetaContactEvent evt) {\n this.refreshAll();\n}\n"
"public boolean apply(ObjectEntity example) {\n try {\n ObjectEntity searchExample = new ObjectEntity().withKey(example.getObjectKey()).withBucket(example.getBucket()).withState(ObjectState.extant);\n Criteria searchCriteria = Entities.createCriteria(ObjectEntity.class);\n searchCriteria.add(Example.create(searchExample)).addOrder(Order.desc(\"String_Node_Str\"));\n searchCriteria = getSearchByBucket(searchCriteria, example.getBucket());\n List<ObjectEntity> results = searchCriteria.list();\n if (results.size() <= 1) {\n return true;\n }\n results.get(0).setIsLatest(true);\n for (ObjectEntity obj : results.subList(1, results.size())) {\n LOG.trace(\"String_Node_Str\" + obj.getObjectUuid() + \"String_Node_Str\");\n obj.setIsLatest(false);\n obj = transitionObjectToState(obj, ObjectState.deleting);\n }\n } catch (NoSuchElementException e) {\n } catch (Exception e) {\n LOG.error(\"String_Node_Str\" + example.getBucket().getBucketName() + \"String_Node_Str\" + example.getObjectKey());\n return false;\n }\n return true;\n}\n"
"public int getSequenceIndexAt(int alignmentIndex) {\n if (sequenceFromAlignment == null) {\n sequenceFromAlignment = new int[length];\n int a = 1, s = numBefore + 1;\n for (int i = 0; i < getStart().getPosition(); i++, a++) {\n sequenceFromAlignment[a - 1] = s;\n }\n for (; a <= length; a++) {\n if (!isGap(a)) {\n s++;\n }\n sequenceFromAlignment[a - 1] = s;\n }\n }\n return sequenceFromAlignment[alignmentIndex - 1];\n}\n"
"public static void printCmdSuccess(String objectType, String name, String result) {\n if (isJansiAvailable() && !isBlank(name)) {\n try {\n name = transferEncoding(name);\n } catch (UnsupportedEncodingException | CliException e) {\n logger.warn(\"String_Node_Str\" + e.getMessage());\n }\n }\n if (!isBlank(name)) {\n System.out.println(objectType + \"String_Node_Str\" + name + \"String_Node_Str\" + result);\n } else {\n System.out.println(objectType + \"String_Node_Str\" + result);\n }\n}\n"
"public static boolean isAbilityInstalled(String name, String author) {\n String ability = getAbility(name);\n return ability != null && AbilityModuleManager.authors.get(name).equalsIgnoreCase(author);\n}\n"
"protected void render() {\n EpisodeViewModel episode = getContent();\n episodeNumberTextView.setText(String.format(\"String_Node_Str\", position + 1));\n episodeTitleTextView.setText(episode.getTitle());\n episodeDateTextView.setText(episode.getPublishDate());\n}\n"
"private Class<?> getClassFromName(String className, ClassLoader classLoader) {\n if (classLoader == null) {\n classLoader = getClass().getClassLoader();\n }\n if (className == null) {\n return null;\n }\n try {\n return classLoader.loadClass(className);\n } catch (ClassNotFoundException ex) {\n LOGGER.log(WARNING, \"String_Node_Str\", ex);\n }\n return null;\n}\n"
"public StoredFieldsReader fieldsReader(Directory directory, SegmentInfo si, FieldInfos fn, IOContext context) throws IOException {\n CompressionMode compressionMode = new CachedCompressionMode(getCompressionMode(si), si, _cache);\n return new CompressingStoredFieldsReader(directory, si, SEGMENT_SUFFIX, fn, context, FORMAT_NAME, compressionMode);\n}\n"
"protected Process createOpcontrolProcess(String[] cmdArray, IProject project) throws OpcontrolException {\n Process p = null;\n try {\n if (!LinuxtoolsPathProperty.getInstance().getLinuxtoolsPath(project).isEmpty()) {\n p = RuntimeProcessFactory.getFactory().sudoExec(cmdArray, project);\n } else if (isInstalled) {\n p = Runtime.getRuntime().exec(cmdArray);\n } else {\n throw new OpcontrolException(OprofileCorePlugin.createErrorStatus(\"String_Node_Str\", null));\n }\n } catch (IOException ioe) {\n throw new OpcontrolException(OprofileCorePlugin.createErrorStatus(\"String_Node_Str\", ioe));\n }\n return p;\n}\n"
"public static void init() {\n String debugTrace = Platform.getDebugOption(pluginID + \"String_Node_Str\");\n String infoTrace = Platform.getDebugOption(pluginID + \"String_Node_Str\");\n String warnTrace = Platform.getDebugOption(pluginID + \"String_Node_Str\");\n if (debugTrace != null) {\n DEBUG = Boolean.valueOf(debugTrace);\n }\n if (infoTrace != null) {\n INFO = (new Boolean(infoTrace)).booleanValue();\n }\n if (warnTrace != null) {\n WARN = (new Boolean(warnTrace)).booleanValue();\n }\n String cfvTrace = Platform.getDebugOption(pluginID + \"String_Node_Str\");\n if (cfvTrace != null) {\n CFV = (new Boolean(cfvTrace)).booleanValue();\n if (CFV) {\n try {\n fCFVfile = new PrintWriter(new FileWriter(\"String_Node_Str\"));\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n String rvTrace = Platform.getDebugOption(pluginID + \"String_Node_Str\");\n if (rvTrace != null) {\n RV = (new Boolean(rvTrace)).booleanValue();\n if (RV) {\n try {\n fRVfile = new PrintWriter(new FileWriter(\"String_Node_Str\"));\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n String svTrace = Platform.getDebugOption(pluginID + \"String_Node_Str\");\n if (svTrace != null) {\n SV = (new Boolean(svTrace)).booleanValue();\n if (SV) {\n try {\n fSVfile = new PrintWriter(new FileWriter(\"String_Node_Str\"));\n } catch (IOException e) {\n e.printStackTrace();\n }\n }\n }\n}\n"
"public boolean accept(String className, URL classUrl, URL classPathUrl) {\n String resourceName = className.replace('.', '/') + \"String_Node_Str\";\n if (visibleResources.contains(resourceName)) {\n return false;\n }\n if (resourceName.startsWith(\"String_Node_Str\")) {\n return true;\n }\n try {\n getClass().getClassLoader().loadClass(\"String_Node_Str\");\n return !SparkRuntimeUtils.SPARK_PROGRAM_CLASS_LOADER_FILTER.acceptResource(resourceName);\n } catch (ClassNotFoundException e) {\n LOG.warn(\"String_Node_Str\", e);\n return true;\n }\n}\n"
"private TreeNode findUpGroupNode(OutputTreeNode node) {\n if (node.eContainer() instanceof OutputTreeNode) {\n OutputTreeNode parent = (OutputTreeNode) node.eContainer();\n if (parent.isGroup()) {\n newLoopUpGroups.add(parent);\n }\n }\n return null;\n}\n"
"public void create() {\n ConnInstanceTO connectorTO = new ConnInstanceTO();\n connectorTO.setVersion(connidSoapVersion);\n connectorTO.setConnectorName(WebServiceConnector.class.getName());\n connectorTO.setBundleName(\"String_Node_Str\");\n connectorTO.setDisplayName(\"String_Node_Str\");\n Set<ConnConfProperty> conf = new HashSet<ConnConfProperty>();\n ConnConfPropSchema endpointSchema = new ConnConfPropSchema();\n endpointSchema.setName(\"String_Node_Str\");\n endpointSchema.setType(String.class.getName());\n endpointSchema.setRequired(true);\n ConnConfProperty endpoint = new ConnConfProperty();\n endpoint.setSchema(endpointSchema);\n endpoint.setValue(\"String_Node_Str\");\n ConnConfPropSchema servicenameSchema = new ConnConfPropSchema();\n servicenameSchema.setName(\"String_Node_Str\");\n servicenameSchema.setType(String.class.getName());\n servicenameSchema.setRequired(true);\n ConnConfProperty servicename = new ConnConfProperty();\n servicename.setSchema(servicenameSchema);\n servicename.setValue(\"String_Node_Str\");\n conf.add(endpoint);\n conf.add(servicename);\n connectorTO.setConfiguration(conf);\n connectorTO.addCapability(ConnectorCapability.ASYNC_CREATE);\n connectorTO.addCapability(ConnectorCapability.SYNC_CREATE);\n connectorTO.addCapability(ConnectorCapability.ASYNC_UPDATE);\n ConnInstanceTO actual = (ConnInstanceTO) restTemplate.postForObject(BASE_URL + \"String_Node_Str\", connectorTO, ConnInstanceTO.class);\n assertNotNull(actual);\n assertEquals(actual.getBundleName(), connectorTO.getBundleName());\n assertEquals(actual.getConnectorName(), connectorTO.getConnectorName());\n assertEquals(actual.getVersion(), connectorTO.getVersion());\n assertEquals(\"String_Node_Str\", actual.getDisplayName());\n assertEquals(connectorTO.getCapabilities(), actual.getCapabilities());\n Throwable t = null;\n connectorTO.setId(actual.getId());\n connectorTO.removeCapability(ConnectorCapability.ASYNC_UPDATE);\n actual = null;\n try {\n actual = restTemplate.postForObject(BASE_URL + \"String_Node_Str\", connectorTO, ConnInstanceTO.class);\n } catch (HttpStatusCodeException e) {\n LOG.error(\"String_Node_Str\", e);\n t = e;\n }\n assertNull(t);\n assertNotNull(actual);\n assertEquals(connectorTO.getCapabilities(), actual.getCapabilities());\n try {\n restTemplate.delete(BASE_URL + \"String_Node_Str\", actual.getId().toString());\n } catch (HttpStatusCodeException e) {\n LOG.error(\"String_Node_Str\", e);\n t = e;\n }\n assertNull(t);\n try {\n restTemplate.getForObject(BASE_URL + \"String_Node_Str\", ConnInstanceTO.class, actual.getId().toString());\n } catch (HttpStatusCodeException e) {\n assertEquals(e.getStatusCode(), HttpStatus.NOT_FOUND);\n }\n}\n"
"public static double recall(int tp, int fp, int fn) {\n if (tp + fp + fn == 0) {\n return 1;\n }\n if (tp + fn == 0) {\n return 1;\n }\n return tp * 1.0 / (tp + fn);\n}\n"
"public Object getValueAt(int arg0, int arg1) {\n switch(arg1) {\n case 0:\n return matches[arg0].getName();\n case 1:\n return matches[arg0].getGameType();\n case 2:\n return matches[arg0].getDeckType();\n case 3:\n return matches[arg0].getPlayers();\n case 4:\n return matches[arg0].getResult();\n case 5:\n return timeFormatter.format(matches[arg0].getStartTime());\n case 6:\n if (matches[arg0].getEndTime() != null) {\n return timeFormatter.format(matches[arg0].getEndTime());\n } else {\n return \"String_Node_Str\";\n }\n case 7:\n if (matches[arg0].isReplayAvailable()) {\n return \"String_Node_Str\";\n } else {\n return \"String_Node_Str\";\n }\n case 8:\n return matches[arg0].getGames();\n }\n return \"String_Node_Str\";\n}\n"
"public void indexDocument(Repository repository, SVNDirEntry dirEntry, String path, long revision) {\n LOGGER.debug(\"String_Node_Str\");\n try {\n if (isBinary()) {\n LOGGER.debug(\"String_Node_Str\");\n addTokenizedField(FieldNames.CONTENTS, \"String_Node_Str\");\n } else {\n LOGGER.debug(\"String_Node_Str\");\n if (dirEntry.getSize() > 10 * 1024 * 1024) {\n LOGGER.warn(\"String_Node_Str\");\n } else {\n ByteArrayOutputStream baos = new ByteArrayOutputStream();\n repository.getRepository().getFile(path, revision, null, baos);\n addTokenizedField(FieldNames.CONTENTS, baos.toString());\n }\n }\n } catch (Exception e) {\n LOGGER.error(\"String_Node_Str\", e);\n }\n}\n"
"private void setBackgroundColor() {\n if (this.getSourceViewer() != null && this.getSourceViewer().getTextWidget() != null) {\n CFMLPreferenceManager manager = new CFMLPreferenceManager();\n this.getSourceViewer().getTextWidget().setBackground(new org.eclipse.swt.graphics.Color(this.getSourceViewer().getTextWidget().getDisplay(), manager.getColor(EditorPreferenceConstants.P_COLOR_BACKGROUND)));\n }\n}\n"
"public CcLinkingOutputs createCcLinkActions(CcCompilationOutputs ccOutputs, Iterable<Artifact> nonCodeLinkerInputs) throws RuleErrorException, InterruptedException {\n Preconditions.checkState(linkType.staticness() == Staticness.STATIC, \"String_Node_Str\");\n CcLinkingOutputs.Builder result = new CcLinkingOutputs.Builder();\n if (cppConfiguration.isLipoContextCollector()) {\n return result.build();\n }\n AnalysisEnvironment env = ruleContext.getAnalysisEnvironment();\n boolean usePicForBinaries = CppHelper.usePic(ruleContext, true);\n boolean usePicForSharedLibs = CppHelper.usePic(ruleContext, false);\n Artifact linkedArtifact = getLinkedArtifact(linkType);\n PathFragment labelName = new PathFragment(ruleContext.getLabel().getName());\n String libraryIdentifier = ruleContext.getPackageDirectory().getRelative(labelName.replaceName(\"String_Node_Str\" + labelName.getBaseName())).getPathString();\n CppLinkAction maybePicAction = newLinkActionBuilder(linkedArtifact).addObjectFiles(ccOutputs.getObjectFiles(usePicForBinaries)).addNonCodeInputs(nonCodeLinkerInputs).addLTOBitcodeFiles(ccOutputs.getLtoBitcodeFiles()).setLinkType(linkType).setLinkStaticness(LinkStaticness.FULLY_STATIC).addActionInputs(linkActionInputs).setLibraryIdentifier(libraryIdentifier).addVariablesExtensions(variablesExtensions).setFeatureConfiguration(featureConfiguration).build();\n env.registerAction(maybePicAction);\n if (linkType != LinkTargetType.EXECUTABLE) {\n result.addStaticLibrary(maybePicAction.getOutputLibrary());\n }\n if (!usePicForBinaries && usePicForSharedLibs) {\n LinkTargetType picLinkType = (linkType == LinkTargetType.ALWAYS_LINK_STATIC_LIBRARY) ? LinkTargetType.ALWAYS_LINK_PIC_STATIC_LIBRARY : LinkTargetType.PIC_STATIC_LIBRARY;\n Artifact picArtifact = getLinkedArtifact(picLinkType);\n CppLinkAction picAction = newLinkActionBuilder(picArtifact).addObjectFiles(ccOutputs.getObjectFiles(true)).addNonCodeInputs(ccOutputs.getHeaderTokenFiles()).addLTOBitcodeFiles(ccOutputs.getLtoBitcodeFiles()).setLinkType(picLinkType).setLinkStaticness(LinkStaticness.FULLY_STATIC).addActionInputs(linkActionInputs).setLibraryIdentifier(libraryIdentifier).addVariablesExtensions(variablesExtensions).setFeatureConfiguration(featureConfiguration).build();\n env.registerAction(picAction);\n if (linkType != LinkTargetType.EXECUTABLE) {\n result.addPicStaticLibrary(picAction.getOutputLibrary());\n }\n }\n if (!createDynamicLibrary) {\n return result.build();\n }\n Artifact soImpl;\n String mainLibraryIdentifier;\n if (soImplArtifact == null) {\n soImpl = getLinkedArtifact(LinkTargetType.DYNAMIC_LIBRARY);\n mainLibraryIdentifier = libraryIdentifier;\n } else {\n soImpl = soImplArtifact;\n mainLibraryIdentifier = FileSystemUtils.removeExtension(soImpl.getRootRelativePath().getPathString());\n }\n List<String> sonameLinkopts = ImmutableList.of();\n Artifact soInterface = null;\n if (cppConfiguration.useInterfaceSharedObjects() && allowInterfaceSharedObjects) {\n soInterface = CppHelper.getLinuxLinkedArtifact(ruleContext, LinkTargetType.INTERFACE_DYNAMIC_LIBRARY);\n sonameLinkopts = ImmutableList.of(\"String_Node_Str\" + SolibSymlinkAction.getDynamicLibrarySoname(soImpl.getRootRelativePath(), false));\n }\n CppLinkActionBuilder linkActionBuilder = newLinkActionBuilder(soImpl).setInterfaceOutput(soInterface).addObjectFiles(ccOutputs.getObjectFiles(usePicForSharedLibs)).addNonCodeInputs(ccOutputs.getHeaderTokenFiles()).addLTOBitcodeFiles(ccOutputs.getLtoBitcodeFiles()).setLinkType(LinkTargetType.DYNAMIC_LIBRARY).setLinkStaticness(LinkStaticness.DYNAMIC).addActionInputs(linkActionInputs).setLibraryIdentifier(mainLibraryIdentifier).addLinkopts(linkopts).addLinkopts(sonameLinkopts).setRuntimeInputs(ArtifactCategory.DYNAMIC_LIBRARY, CppHelper.getToolchain(ruleContext).getDynamicRuntimeLinkMiddleman(), CppHelper.getToolchain(ruleContext).getDynamicRuntimeLinkInputs()).setFeatureConfiguration(featureConfiguration).addVariablesExtensions(variablesExtensions);\n if (!ccOutputs.getLtoBitcodeFiles().isEmpty() && featureConfiguration.isEnabled(CppRuleClasses.THIN_LTO)) {\n linkActionBuilder.setLTOIndexing(true);\n CppLinkAction indexAction = linkActionBuilder.build();\n env.registerAction(indexAction);\n for (LTOBackendArtifacts ltoArtifacts : indexAction.getAllLTOBackendArtifacts()) {\n ltoArtifacts.scheduleLTOBackendAction(ruleContext, usePicForSharedLibs);\n }\n linkActionBuilder.setLTOIndexing(false);\n }\n CppLinkAction action = linkActionBuilder.build();\n env.registerAction(action);\n if (linkType == LinkTargetType.EXECUTABLE) {\n return result.build();\n }\n LibraryToLink dynamicLibrary = action.getOutputLibrary();\n LibraryToLink interfaceLibrary = action.getInterfaceOutputLibrary();\n if (interfaceLibrary == null) {\n interfaceLibrary = dynamicLibrary;\n }\n if (neverLink) {\n result.addDynamicLibrary(interfaceLibrary);\n result.addExecutionDynamicLibrary(dynamicLibrary);\n } else {\n Artifact libraryLink = SolibSymlinkAction.getDynamicLibrarySymlink(ruleContext, interfaceLibrary.getArtifact(), false, false, ruleContext.getConfiguration());\n result.addDynamicLibrary(LinkerInputs.solibLibraryToLink(libraryLink, interfaceLibrary.getArtifact(), libraryIdentifier));\n Artifact implLibraryLink = SolibSymlinkAction.getDynamicLibrarySymlink(ruleContext, dynamicLibrary.getArtifact(), false, false, ruleContext.getConfiguration());\n result.addExecutionDynamicLibrary(LinkerInputs.solibLibraryToLink(implLibraryLink, dynamicLibrary.getArtifact(), libraryIdentifier));\n }\n return result.build();\n}\n"
"public String resolveNamespacePrefix(String prefix) {\n if (null == prefix || prefix.length() == 0) {\n return defaultNamespaceURI;\n }\n String uri = prefixesToNamespaces.get(prefix);\n if (null != uri) {\n return uri;\n } else if (XMLConstants.XML_NAMESPACE_PREFIX.equals(prefix)) {\n return XMLConstants.XML_NAMESPACE_URL;\n } else if (XMLConstants.XMLNS.equals(prefix)) {\n return XMLConstants.XMLNS_URL;\n }\n return null;\n}\n"
"void addDataSet(DataSet dataSet) {\n dataSets.put(dataSet.getReferenceStr().replace('$', '.'), dataSet);\n for (ModelNode ld : children.values()) {\n for (ModelNode ln : ld.getChildren()) {\n for (Urcb urcb : ((LogicalNode) ln).getUrcbs()) {\n urcb.dataSet = getDataSet(urcb.getDatSet().getStringValue().replace('$', '.'));\n }\n for (Brcb brcb : ((LogicalNode) ln).getBrcbs()) {\n brcb.dataSet = getDataSet(brcb.getDatSet().getStringValue().replace('$', '.'));\n }\n }\n }\n}\n"
"public void run() throws IOException {\n FileUtils.mkdir(outputDir.getAbsolutePath());\n final List<File> tests = FileUtils.getFiles(baseDir, includes, excludes);\n if (tests.isEmpty()) {\n logger.warn(\"String_Node_Str\");\n return;\n }\n logger.info(\"String_Node_Str\", threadCount);\n logger.info(\"String_Node_Str\", outputStrategy);\n final ExecutorService executorService = Executors.newFixedThreadPool(threadCount);\n final CompletionService<RunStats> completionService = new ExecutorCompletionService<RunStats>(executorService);\n for (final File test : tests) {\n completionService.submit(new Callable<RunStats>() {\n public RunStats call() {\n logger.info(\"String_Node_Str\", test.getAbsoluteFile().toURI().normalize().getPath());\n try {\n final RunStats runStats = runTest(test);\n if (outputStrategy.contains(OutputStrategy.PER_TEST)) {\n writeRunStats(runStats);\n }\n return runStats;\n } catch (final IOException e) {\n throw new RuntimeException(e);\n }\n }\n });\n }\n final List<RunStats> allRunStats = Lists.newLinkedList();\n try {\n for (int i = 0; i < tests.size(); i++) {\n final Future<RunStats> future = completionService.take();\n final RunStats runStats = future.get();\n allRunStats.add(runStats);\n } catch (final InterruptedException e) {\n throw new RuntimeException(e);\n } catch (final ExecutionException e) {\n throw new RuntimeException(e);\n }\n }\n logger.info(\"String_Node_Str\");\n executorService.shutdown();\n if (outputStrategy.contains(OutputStrategy.TOTAL)) {\n final RunStats totalStats = new RunStats(new File(outputDir, reportName), \"String_Node_Str\");\n for (final RunStats runStats : allRunStats) {\n for (final FileStats fileStats : runStats) {\n totalStats.add(fileStats);\n }\n }\n writeRunStats(totalStats);\n }\n}\n"
"void validateSaleOrder(Long soId) {\n try {\n SaleOrder saleOrder = SaleOrder.find(soId);\n for (SaleOrderLine line : saleOrder.getSaleOrderLineList()) line.setTaxLine(saleOrderLineService.getTaxLine(saleOrder, line));\n saleOrderService.computeSaleOrder(saleOrder);\n if (saleOrder.getStatusSelect() == 3) {\n taskSaleOrderService.createTasks(saleOrder);\n saleOrderServiceStockImpl.createStocksMovesFromSaleOrder(saleOrder);\n saleOrderPurchaseService.createPurchaseOrders(saleOrder);\n saleOrder.setClientPartner(saleOrderService.validateCustomer(saleOrder));\n if (saleOrder.getInvoicingTypeSelect() == 1 || saleOrder.getInvoicingTypeSelect() == 5) {\n Invoice invoice = saleOrderInvoiceService.generatePerOrderInvoice(saleOrder);\n invoice.setInvoiceDate(saleOrder.getValidationDate());\n invoiceService.compute(invoice);\n invoiceService.validate(invoice);\n invoiceService.ventilate(invoice);\n }\n StockMove stockMove = StockMove.all().filter(\"String_Node_Str\", saleOrder).fetchOne();\n if (stockMove != null && stockMove.getStockMoveLineList() != null && !stockMove.getStockMoveLineList().isEmpty()) {\n stockMoveService.copyQtyToRealQty(stockMove);\n stockMoveService.validate(stockMove);\n stockMove.setRealDate(saleOrder.getValidationDate());\n if (saleOrder.getInvoicingTypeSelect() == 4) {\n Invoice invoice = stockMoveInvoiceService.createInvoiceFromSaleOrder(stockMove, saleOrder);\n invoice.setInvoiceDate(saleOrder.getValidationDate());\n invoiceService.compute(invoice);\n invoiceService.validate(invoice);\n invoiceService.ventilate(invoice);\n }\n }\n }\n saleOrder.save();\n } catch (Exception e) {\n e.printStackTrace();\n }\n}\n"
"public ExecutionResult executeAssembler(Assembler assembler, String jobName, List<Integer> jobIds) throws ProcessExecutionException, InterruptedException, IOException, ConanParameterException {\n assembler.setup();\n Args args = this.getArgs();\n return this.conanExecutorService.executeProcess(assembler, assembler.getAssemblerArgs().getOutputDir(), jobName, args.getThreads(), args.getMemory(), args.isMassParallel() || args.isRunParallel(), jobIds, assembler.usesOpenMpi());\n}\n"
"protected void selectAndExpand(Object value) {\n if (value != null && !treeTable.containsId(value)) {\n String projectVersionId = null;\n if (value instanceof AbstractName) {\n AbstractName named = (AbstractName) value;\n projectVersionId = named.getProjectVersionId();\n } else if (value instanceof ProjectVersion) {\n projectVersionId = ((ProjectVersion) value).getId();\n }\n String projectId = null;\n if (isNotBlank(projectVersionId)) {\n ProjectVersion projectVersion = configurationService.findProjectVersion(projectVersionId);\n projectId = projectVersion.getProjectId();\n } else if (value instanceof Project) {\n projectId = ((Project) value).getId();\n }\n if (isNotBlank(projectId)) {\n Collection<?> items = treeTable.getItemIds();\n for (Object object : items) {\n if (object instanceof Project && ((Project) object).getId().equals(projectId) && !((Project) object).isDeleted()) {\n addProjectVersions(((Project) object));\n }\n }\n }\n }\n treeTable.setValue(value);\n if (value != null) {\n treeTable.setCollapsed(value, false);\n Object parent = treeTable.getParent(value);\n while (parent != null) {\n treeTable.setCollapsed(parent, false);\n parent = treeTable.getParent(parent);\n }\n }\n treeTable.focus();\n}\n"
"public void testReceivedMessageFromTopicWithReplyToWithoutTypeAnnotationResultsInUseOfConsumerDestinationType() throws Exception {\n try (TestAmqpPeer testPeer = new TestAmqpPeer(testFixture.getAvailablePort())) {\n Connection connection = testFixture.establishConnecton(testPeer);\n connection.start();\n testPeer.expectBegin(true);\n Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);\n Topic topic = session.createTopic(\"String_Node_Str\");\n String myReplyTopicAddress = \"String_Node_Str\";\n PropertiesDescribedType props = new PropertiesDescribedType();\n props.setReplyTo(myReplyTopicAddress);\n props.setMessageId(\"String_Node_Str\");\n DescribedType amqpValueNullContent = new AmqpValueDescribedType(null);\n testPeer.expectReceiverAttach();\n testPeer.expectLinkFlowRespondWithTransfer(null, null, props, null, amqpValueNullContent);\n testPeer.expectDispositionThatIsAcceptedAndSettled();\n MessageConsumer messageConsumer = session.createConsumer(topic);\n Message receivedMessage = messageConsumer.receive(1000);\n testPeer.waitForAllHandlersToComplete(3000);\n assertNotNull(receivedMessage);\n Destination dest = receivedMessage.getJMSReplyTo();\n assertNotNull(\"String_Node_Str\", dest);\n assertTrue(\"String_Node_Str\" + dest.getClass(), dest instanceof Topic);\n assertEquals(myReplyTopicAddress, ((Topic) dest).getTopicName());\n }\n}\n"
"private boolean isSetterMethod(JMethod method) {\n return method.isPublic() && !method.isStatic() && method.getName().startsWith(\"String_Node_Str\") && method.getName().length() > 3 && method.getReturnType() == JPrimitiveType.VOID;\n}\n"
"public void resolveBindings(IScope scope, Bindings bindings) {\n if (onTypeSymbolic != null) {\n onType = onTypeSymbolic.resolveExactType(scope, bindings);\n if (ResolvedType.isMissing(onType))\n return;\n }\n ResolvedType searchType;\n if (onType != null) {\n searchType = scope.getWorld().resolve(onType);\n } else {\n searchType = scope.getEnclosingType();\n }\n if (searchType.isTypeVariableReference()) {\n searchType = ((TypeVariableReference) searchType).getTypeVariable().getUpperBound().resolve(scope.getWorld());\n }\n arguments.resolveBindings(scope, bindings, true, true);\n ResolvedPointcutDefinition pointcutDef = searchType.findPointcut(name);\n if (pointcutDef == null && onType == null) {\n while (true) {\n UnresolvedType declaringType = searchType.getDeclaringType();\n if (declaringType == null)\n break;\n searchType = declaringType.resolve(scope.getWorld());\n pointcutDef = searchType.findPointcut(name);\n if (pointcutDef != null) {\n onType = searchType;\n break;\n }\n }\n }\n if (pointcutDef == null) {\n scope.message(IMessage.ERROR, this, \"String_Node_Str\" + name);\n return;\n }\n if (!pointcutDef.isVisible(scope.getEnclosingType())) {\n scope.message(IMessage.ERROR, this, \"String_Node_Str\" + pointcutDef + \"String_Node_Str\");\n return;\n }\n if (Modifier.isAbstract(pointcutDef.getModifiers())) {\n if (onType != null && !onType.isTypeVariableReference()) {\n scope.message(IMessage.ERROR, this, \"String_Node_Str\");\n return;\n } else if (!searchType.isAbstract()) {\n scope.message(IMessage.ERROR, this, \"String_Node_Str\");\n return;\n }\n }\n ResolvedType[] parameterTypes = scope.getWorld().resolve(pointcutDef.getParameterTypes());\n if (parameterTypes.length != arguments.size()) {\n scope.message(IMessage.ERROR, this, \"String_Node_Str\" + parameterTypes.length + \"String_Node_Str\" + arguments.size());\n return;\n }\n if (onType != null) {\n if (onType.isParameterizedType()) {\n typeVariableMap = new HashMap();\n ResolvedType underlyingGenericType = ((ResolvedType) onType).getGenericType();\n TypeVariable[] tVars = underlyingGenericType.getTypeVariables();\n ResolvedType[] typeParams = ((ResolvedType) onType).getResolvedTypeParameters();\n for (int i = 0; i < tVars.length; i++) {\n typeVariableMap.put(tVars[i].getName(), typeParams[i]);\n }\n } else if (onType.isGenericType()) {\n scope.message(MessageUtil.error(WeaverMessages.format(WeaverMessages.CANT_REFERENCE_POINTCUT_IN_RAW_TYPE), getSourceLocation()));\n }\n }\n for (int i = 0, len = arguments.size(); i < len; i++) {\n TypePattern p = arguments.get(i);\n if (typeVariableMap != null) {\n p = p.parameterizeWith(typeVariableMap, scope.getWorld());\n }\n if (p == TypePattern.NO) {\n scope.message(IMessage.ERROR, this, \"String_Node_Str\");\n return;\n }\n boolean reportProblem = false;\n if (parameterTypes[i].isTypeVariableReference() && p.getExactType().isTypeVariableReference()) {\n UnresolvedType One = ((TypeVariableReference) parameterTypes[i]).getTypeVariable().getFirstBound();\n UnresolvedType Two = ((TypeVariableReference) p.getExactType()).getTypeVariable().getFirstBound();\n reportProblem = !One.resolve(scope.getWorld()).isAssignableFrom(Two.resolve(scope.getWorld()));\n } else {\n reportProblem = !p.matchesSubtypes(parameterTypes[i]) && !p.getExactType().equals(UnresolvedType.OBJECT);\n }\n if (reportProblem) {\n scope.message(IMessage.ERROR, this, \"String_Node_Str\" + parameterTypes[i].getName() + \"String_Node_Str\" + p + \"String_Node_Str\");\n return;\n }\n }\n}\n"
"public void configure(final Env env, final Config conf, final Binder binder) {\n ConnectionString cstr = Try.apply(() -> ConnectionString.parse(db)).orElseGet(() -> ConnectionString.parse(conf.getString(db)));\n ServiceKey serviceKey = env.serviceKey();\n Throwing.Function3<Class, String, Object, Void> bind = (type, name, value) -> {\n serviceKey.generate(type, name, k -> binder.bind(k).toInstance(value));\n return null;\n };\n Cluster.Builder builder = this.builder.get().addContactPoints(cstr.contactPoints()).withPort(cstr.port());\n if (ccbuilder != null) {\n ccbuilder.accept(builder, conf);\n }\n log.debug(\"String_Node_Str\", cstr);\n Cluster cluster = builder.build();\n if (cc != null) {\n cc.accept(cluster, conf);\n }\n Configuration configuration = cluster.getConfiguration();\n CodecRegistry codecRegistry = configuration.getCodecRegistry();\n codecRegistry.register(InstantCodec.instance, LocalDateCodec.instance, LocalTimeCodec.instance);\n hierarchy(cluster.getClass(), type -> bind.apply(type, cstr.keyspace(), cluster));\n Session session = cluster.connect(cstr.keyspace());\n hierarchy(session.getClass(), type -> bind.apply(type, cstr.keyspace(), session));\n MappingManager manager = new MappingManager(session);\n bind.apply(MappingManager.class, cstr.keyspace(), manager);\n bind.apply(Datastore.class, cstr.keyspace(), new Datastore(manager));\n accesors.forEach(c -> {\n Object accessor = manager.createAccessor(c);\n binder.bind(c).toInstance(accessor);\n });\n env.router().map(new CassandraMapper());\n env.onStop(() -> {\n log.debug(\"String_Node_Str\", cstr);\n Try.run(session::close).onFailure(x -> log.error(\"String_Node_Str\", x));\n cluster.close();\n log.info(\"String_Node_Str\", cstr);\n });\n}\n"
"private void addTileSites(Collection<VectorXYZ> result, int tileLon, int tileLat, double minLon, double minLat, double maxLon, double maxLat) {\n SRTMTile tile = getTile(tileLon, tileLat);\n if (tile == null)\n return;\n int minX = max(0, (int) ceil(SRTMTile.PIXELS * (minLon - tileLon)));\n int maxX = min(SRTMTile.PIXELS - 1, (int) floor(SRTMTile.PIXELS * (maxLon - tileLon)));\n int minY = max(0, (int) ceil(SRTMTile.PIXELS * (minLat - tileLat)));\n int maxY = min(SRTMTile.PIXELS - 1, (int) floor(SRTMTile.PIXELS * (maxLat - tileLat)));\n for (int x = minX; x < maxX; x++) {\n for (int y = minY; y < maxY; y++) {\n short value = tile.getData(x, y);\n double lat = tileLat + 1.0 / SRTMTile.PIXELS * (y + 0.5);\n double lon = tileLon + 1.0 / SRTMTile.PIXELS * (x + 0.5);\n VectorXZ pos = projection.calcPos(lat, lon);\n if (value != SRTMTile.BLANK_VALUE && !Double.isNaN(pos.x) && !Double.isNaN(pos.z)) {\n result.add(pos.xyz(value));\n }\n }\n }\n}\n"
"public boolean exists(final DataFile src, final boolean followLink) {\n try {\n return new S3URL(src).getS3Object() != null;\n } catch (AmazonS3Exception | IOException e) {\n return false;\n }\n}\n"
"private FileIdKey getCacheFileName(CacheDirectory directory, String fileName) throws IOException {\n if (directory.fileExists(fileName)) {\n long fileModified = directory.getFileModified(fileName);\n return new FileIdKey(directory.getDirectoryName(), fileName, fileModified);\n }\n return new FileIdKey(directory.getDirectoryName(), fileName, -1L);\n}\n"
"private int getPixelPerWaterfallLine() {\n return 1;\n}\n"
"public boolean prefire() throws IllegalActionException {\n if (_debugging) {\n _debug(\"String_Node_Str\", getName(), \"String_Node_Str\");\n }\n if (!_isTopLevel()) {\n CompositeActor container = (CompositeActor) getContainer();\n Director executiveDirector = container.getExecutiveDirector();\n _outsideTime = executiveDirector.getModelTime();\n Time localTime = getModelTime();\n Time outsideNextIterationTime = executiveDirector.getModelNextIterationTime();\n if (_debugging) {\n _debug(\"String_Node_Str\" + _outsideTime, \"String_Node_Str\" + outsideNextIterationTime, \"String_Node_Str\" + localTime);\n }\n if (outsideNextIterationTime.compareTo(_outsideTime) < 0) {\n throw new IllegalActionException(this, \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + _outsideTime + \"String_Node_Str\" + outsideNextIterationTime);\n }\n if (_outsideTime.compareTo(localTime) > 0) {\n throw new IllegalActionException(this, executiveDirector, \"String_Node_Str\" + \"String_Node_Str\");\n } else if (_outsideTime.compareTo(localTime) < 0) {\n if (_debugging) {\n _debug(getName() + \"String_Node_Str\" + localTime + \"String_Node_Str\" + _knownGoodTime + \"String_Node_Str\" + _outsideTime);\n }\n _rollback();\n _propagateResolvedStates();\n _catchUp();\n if (_debugging) {\n _debug(\"String_Node_Str\" + localTime);\n }\n }\n if (_debugging) {\n _debug(\"String_Node_Str\" + \"String_Node_Str\");\n }\n _setIterationBeginTime(getModelTime());\n double aheadLength = outsideNextIterationTime.subtract(_outsideTime).getDoubleValue();\n if (_debugging) {\n _debug(getName(), \"String_Node_Str\" + localTime, \"String_Node_Str\" + _outsideTime, \"String_Node_Str\" + outsideNextIterationTime + \"String_Node_Str\" + aheadLength);\n }\n if (aheadLength < getTimeResolution()) {\n if (_debugging) {\n _debug(\"String_Node_Str\");\n }\n aheadLength = 0;\n } else if (aheadLength > _runAheadLength) {\n aheadLength = _runAheadLength;\n }\n double currentSuggestedNextStepSize = getSuggestedNextStepSize();\n if (aheadLength < currentSuggestedNextStepSize || currentSuggestedNextStepSize == 0) {\n setSuggestedNextStepSize(aheadLength);\n }\n if (_debugging) {\n _debug(getName(), \"String_Node_Str\" + getSuggestedNextStepSize());\n }\n return true;\n } else {\n return super.prefire();\n }\n}\n"
"public static void main(String[] args) throws IllegalActionException, IOException {\n try {\n _omcProxy.initServer();\n } catch (ConnectException ex) {\n throw new IllegalActionException(\"String_Node_Str\");\n }\n try {\n _omcProxy.loadFile(\"String_Node_Str\", \"String_Node_Str\");\n } catch (ConnectException e) {\n throw new IllegalActionException(\"String_Node_Str\");\n }\n try {\n _omcProxy.simulateModel(\"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", 500, \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\");\n } catch (Throwable throwable) {\n throw new IllegalActionException(null, throwable, \"String_Node_Str\");\n }\n _utilSocket = UtilSocket.getInstance();\n if (!_utilSocket.establishclientsocket()) {\n try {\n _omcProxy.quitServer();\n System.out.println(\"String_Node_Str\");\n } catch (ConnectException ex) {\n throw new IllegalActionException(\"String_Node_Str\");\n }\n } else {\n _utilSocket.exchangewithsocket();\n _utilSocket.closesocket();\n try {\n _omcProxy.quitServer();\n System.out.println(\"String_Node_Str\");\n } catch (ConnectException ex) {\n throw new IllegalActionException(\"String_Node_Str\");\n }\n }\n}\n"
"private void handleSinkStateChange(BluetoothDevice device, int prevState, int state) {\n if (state == BluetoothA2dp.STATE_DISCONNECTED) {\n mSuspending = false;\n mResuming = false;\n }\n if (state != prevState) {\n if (state == BluetoothA2dp.STATE_DISCONNECTED || state == BluetoothA2dp.STATE_DISCONNECTING) {\n if (prevState == BluetoothA2dp.STATE_CONNECTED || prevState == BluetoothA2dp.STATE_PLAYING) {\n Intent intent = new Intent(AudioManager.ACTION_AUDIO_BECOMING_NOISY);\n mContext.sendBroadcast(intent);\n }\n mSinkCount--;\n } else if (state == BluetoothA2dp.STATE_CONNECTED) {\n mSinkCount++;\n }\n mAudioDevices.put(device, state);\n checkSinkSuspendState(state);\n mTargetA2dpState = -1;\n if (state == BluetoothA2dp.STATE_CONNECTING) {\n mAudioManager.setParameters(\"String_Node_Str\");\n }\n Intent intent = new Intent(BluetoothA2dp.ACTION_SINK_STATE_CHANGED);\n intent.putExtra(BluetoothDevice.EXTRA_DEVICE, device);\n intent.putExtra(BluetoothA2dp.EXTRA_PREVIOUS_SINK_STATE, prevState);\n intent.putExtra(BluetoothA2dp.EXTRA_SINK_STATE, state);\n mContext.sendBroadcast(intent, BLUETOOTH_PERM);\n if (DBG)\n log(\"String_Node_Str\" + device + \"String_Node_Str\" + prevState + \"String_Node_Str\" + state);\n }\n}\n"
"public void setLocalVideoView(QBGLVideoView videoView) {\n this.localVideoView = videoView;\n onLocalVideoViewCreated();\n}\n"
"public void onRow(Row4Aggregation row) throws IOException, DataException {\n Row4Aggregation newRow = new Row4Aggregation();\n if (row.getLevelMembers().length != newMemberSize && orignalLevelCount == newMemberSize) {\n Member[] nMembers = new Member[newMemberSize];\n System.arraycopy(row.getLevelMembers(), 0, nMembers, 0, firstTimeLevel);\n Member[] timeMember = cubeDimensionReader.getLevelMembers(timeDimensionIndex, endLevelIndex, row.getDimPos()[timeDimensionIndex]);\n System.arraycopy(timeMember, 0, nMembers, firstTimeLevel, timeMember.length);\n if ((orignalLevelCount - (lowestTimeLevel + 1)) > 0) {\n System.arraycopy(row.getLevelMembers(), lowestTimeLevel + 1, nMembers, firstTimeLevel + timeMember.length, orignalLevelCount - (lowestTimeLevel + 1));\n }\n newRow.setLevelMembers(nMembers);\n newRow.setDimPos(row.getDimPos());\n newRow.setMeasures(row.getMeasures());\n newRow.setMeasureList(row.getMeasureList());\n newRow.setParameterValues(row.getParameterValues());\n } else {\n newRow = row;\n }\n if (this.existReferenceDate) {\n sortedFactRows.push(newRow);\n } else {\n factRows.add(newRow);\n }\n}\n"
"public String getShortInfo() {\n return \"String_Node_Str\" + dataDomain.getSet().getBaseStorageVA().size() + \"String_Node_Str\";\n}\n"
"public void publish(final String topic) {\n this.checkState();\n this.checkTopic(topic);\n if (!this.publishedTopics.contains(topic)) {\n this.producerZooKeeper.publishTopic(topic, this);\n this.publishedTopics.add(topic);\n }\n}\n"
"public void testRSAServer() throws Exception {\n KeyStore ks = getRsaKeyStore(false);\n KeyStore trustStore = KeyStore.getInstance(\"String_Node_Str\");\n trustStore.load(null, PASSWORD);\n trustStore.setCertificateEntry(\"String_Node_Str\", ks.getCertificate(\"String_Node_Str\"));\n SSLUtils.startServer(ks, PASSWORD, trustStore, false, 8886);\n TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance(\"String_Node_Str\", BouncyCastleJsseProvider.PROVIDER_NAME);\n trustManagerFactory.init(trustStore);\n SSLContext context = SSLContext.getInstance(\"String_Node_Str\");\n context.init(null, trustManagerFactory.getTrustManagers(), null);\n SSLSocketFactory f = context.getSocketFactory();\n SSLSocket c = (SSLSocket) f.createSocket(\"String_Node_Str\", 8888);\n c.setUseClientMode(true);\n c.startHandshake();\n c.getOutputStream().write('!');\n c.getInputStream().read();\n}\n"
"public void createParamEmptySetTest() throws UnsupportedEncodingException {\n UpdateIssueParams params = new UpdateIssueParams(1000000001l);\n params.resolution(null).assigneeId(0).dueDate(null).startDate(null).categoryIds(null).versionIds(null).milestoneIds(null).estimatedHours(null).actualHours(null);\n List<NameValuePair> parameters = params.getParamList();\n assertEquals(11, parameters.size());\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n assertEquals(true, existsOneKeyValue(parameters, \"String_Node_Str\", \"String_Node_Str\"));\n}\n"
"private void bindObjLiteralId(ObjectLiteralField astObjectliteralField, final JstIdentifier id, IExpr value, NV nv) {\n if (value instanceof FuncExpr) {\n final TranslateHelper.RenameableSynthJstProxyMethod mtdBinding = new TranslateHelper.RenameableSynthJstProxyMethod(((FuncExpr) value).getFunc(), id.getName());\n id.setJstBinding(mtdBinding);\n id.setType(new JstFuncType(mtdBinding));\n }\n final List<IJsCommentMeta> metaArr = getCommentMeta(astObjectliteralField);\n if (metaArr != null && metaArr.size() > 0) {\n final IJsCommentMeta meta = metaArr.get(0);\n if (meta.getTyping() != null) {\n nv.setOptional(meta.getTyping().isOptional());\n final IJstType metaDefinedType = TranslateHelper.findType(m_ctx, meta.getTyping(), meta);\n if (metaDefinedType != null) {\n id.setType(metaDefinedType);\n if (metaDefinedType instanceof JstFuncType) {\n final IJstMethod replacement = TranslateHelper.MethodTranslateHelper.createJstSynthesizedMethod(metaArr, m_ctx, id.getName());\n if (replacement != null) {\n TranslateHelper.replaceSynthesizedMethodBinding(id, replacement);\n }\n }\n }\n }\n }\n}\n"
"public void drawActiveElements(GL gl) {\n for (HeatMapWrapper heatMapWrapper : heatMapWrappers) {\n if (heatMapWrapper.handleDragging(gl, glMouseListener)) {\n view.setDisplayListDirty();\n }\n }\n for (HeatMapWrapper heatMapWrapper : heatMapWrappers) {\n if (heatMapWrapper.isNewSelection()) {\n for (HeatMapWrapper wrapper : heatMapWrappers) {\n if (wrapper != heatMapWrapper) {\n wrapper.choosePassiveHeatMaps(relations.getMapping(heatMapWrapper.getSet()), heatMapWrapper.getContentVAsOfHeatMaps());\n }\n }\n view.setDisplayListDirty();\n break;\n }\n }\n for (HeatMapWrapper heatMapWrapper : heatMapWrappers) {\n heatMapWrapper.drawRemoteItems(gl, glMouseListener, pickingManager);\n }\n dragAndDropController.handleDragging(gl, glMouseListener);\n}\n"
"public void localListenerTest() throws InterruptedException {\n map1.addLocalEntryListener(createEntryListener(true));\n map2.addLocalEntryListener(createEntryListener(true));\n int k = 4;\n putDummyData(k);\n checkCountWithExpected(0, k, k);\n}\n"
"public boolean isUnscopedQualifiedName() {\n switch(getType()) {\n case Token.NAME:\n return !getString().isEmpty();\n case Token.GETPROP:\n return getFirstChild().isUnscopedQualifiedName();\n default:\n return false;\n }\n}\n"
"public static String getEnclosingEmbeddedFieldName(EntityMetadata m, String criteria, boolean viaColumnName) {\n String enclosingEmbeddedFieldName = null;\n StringTokenizer strToken = new StringTokenizer(criteria, \"String_Node_Str\");\n String embeddedFieldName = null;\n String embeddableAttributeName = null;\n while (strToken.hasMoreElements()) {\n embeddableAttributeName = strToken.nextToken();\n if (strToken.countTokens() > 0) {\n embeddedFieldName = strToken.nextToken();\n }\n }\n Metamodel metaModel = KunderaMetadata.INSTANCE.getApplicationMetadata().getMetamodel(m.getPersistenceUnit());\n EntityType entity = metaModel.entity(m.getEntityClazz());\n try {\n Attribute attribute = entity.getAttribute(embeddableAttributeName);\n if (((MetamodelImpl) metaModel).isEmbeddable(((AbstractAttribute) attribute).getBindableJavaType())) {\n EmbeddableType embeddable = metaModel.embeddable(((AbstractAttribute) attribute).getBindableJavaType());\n Iterator<Attribute> iter = embeddable.getAttributes().iterator();\n while (iter.hasNext()) {\n AbstractAttribute attrib = (AbstractAttribute) iter.next();\n if (viaColumnName && attrib.getName().equals(embeddedFieldName)) {\n enclosingEmbeddedFieldName = attribute.getName();\n break;\n }\n if (!viaColumnName && attrib.getJPAColumnName().equals(embeddedFieldName)) {\n enclosingEmbeddedFieldName = attribute.getName();\n break;\n }\n }\n }\n } catch (IllegalArgumentException iax) {\n return null;\n }\n return enclosingEmbeddedFieldName;\n}\n"
"private void _readConstraintFile(String filename) throws PropertyFailedRegressionTestException {\n File file = new File(filename);\n try {\n BufferedReader reader = null;\n try {\n reader = new BufferedReader(new FileReader(file));\n String line = reader.readLine();\n while (line != null) {\n _trainedConstraints.add(line);\n line = reader.readLine();\n }\n getStats().put(\"String_Node_Str\", _trainedConstraints.size());\n } finally {\n if (reader != null) {\n reader.close();\n }\n }\n } catch (IOException ex) {\n throw new PropertyFailedRegressionTestException(this, \"String_Node_Str\" + filename + \"String_Node_Str\");\n }\n}\n"
"public void showIssuePicker_typeQuery_displaysCorrectly() {\n triggerIssuePicker(new ArrayList<>());\n TextField issuePickerTextField = GuiTest.find(QUERY_FIELD_ID);\n clickOn(issuePickerTextField);\n type(\"String_Node_Str\");\n assertEquals(\"String_Node_Str\", issuePickerTextField.getText());\n}\n"
"synchronized public void addCache(Cacheable cache) {\n cache.getReferenceCount().set(1);\n Object cacheKey = cache.getCacheKey();\n Cacheable oldCache = caches.get(cacheKey);\n if (oldCache != null) {\n int referenceCount = oldCache.getReferenceCount().get();\n if (referenceCount >= 1) {\n throw new IllegalStateException(\"String_Node_Str\");\n }\n if (referenceCount == 0) {\n freeCaches.remove(oldCache);\n } else {\n assert (systemCache != null);\n synchronized (systemCache) {\n systemCache.removeCache(oldCache);\n }\n }\n } else {\n if (systemCache != null) {\n synchronized (systemCache) {\n systemCache.increaseUsedCacheSize(1);\n }\n }\n }\n if (maxCacheSize > 0) {\n adjustFreeCaches();\n }\n}\n"
"private void setup() {\n setupMainIssueCard();\n TurboIssue issue = guiElement.getIssue();\n Text issueTitle = new Text(\"String_Node_Str\" + issue.getId() + \"String_Node_Str\" + issue.getTitle());\n issueTitle.setWrappingWidth(CARD_WIDTH);\n issueTitle.getStyleClass().add(\"String_Node_Str\");\n if (issue.isCurrentlyRead()) {\n issueTitle.getStyleClass().add(\"String_Node_Str\");\n }\n if (!issue.isOpen()) {\n issueTitle.getStyleClass().add(\"String_Node_Str\");\n }\n setupIssueDetailsBox();\n setupAuthorAssigneeBox();\n updateDetails();\n setPadding(new Insets(3, 0, 3, 0));\n setSpacing(1);\n getChildren().addAll(issueTitle, issueDetails, authorAssigneeBox);\n}\n"
"public Record createRecord(Data key, Object value, long ttlMillis, long now) {\n Record record = getRecordFactory().newRecord(key, value);\n record.setLastAccessTime(now);\n record.setLastUpdateTime(now);\n record.setCreationTime(now);\n final long ttlMillisFromConfig = calculateTTLMillis(mapConfig);\n final long ttl = pickTTL(ttlMillis, ttlMillisFromConfig);\n record.setTtl(ttl);\n final long maxIdleMillis = getMaxIdleMillis();\n setExpirationTime(record, maxIdleMillis);\n return record;\n}\n"
"protected Vector getVisibleKeys(PGraphics pg) {\n int zoomLevel = Map.getZoomLevelFromScale((float) innerScale);\n synchronized (this) {\n float[] innerTL = getInnerObjectFromObjectPosition(0, 0);\n float[] innerTR = getInnerObjectFromObjectPosition(getWidth(), 0);\n float[] innerBR = getInnerObjectFromObjectPosition(getWidth(), getHeight());\n float[] innerBL = getInnerObjectFromObjectPosition(0, getHeight());\n Coordinate coordTL = getCoordinateFromInnerPosition(innerTL[0], innerTL[1]).zoomTo(zoomLevel);\n Coordinate coordTR = getCoordinateFromInnerPosition(innerTR[0], innerTR[1]).zoomTo(zoomLevel);\n Coordinate coordBR = getCoordinateFromInnerPosition(innerBR[0], innerBR[1]).zoomTo(zoomLevel);\n Coordinate coordBL = getCoordinateFromInnerPosition(innerBL[0], innerBL[1]).zoomTo(zoomLevel);\n minCol = (int) PApplet.min(new float[] { coordTL.column, coordTR.column, coordBR.column, coordBL.column });\n maxCol = (int) PApplet.max(new float[] { coordTL.column, coordTR.column, coordBR.column, coordBL.column });\n minRow = (int) PApplet.min(new float[] { coordTL.row, coordTR.row, coordBR.row, coordBL.row });\n maxRow = (int) PApplet.max(new float[] { coordTL.row, coordTR.row, coordBR.row, coordBL.row });\n }\n minCol -= grid_padding;\n minRow -= grid_padding;\n maxCol += grid_padding;\n maxRow += grid_padding;\n int numberTiles = (int) Map.getScaleFromZoom(zoomLevel);\n minCol = PApplet.constrain(minCol, 0, numberTiles);\n maxCol = PApplet.constrain(maxCol, 0, numberTiles);\n minRow = PApplet.constrain(minRow, 0, numberTiles);\n maxRow = PApplet.constrain(maxRow, 0, numberTiles);\n Vector visibleKeys = new Vector();\n for (int col = minCol; col <= maxCol; col++) {\n for (int row = minRow; row <= maxRow; row++) {\n Coordinate coord = provider.sourceCoordinate(new Coordinate(row, col, zoomLevel));\n coord.roundValues();\n visibleKeys.add(coord);\n if (!images.containsKey(coord)) {\n grabTile(coord);\n boolean gotParent = false;\n for (int i = (int) coord.zoom; i > 0; i--) {\n Coordinate zoomed = coord.zoomTo(i).container();\n zoomed.roundValues();\n if (images.containsKey(zoomed)) {\n visibleKeys.add(zoomed);\n gotParent = true;\n break;\n }\n }\n if (!gotParent) {\n Coordinate zoomed = coord.zoomBy(1).container();\n Coordinate[] kids = { zoomed, zoomed.right(), zoomed.down(), zoomed.right().down() };\n for (int i = 0; i < kids.length; i++) {\n zoomed = kids[i];\n zoomed.row = PApplet.round(zoomed.row);\n zoomed.column = PApplet.round(zoomed.column);\n zoomed.zoom = PApplet.round(zoomed.zoom);\n if (images.containsKey(zoomed)) {\n visibleKeys.add(zoomed);\n }\n }\n }\n }\n }\n }\n Collections.sort(visibleKeys, zoomComparator);\n queue.retainAll(visibleKeys);\n queueSorter.setCenter(new Coordinate((minRow + maxRow) / 2.0f, (minCol + maxCol) / 2.0f, zoomLevel));\n Collections.sort(queue, queueSorter);\n processQueue();\n return visibleKeys;\n}\n"
"private CheckContactDuplication buildCheckContactDuplicationCommand(ContactDTO contactDTO) {\n CheckContactDuplication checkDuplicationCommand;\n String currentEmail = getCurrentSingleValue(DefaultContactFlexibleElementType.EMAIL_ADDRESS, contactDTO.getEmail());\n switch(contactDTO.getContactModel().getType()) {\n case INDIVIDUAL:\n String currentFamilyName = getCurrentSingleValue(DefaultContactFlexibleElementType.FAMILY_NAME, contactDTO.getFamilyName());\n String currentFirstName = getCurrentSingleValue(DefaultContactFlexibleElementType.FIRST_NAME, contactDTO.getFirstname());\n checkDuplicationCommand = new CheckContactDuplication(contactDTO.getId(), currentEmail, currentFamilyName, currentFirstName, contactDTO.getContactModel());\n break;\n case ORGANIZATION:\n String currentOrganizationName = getCurrentSingleValue(DefaultContactFlexibleElementType.ORGANIZATION_NAME, contactDTO.getOrganizationName());\n checkDuplicationCommand = new CheckContactDuplication(contactDTO.getId(), currentEmail, currentOrganizationName, null);\n break;\n default:\n throw new IllegalStateException(\"String_Node_Str\" + contactDTO.getContactModel().getType());\n }\n return checkDuplicationCommand;\n}\n"
"private void saveWordInHistory(CharSequence result) {\n if (mWord.size() <= 1) {\n mWord.reset();\n return;\n }\n final String resultCopy = result.toString();\n TypedWordAlternatives entry = new TypedWordAlternatives(resultCopy, new WordComposer(mWord));\n mWordHistory.add(entry);\n}\n"
"private static void refreshItemsWithNow(List<Metadata> ms) {\n noØ(ms);\n if (ms.isEmpty())\n return;\n IO_THREAD.execute(() -> {\n MapSet<URI, Metadata> mm = new MapSet<>(Metadata::getUri, ms);\n APP.db.updatePer(ms);\n APP.db.updateInMemoryDbFromPersisted();\n runFX(() -> {\n PlaylistManager.playlists.stream().flatMap(Playlist::stream).forEach((PlaylistItem p) -> mm.ifHasK(p.getUri(), p::update));\n mm.ifHasE(playingItem.get(), playingItem::update);\n if (playing.i.getValue() != null)\n mm.ifHasE(playing.i.getValue(), playing.i::setValue);\n if (playlistSelected.i.getValue() != null)\n mm.ifHasK(playlistSelected.i.getValue().getUri(), m -> playlistSelected.i.setValue(m.toPlaylist()));\n if (librarySelected.i.getValue() != null)\n mm.ifHasE(librarySelected.i.getValue(), librarySelected.i::setValue);\n refreshHandlers.forEach(h -> h.accept(mm));\n });\n });\n}\n"
"public static Emitter newBulletTracerEmitter(Vector2f pos, int emitterTimeToLive) {\n int maxParticles = 68;\n final Emitter emitter = new Emitter(pos, emitterTimeToLive, maxParticles).setName(\"String_Node_Str\").setDieInstantly(false);\n BatchedParticleGenerator gen = new BatchedParticleGenerator(0, maxParticles).addSingleParticleGenerator(new RandomColorSingleParticleGenerator(new Color(0xffbA00ff), new Color(0xffff00ff))).addSingleParticleGenerator(new SingleParticleGenerator() {\n\n public void onGenerateParticle(int index, TimeStep timeStep, ParticleData particles) {\n particles.color[index].a = 0.0f;\n }\n }).addSingleParticleGenerator(new SetPositionSingleParticleGenerator());\n emitter.addParticleGenerator(gen);\n emitter.addParticleUpdater(new ParticleUpdater() {\n public void update(TimeStep timeStep, ParticleData particles) {\n ClientEntity ent = emitter.attachedTo();\n if (ent != null) {\n for (int index = 0; index < particles.numberOfAliveParticles; index++) {\n Vector2f pos = ent.getCenterPos();\n Vector2f vel = ent.getMovementDir();\n float offset = index;\n Vector2f.Vector2fMS(pos, vel, offset, particles.pos[index]);\n float percentange = (float) index / particles.numberOfAliveParticles;\n particles.color[index].a = 0.9512f * (1f - percentange);\n }\n } else {\n for (int index = 0; index < particles.numberOfAliveParticles; index++) {\n particles.color[index].a = 0f;\n }\n }\n }\n });\n emitter.addParticleUpdater(new KillIfAttachedIsDeadUpdater());\n emitter.addParticleRenderer(new RectParticleRenderer(2, 2));\n return emitter;\n}\n"
"void fromDBObject(final DBObject dbObject, final MappedField mf, final Object entity, final Map<Key, Object> retrieved) {\n String name = mf.getName();\n Class fieldType = mf.getType();\n try {\n if (mf.isMap()) {\n readMap(dbObject, mf, entity, name, retrieved);\n } else if (mf.isMultipleValues()) {\n readCollection(dbObject, mf, entity, name, retrieved);\n } else {\n if (dbObject.containsField(name)) {\n BasicDBObject dbVal = (BasicDBObject) dbObject.get(name);\n Object refObj = ReflectionUtils.createInstance(fieldType, dbVal);\n refObj = mapper.fromDb(dbVal, refObj, retrieved);\n if (refObj != null) {\n mf.setFieldValue(entity, refObj);\n }\n }\n }\n } catch (Exception e) {\n throw new RuntimeException(e);\n }\n}\n"
"public static void createPostLocationIndex(CassandraClient cassandraClient, String postId, String createDate, String latitude, String longitude) {\n UUID uuid = UUID.fromString(postId);\n GeoHashUtil util = new GeoHashUtil();\n String geoHash = util.encode(latitude, longitude);\n cassandraClient.insert(DBConstants.INDEX_POST_LOCATION, geoHash, uuid, createDate);\n}\n"
"private void bufferQueue(String cmd, int retries) throws Exception {\n if (simulationPlot != null)\n simulationPlot.add(cmd);\n if (serialOutStream == null) {\n if (nonRunningWarn)\n Debug.d(\"String_Node_Str\" + cmd + \"String_Node_Str\");\n nonRunningWarn = false;\n return;\n }\n if (retries > 3) {\n Debug.e(\"String_Node_Str\" + retries + \"String_Node_Str\" + cmd);\n return;\n }\n if (sendLine(cmd)) {\n long resp = waitForResponse();\n if (resp == shutDown) {\n throw new Exception(\"String_Node_Str\");\n } else if (resp == allSentOK) {\n lineNumber++;\n } else {\n long gotTo = lineNumber;\n lineNumber = resp;\n String rCmd = \"String_Node_Str\";\n while (lineNumber <= gotTo && !rCmd.contentEquals(\"String_Node_Str\")) {\n rCmd = ringGet(lineNumber);\n bufferQueue(rCmd, retries + 1);\n }\n }\n }\n}\n"
"public void progress() {\n PotionEffect effect = new PotionEffect(PotionEffectType.SLOW, 60, 1);\n if (!player.isSneaking()) {\n remove();\n return;\n } else if (holdTime > 0 && System.currentTimeMillis() - this.time > holdTime) {\n remove();\n return;\n }\n if (!canBeUsedOnUndeadMobs) {\n for (Entity entity : TARGETED_ENTITIES.keySet()) {\n if (isUndead(entity)) {\n TARGETED_ENTITIES.remove(entity);\n }\n }\n }\n if (onlyUsableDuringMoon && !isFullMoon(player.getWorld()) && !bPlayer.canBloodbendAtAnytime()) {\n remove();\n return;\n } else if (canOnlyBeUsedAtNight && !isNight(player.getWorld()) && !bPlayer.canBloodbendAtAnytime()) {\n remove();\n return;\n } else if (!bPlayer.canBendIgnoreCooldowns(this)) {\n remove();\n return;\n }\n if (bPlayer.isAvatarState()) {\n ArrayList<Entity> entities = new ArrayList<>();\n for (Entity entity : GeneralMethods.getEntitiesAroundPoint(player.getLocation(), range)) {\n if (GeneralMethods.isRegionProtectedFromBuild(this, entity.getLocation())) {\n continue;\n } else if (!(entity instanceof LivingEntity)) {\n continue;\n } else if (entity instanceof Player) {\n BendingPlayer targetBPlayer = BendingPlayer.getBendingPlayer((Player) entity);\n if (targetBPlayer != null) {\n if (!targetBPlayer.canBeBloodbent() || entity.getEntityId() == player.getEntityId()) {\n continue;\n }\n }\n }\n entities.add(entity);\n if (!TARGETED_ENTITIES.containsKey(entity) && entity instanceof LivingEntity) {\n DamageHandler.damageEntity(entity, 0, this);\n TARGETED_ENTITIES.put(entity, player);\n }\n if (player.getWorld() != entity.getLocation().getWorld()) {\n TARGETED_ENTITIES.remove(entity);\n continue;\n }\n if (entity instanceof LivingEntity) {\n entity.setVelocity(new Vector(0, 0, 0));\n new TempPotionEffect((LivingEntity) entity, effect);\n entity.setFallDistance(0);\n if (entity instanceof Creature) {\n ((Creature) entity).setTarget(null);\n }\n AirAbility.breakBreathbendingHold(entity);\n }\n }\n for (Entity entity : TARGETED_ENTITIES.keySet()) {\n if (!entities.contains(entity) && TARGETED_ENTITIES.get(entity) == player) {\n TARGETED_ENTITIES.remove(entity);\n }\n }\n } else {\n if (TARGETED_ENTITIES.get(target) != player) {\n remove();\n return;\n }\n for (Entity entity : TARGETED_ENTITIES.keySet()) {\n if (entity instanceof Player) {\n BendingPlayer targetBPlayer = BendingPlayer.getBendingPlayer((Player) entity);\n if (targetBPlayer != null && !targetBPlayer.canBeBloodbent()) {\n TARGETED_ENTITIES.remove(entity);\n continue;\n }\n }\n Location newLocation = entity.getLocation();\n if (player.getWorld() != newLocation.getWorld()) {\n TARGETED_ENTITIES.remove(entity);\n continue;\n }\n }\n Location location = GeneralMethods.getTargetedLocation(player, 6, getTransparentMaterial());\n double distance = 0;\n if (location.getWorld().equals(target.getWorld())) {\n distance = location.distance(target.getLocation());\n }\n double dx, dy, dz;\n dx = location.getX() - target.getLocation().getX();\n dy = location.getY() - target.getLocation().getY();\n dz = location.getZ() - target.getLocation().getZ();\n Vector vector = new Vector(dx, dy, dz);\n if (distance > .5) {\n target.setVelocity(vector.normalize().multiply(.5));\n } else {\n target.setVelocity(new Vector(0, 0, 0));\n }\n new TempPotionEffect((LivingEntity) target, effect);\n target.setFallDistance(0);\n if (target instanceof Creature) {\n ((Creature) target).setTarget(null);\n }\n AirAbility.breakBreathbendingHold(target);\n }\n}\n"
"public void usage_is_required() {\n givenWithContent(authToken).body(minValidPayload().put(Key.USAGE, null).asArray()).when().put(UrlSchema.FACILITY_UTILIZATION, f.id).then().spec(assertResponse(HttpStatus.BAD_REQUEST, ValidationException.class)).body(\"String_Node_Str\", is(\"String_Node_Str\" + Key.USAGE)).body(\"String_Node_Str\", is(\"String_Node_Str\"));\n}\n"
"public boolean initialize(OpenJPAStateManager stateManager, PCState pcState, FetchConfiguration fetchConfiguration, Object obj) {\n log.debug(\"String_Node_Str\");\n cassandraStore.open();\n stateManager.initialize(stateManager.getMetaData().getDescribedType(), pcState);\n return cassandraStore.getObject(stateManager, stateManager.getUnloaded(fetchConfiguration));\n}\n"
"private final int jjMoveStringLiteralDfa1_0(long active0) {\n try {\n curChar = input_stream.readChar();\n } catch (java.io.IOException e) {\n jjStopStringLiteralDfa_0(0, active0);\n return 1;\n }\n switch(curChar) {\n case 97:\n return jjMoveStringLiteralDfa2_0(active0, 0x800000L);\n case 114:\n return jjMoveStringLiteralDfa2_0(active0, 0x200000L);\n case 117:\n return jjMoveStringLiteralDfa2_0(active0, 0x800000L);\n default:\n break;\n }\n return jjStartNfa_0(0, active0);\n}\n"
"private boolean isLiteralClose(String template, char magicChar, int tagStart, int i) {\n if (magicChar == '.' && i - tagStart > 8) {\n if (template.charAt(tagStart + 1) == '%') {\n int exprEnd = i - 1;\n if (template.charAt(exprEnd) == '%')\n exprEnd--;\n String expr = template.substring(tagStart + 2, exprEnd).trim();\n if (expr.equals(\"String_Node_Str\") || expr.equals(\"String_Node_Str\")) {\n return true;\n }\n }\n } else if (magicChar == '^') {\n if (tagStart == i - 2) {\n return true;\n }\n } else if (magicChar == '~') {\n if (tagStart == i - 3 && template.charAt(i - 1) == '.') {\n return true;\n } else if (tagStart == i - 11 && template.substring(tagStart + 3, i).equals(\"String_Node_Str\")) {\n return true;\n }\n } else if (tagStart == i - 9 && magicChar == '/') {\n if (template.substring(tagStart + 1, i).equals(\"String_Node_Str\")) {\n return true;\n }\n }\n return false;\n}\n"
"public Point getPointOffset() {\n String[] pair = arguments[7].split(\"String_Node_Str\");\n int x = Integer.valueOf(pair[0]);\n int y = Integer.valueOf(pair[1]);\n return new Point(x, y);\n}\n"
"static <D extends DynamicObject<D>> Collection<Method> fieldGetters(Class<D> type) {\n Collection<Method> ret = new LinkedHashSet<>();\n for (Method method : type.getDeclaredMethods()) if (isGetter(method))\n ret.add(method);\n return ret;\n}\n"
"public Map<? extends ServerResource, Map<String, String>> find(long dcId, Long podId, Long clusterId, URI uri, String username, String password) throws DiscoveryException {\n Map<KvmDummyResourceBase, Map<String, String>> resources = new HashMap<KvmDummyResourceBase, Map<String, String>>();\n Map<String, String> details = new HashMap<String, String>();\n if (!uri.getScheme().equals(\"String_Node_Str\")) {\n String msg = \"String_Node_Str\" + uri;\n s_logger.debug(msg);\n return null;\n }\n com.trilead.ssh2.Connection sshConnection = null;\n Session sshSession = null;\n String agentIp = null;\n try {\n String hostname = uri.getHost();\n InetAddress ia = InetAddress.getByName(hostname);\n agentIp = ia.getHostAddress();\n String guid = UUID.nameUUIDFromBytes(agentIp.getBytes()).toString();\n sshConnection = new com.trilead.ssh2.Connection(agentIp, 22);\n sshConnection.connect(null, 60000, 60000);\n if (!sshConnection.authenticateWithPassword(username, password)) {\n throw new Exception(\"String_Node_Str\");\n }\n SCPClient scp = new SCPClient(sshConnection);\n scp.put(_setupAgentPath, \"String_Node_Str\", \"String_Node_Str\");\n sshExecuteCmd(sshConnection, \"String_Node_Str\" + \"String_Node_Str\" + _hostIp + \"String_Node_Str\" + dcId + \"String_Node_Str\" + podId + \"String_Node_Str\" + guid + \"String_Node_Str\", 3);\n KvmDummyResourceBase kvmResource = new KvmDummyResourceBase();\n Map<String, Object> params = new HashMap<String, Object>();\n params.put(\"String_Node_Str\", Long.toString(dcId));\n params.put(\"String_Node_Str\", Long.toString(podId));\n params.put(\"String_Node_Str\", guid);\n params.put(\"String_Node_Str\", agentIp);\n kvmResource.configure(\"String_Node_Str\", params);\n kvmResource.setRemoteAgent(true);\n resources.put(kvmResource, details);\n return resources;\n } catch (Exception e) {\n String msg = \"String_Node_Str\" + e.toString() + \"String_Node_Str\" + e.getMessage();\n s_logger.warn(msg);\n } finally {\n if (sshSession != null)\n sshSession.close();\n if (sshConnection != null)\n sshConnection.close();\n }\n return null;\n}\n"