content stringlengths 40 137k |
|---|
"public void onCreate(Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\n Log.e(tag, \"String_Node_Str\");\n mSoundEffects = new SoundEffectPlayer();\n mSoundEffects.setup(this);\n loadExtras(getIntent());\n Log.e(tag, \"String_Node_Str\");\n loadUI();\n Log.e(tag, \"String_Node_Str\");\n}\n"
|
"private void init() {\n JedisPoolConfig config = new JedisPoolConfig();\n config.setMaxIdle(100);\n config.setMaxTotal(100);\n config.setMaxWaitMillis(10000);\n config.setTestOnBorrow(true);\n config.setTestOnReturn(true);\n RedisClusterConfiguration redisClusterConfiguration = new RedisClusterConfiguration();\n redisClusterConfiguration.addClusterNode(new RedisNode(\"String_Node_Str\", 7000));\n JedisConnectionFactory jedisConnectionFactory = new JedisConnectionFactory(config);\n jedisConnectionFactory.setHostName(\"String_Node_Str\");\n jedisConnectionFactory.setPort(6379);\n jedisConnectionFactory.setPassword(\"String_Node_Str\");\n jedisConnectionFactory.setTimeout(100000);\n jedisConnectionFactory.afterPropertiesSet();\n HostAndPort hostAndPort = new HostAndPort(\"String_Node_Str\", 7000);\n JedisCluster jedisCluster = new JedisCluster(hostAndPort);\n redisLock = new RedisLock.Builder(jedisConnectionFactory, RedisToolsConstant.SINGLE).lockPrefix(\"String_Node_Str\").sleepTime(100).build();\n}\n"
|
"public void userThreadStarted(final Thread userThread) {\n if (this.encapsulatedRuntimeTask != null) {\n this.encapsulatedRuntimeTask.userThreadStarted(userThread);\n } else {\n LOG.error(\"String_Node_Str\");\n }\n}\n"
|
"protected Type _methodCall(String methodName, Type[] argTypes) throws IllegalActionException {\n CachedMethod cachedMethod = CachedMethod.findMethod(methodName, argTypes, CachedMethod.METHOD);\n if (cachedMethod.isValid()) {\n Type type = cachedMethod.getReturnType();\n return type;\n }\n if (argTypes[0] instanceof ObjectType) {\n Object object = ((ObjectType) argTypes[0]).getValue();\n if (object != null) {\n if (object instanceof NamedObj) {\n Object result = ((NamedObj) object).getAttribute(methodName);\n if (result == null && object instanceof Entity) {\n result = ((Entity) object).getPort(methodName);\n }\n if (result == null && object instanceof CompositeEntity) {\n result = ((CompositeEntity) object).getEntity(methodName);\n if (result == null) {\n result = ((CompositeEntity) object).getRelation(methodName);\n }\n }\n if (result == null) {\n List attributes = ((NamedObj) object).attributeList(ContainmentExtender.class);\n Iterator attrIterator = attributes.iterator();\n while (result == null && attrIterator.hasNext()) {\n ContainmentExtender extender = (ContainmentExtender) attrIterator.next();\n result = extender.getContainedObject(methodName);\n }\n }\n if (result != null) {\n if (result instanceof Variable) {\n Type type = ((Variable) result).getType();\n if (type instanceof MatrixType) {\n return ((MatrixType) type).getElementType();\n }\n if (type instanceof ArrayType) {\n return ((ArrayType) type).getElementType();\n }\n return type;\n } else {\n return new ObjectType(result, result.getClass());\n }\n }\n }\n }\n Class<?> valueClass = ((ObjectType) argTypes[0]).getValueClass();\n if (valueClass == null) {\n valueClass = Object.class;\n }\n Set<Class<?>> classes = new HashSet<Class<?>>();\n classes.add(valueClass);\n while (!classes.isEmpty()) {\n Iterator<Class<?>> iterator = classes.iterator();\n valueClass = iterator.next();\n iterator.remove();\n if (!Modifier.isPublic(valueClass.getModifiers())) {\n for (Class<?> interf : valueClass.getInterfaces()) {\n classes.add(interf);\n }\n Class<?> superclass = valueClass.getSuperclass();\n if (superclass != null) {\n classes.add(superclass);\n }\n } else {\n Type result = _getMethodReturnType(valueClass, methodName, argTypes);\n if (result != null) {\n return result;\n }\n }\n }\n }\n StringBuffer buffer = new StringBuffer();\n for (int i = 1; i < argTypes.length; i++) {\n if (i == 1) {\n buffer.append(argTypes[i].toString());\n } else {\n buffer.append(\"String_Node_Str\" + argTypes[i].toString());\n }\n }\n throw new IllegalActionException(\"String_Node_Str\" + argTypes[0] + \"String_Node_Str\" + methodName + \"String_Node_Str\" + buffer + \"String_Node_Str\");\n}\n"
|
"public void startAutoText(IAutoTextContent autoText) {\n HyperlinkDef link = parseHyperLink(autoText);\n BookmarkDef bookmark = getBookmark(autoText);\n engine.addData(autoText.getText(), autoText.getComputedStyle(), link, bookmark);\n}\n"
|
"private void createOpenMenuItem(Menu parentMenu) {\n openMenuItem = new MenuItem(parentMenu, SWT.PUSH);\n openMenuItem.setText(\"String_Node_Str\");\n needSelectedArtifactListener.addArtifactEnabled(openMenuItem);\n openMenuItem.addSelectionListener(new SelectionAdapter() {\n public void widgetSelected(SelectionEvent event) {\n openViewer((IStructuredSelection) treeViewer.getSelection());\n }\n });\n}\n"
|
"public void load(GuaguaWritableAdapter<LongWritable> currentKey, GuaguaWritableAdapter<Text> currentValue, WorkerContext<DTMasterParams, DTWorkerParams> context) {\n this.count += 1;\n if ((this.count) % 100000 == 0) {\n LOG.info(\"String_Node_Str\", this.count);\n }\n float[] numericInputs = new float[this.numericInputCount];\n String[] categoricalInputs = new String[this.categoricalInputCount];\n float ideal = 0f;\n float significance = 1f;\n int index = 0, numericInputsIndex = 0, categoricalInputsIndex = 0;\n for (String input : DEFAULT_SPLITTER.split(currentValue.getWritable().toString())) {\n float floatValue = NumberFormatUtils.getFloat(input, 0f);\n if (Float.isNaN(floatValue) || Double.isNaN(floatValue)) {\n floatValue = 0f;\n }\n if (index == this.columnConfigList.size()) {\n significance = NumberFormatUtils.getFloat(input, 1f);\n break;\n } else {\n ColumnConfig columnConfig = this.columnConfigList.get(index);\n if (columnConfig != null && columnConfig.isTarget()) {\n ideal = floatValue;\n } else {\n if (!isAfterVarSelect) {\n if (!columnConfig.isMeta() && !columnConfig.isTarget() && CommonUtils.isGoodCandidate(columnConfig)) {\n if (columnConfig.isNumerical()) {\n numericInputs[numericInputsIndex] = floatValue;\n this.numericInputIndexMap.put(columnConfig.getColumnNum(), numericInputsIndex);\n numericInputsIndex += 1;\n } else if (columnConfig.isCategorical()) {\n if (input == null) {\n categoricalInputs[categoricalInputsIndex] = \"String_Node_Str\";\n } else {\n categoricalInputs[categoricalInputsIndex] = input;\n }\n this.categoricalInputIndexMap.put(columnConfig.getColumnNum(), categoricalInputsIndex);\n categoricalInputsIndex += 1;\n }\n }\n } else {\n if (columnConfig != null && !columnConfig.isMeta() && !columnConfig.isTarget() && columnConfig.isFinalSelect()) {\n if (columnConfig.isNumerical()) {\n numericInputs[numericInputsIndex] = floatValue;\n this.numericInputIndexMap.put(columnConfig.getColumnNum(), numericInputsIndex);\n numericInputsIndex += 1;\n } else if (columnConfig.isCategorical()) {\n if (input == null) {\n categoricalInputs[categoricalInputsIndex] = \"String_Node_Str\";\n } else {\n categoricalInputs[categoricalInputsIndex] = input;\n }\n this.categoricalInputIndexMap.put(columnConfig.getColumnNum(), categoricalInputsIndex);\n categoricalInputsIndex += 1;\n }\n }\n }\n }\n }\n index += 1;\n }\n float[] sampleWeights;\n if (this.treeNum == 1 || this.isGBDT) {\n sampleWeights = new float[this.treeNum];\n if (random.nextDouble() <= modelConfig.getTrain().getBaggingSampleRate()) {\n sampleWeights[0] = 1f;\n } else {\n sampleWeights[0] = 0f;\n }\n for (int i = 1; i < sampleWeights.length; i++) {\n sampleWeights[i] = 1f;\n }\n } else {\n sampleWeights = new float[this.treeNum];\n for (int i = 0; i < sampleWeights.length; i++) {\n sampleWeights[i] = this.rng[i].sample();\n }\n }\n float output = ideal;\n float predict = ideal;\n Data data = new Data(numericInputs, categoricalInputs, predict, output, output, significance, sampleWeights);\n boolean isNeedFailOver = !context.isFirstIteration();\n if (isNeedFailOver && this.isGBDT) {\n DTMasterParams lastMasterResult = context.getLastMasterResult();\n if (lastMasterResult != null) {\n List<TreeNode> trees = lastMasterResult.getTrees();\n if (trees.size() > 1) {\n int iterLen = lastMasterResult.isSwitchToNextTree() ? trees.size() - 2 : trees.size() - 1;\n for (int i = 0; i < iterLen; i++) {\n TreeNode currTree = trees.get(i);\n if (i == 0) {\n double oldPredict = predictNodeIndex(currTree.getNode(), data).getPredict().getPredict();\n predict = (float) oldPredict;\n output = -loss.computeGradient(predict, data.label);\n } else {\n double oldPredict = predictNodeIndex(currTree.getNode(), data).getPredict().getPredict();\n predict += (float) (this.learningRate * oldPredict);\n output = -loss.computeGradient(predict, data.label);\n }\n }\n data.output = output;\n data.predict = predict;\n }\n }\n }\n this.trainingData.append(data);\n}\n"
|
"protected Object check(HadoopServiceProperties serviceProperties, ClassLoader classLoader) throws Exception {\n Object configuration = Class.forName(\"String_Node_Str\", true, classLoader).newInstance();\n Object conf = ReflectionUtils.newInstance(\"String_Node_Str\", classLoader, new Object[] { configuration });\n ReflectionUtils.invokeMethod(conf, \"String_Node_Str\", new Object[] { \"String_Node_Str\", serviceProperties.getJobTracker() });\n ReflectionUtils.invokeMethod(conf, \"String_Node_Str\", new Object[] { \"String_Node_Str\", \"String_Node_Str\" });\n ReflectionUtils.invokeMethod(conf, \"String_Node_Str\", new Object[] { \"String_Node_Str\", \"String_Node_Str\" });\n ReflectionUtils.invokeMethod(conf, \"String_Node_Str\", new Object[] { \"String_Node_Str\", \"String_Node_Str\" });\n setHadoopProperties(conf, serviceProperties);\n boolean useKrb = serviceProperties.isUseKrb();\n boolean useMaprTicket = serviceProperties.isMaprT();\n if (useKrb) {\n String mrPrincipal = serviceProperties.getJtOrRmPrincipal();\n ReflectionUtils.invokeMethod(conf, \"String_Node_Str\", new Object[] { \"String_Node_Str\", mrPrincipal });\n boolean useKeytab = serviceProperties.isUseKeytab();\n if (useKeytab) {\n String keytabPrincipal = serviceProperties.getKeytabPrincipal();\n String keytab = serviceProperties.getKeytab();\n ReflectionUtils.invokeStaticMethod(\"String_Node_Str\", classLoader, \"String_Node_Str\", new String[] { keytabPrincipal, keytab });\n }\n if (useMaprTicket) {\n System.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n System.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n System.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n System.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n String mapRTicketCluster = serviceProperties.getMaprTCluster();\n String mapRTicketDuration = serviceProperties.getMaprTDuration();\n Long desiredTicketDurInSecs = 86400L;\n if (mapRTicketDuration != null && StringUtils.isNotBlank(mapRTicketDuration)) {\n desiredTicketDurInSecs = Long.parseLong(mapRTicketDuration);\n }\n try {\n ReflectionUtils.invokeStaticMethod(\"String_Node_Str\", classLoader, \"String_Node_Str\", new Object[] { mapRTicketCluster, mapRTicketDuration });\n } catch (Exception e) {\n throw new SQLException(e);\n }\n }\n }\n if (useMaprTicket) {\n System.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n System.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n System.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n String mapRTicketUsername = serviceProperties.getUserName();\n String mapRTicketPassword = serviceProperties.getMaprTPassword();\n String mapRTicketCluster = serviceProperties.getMaprTCluster();\n Object mapRTicketDuration = serviceProperties.getMaprTDuration();\n try {\n String decryptedPassword = PasswordEncryptUtil.encryptPassword(mapRTicketPassword);\n ReflectionUtils.invokeStaticMethod(\"String_Node_Str\", classLoader, \"String_Node_Str\", new Object[] { false }, Boolean.class);\n ReflectionUtils.invokeStaticMethod(\"String_Node_Str\", classLoader, \"String_Node_Str\", new Object[] { mapRTicketCluster, mapRTicketUsername, decryptedPassword, mapRTicketDuration });\n } catch (Exception e) {\n throw new SQLException(e);\n }\n }\n Object jc = ReflectionUtils.newInstance(\"String_Node_Str\", classLoader, new Object[] { conf });\n return ReflectionUtils.invokeMethod(jc, \"String_Node_Str\", new Object[0]);\n}\n"
|
"public void onPlayerCommandPreprocess(PlayerCommandPreprocessEvent event) {\n String[] split = event.getMessage().split(\"String_Node_Str\");\n if (split.length == 0)\n return;\n String cmdName = split[0].substring(1).toLowerCase();\n ACCommands cmd = CommandManager.getInstance().getCommand(cmdName);\n if (cmd != null) {\n event.setCancelled(true);\n CommandManager.getInstance().executeCommand(event.getPlayer(), cmd, Utils.Arrays_copyOfRange(split, 1, split.length));\n }\n}\n"
|
"public void update() {\n try {\n URL url = new URL(\"String_Node_Str\");\n BufferedReader in = new BufferedReader(new InputStreamReader(url.openStream()));\n String str;\n while ((str = in.readLine()) != null) {\n int version = Integer.parseInt(str);\n if (version > minecod_version) {\n in.close();\n File directory = new File(getServer().getUpdateFolder());\n File plugin = new File(directory.getPath(), \"String_Node_Str\");\n download(log, new URL(\"String_Node_Str\"), plugin);\n getServer().dispatchCommand(new ConsoleCommandSender(getServer()), \"String_Node_Str\");\n return true;\n }\n }\n in.close();\n } catch (Exception e) {\n e.printStackTrace();\n }\n}\n"
|
"private static void runDigitalSignatureStripOOXML(Path input, Path output) throws IOException, AlreadyExistsException, GenericException, InvalidFormatException {\n FSUtils.copy(input, output, true);\n OPCPackage pkg = OPCPackage.open(output.toString(), PackageAccess.READ_WRITE);\n ArrayList<PackagePart> pps = pkg.getPartsByContentType(SIGN_CONTENT_TYPE_OOXML);\n for (PackagePart pp : pps) {\n pkg.removePart(pp);\n }\n ArrayList<PackagePart> ppct = pkg.getPartsByRelationshipType(signatureRelType);\n for (PackagePart pp : ppct) {\n pkg.removePart(pp);\n }\n pkg.close();\n}\n"
|
"public Future<Result<Thread>> start() throws IOException {\n final FutureImpl<Result<Thread>> future = UnsafeFutureImpl.<Result<Thread>>create();\n final long t1 = System.currentTimeMillis();\n grizzlyListener.start();\n if (logger.isLoggable(Level.INFO)) {\n logger.log(Level.INFO, KernelLoggerInfo.grizzlyStarted, new Object[] { Grizzly.getDotedVersion(), System.currentTimeMillis() - t1, grizzlyListener.getAddress(), ':', String.valueOf(grizzlyListener.getPort()), ']' });\n }\n future.result(new Result<Thread>(Thread.currentThread()));\n return future;\n}\n"
|
"public static ReaderTag getTag(String tagName) {\n if (TextUtils.isEmpty(tagName)) {\n return null;\n Cursor c = ReaderDatabase.getReadableDb().rawQuery(\"String_Node_Str\", new String[] { tagName });\n try {\n if (!c.moveToFirst())\n return null;\n return getTagFromCursor(c);\n } finally {\n SqlUtils.closeCursor(c);\n }\n}\n"
|
"public Map<Integer, List<Integer>> getResourcesOfTestUsers(int trainSize) {\n Map<Integer, List<Integer>> resourcesMap = new HashMap<Integer, List<Integer>>();\n if (trainSize == -1) {\n trainSize = 0;\n }\n for (int i = trainSize; i < getBookmarks().size(); i++) {\n Bookmark data = getBookmarks().get(i);\n int userID = data.getUserID();\n List<Integer> resources = resourcesMap.get(userID);\n if (resources == null) {\n resources = new ArrayList<Integer>();\n }\n resources.add(data.getResourceID());\n resourcesMap.put(userID, resources);\n }\n return resourcesMap;\n}\n"
|
"private Key createRightKey(ExpressionNode node, DboColumnMeta info) {\n byte[] data = retrieveValue(info, node.getRightChild());\n if (node.getType() == NoSqlLexer.LT)\n return new Key(data, false);\n else if (node.getType() == NoSqlLexer.GE)\n return new Key(data, true);\n else\n throw new RuntimeException(\"String_Node_Str\");\n}\n"
|
"public void testEOLWithHighlightSearch() {\n setHighlightSearch();\n final int pos = search(\"String_Node_Str\", \"String_Node_Str\" + \"String_Node_Str\");\n assertEquals(3, pos);\n}\n"
|
"public void deletePlot(Object id) {\n this.lock.lock();\n try {\n PlotInfo info = stackedPlots.remove(id);\n if (info == null)\n return;\n this.removeLayout(info.getLayout());\n stackedPlots.remove(id);\n if (isAutoValidate())\n validate();\n } finally {\n this.lock.unlock();\n }\n}\n"
|
"private void save() {\n final String ERROR_HEADER = \"String_Node_Str\";\n final String ERROR_TEXT = \"String_Node_Str\";\n String file = controller.actionShowSaveFileDialog(getShell(), \"String_Node_Str\");\n if (file == null)\n return;\n try {\n HierarchyBuilder<T> builder = null;\n if (getDialog().getCurrentPage() instanceof HierarchyWizardPageOrder) {\n builder = model.getOrderModel().getBuilder(true);\n } else if (getDialog().getCurrentPage() instanceof HierarchyWizardPageIntervals) {\n builder = model.getIntervalModel().getBuilder();\n } else if (getDialog().getCurrentPage() instanceof HierarchyWizardPageRedaction) {\n builder = model.getRedactionModel().getBuilder();\n }\n builder.save(file);\n } catch (Exception e) {\n controller.actionShowInfoDialog(getShell(), ERROR_HEADER, ERROR_TEXT + e.getMessage());\n return;\n }\n}\n"
|
"public boolean apply(Game game, Ability source) {\n Player controller = game.getPlayer(source.getControllerId());\n if (controller != null) {\n for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) {\n final int count = game.getBattlefield().getAllActivePermanents(new FilterCreaturePermanent(), playerId, game).size();\n if (count > 0) {\n Player player = game.getPlayer(playerId);\n if (player != null) {\n player.loseLife(count, game, false);\n }\n }\n }\n return true;\n }\n return false;\n}\n"
|
"protected Object getFromNamespace(String name) {\n Object v = _ns.getVariable(name, true);\n return v != null || _ns.containsVariable(name, true) ? v : getImplicit(name);\n}\n"
|
"public void testMoreThanOneAuthMechDoesNotRegisterProvider() throws Exception {\n final Bean<HttpAuthenticationMechanism> httpAuthenticationMechanismBean1 = mockery.mock(Bean.class, \"String_Node_Str\");\n final Bean<HttpAuthenticationMechanism> httpAuthenticationMechanismBean2 = mockery.mock(Bean.class, \"String_Node_Str\");\n httpAuthMechs.add(httpAuthenticationMechanismBean1);\n httpAuthMechs.add(httpAuthenticationMechanismBean2);\n withNoCachedProvider().withBeanManager().doesNotRegisterProvider();\n bridgeBuilder.buildBridgeIfNeeded(APP_CONTEXT, providerFactory);\n}\n"
|
"public void run() {\n synchronized (ImageIcon.this) {\n Toolkit tk = Toolkit.getDefaultToolkit();\n int width = _image.getWidth(ImageIcon.this);\n int height = _image.getHeight(ImageIcon.this);\n if (width < 0 || height < 0) {\n return;\n }\n int newWidth = (int) Math.round((width * _scalePercentage) / 100.0);\n int newHeight = (int) Math.round((height * _scalePercentage) / 100.0);\n _scaledImage = _image.getScaledInstance(newWidth, newHeight, Image.SCALE_SMOOTH);\n _scalePercentageImplemented = _scalePercentage;\n if (tk.prepareImage(_scaledImage, width, height, ImageIcon.this)) {\n _updateFigures();\n }\n }\n}\n"
|
"private void extractArguments(Node callNode, ScriptOrFnNode tree, List columnExprList) throws BirtException {\n Node arg = callNode.getFirstChild().getNext();\n while (arg != null) {\n Node nextArg = arg.getNext();\n processChild(arg, tree, columnExprList);\n arg = nextArg;\n }\n}\n"
|
"private MultiRateLimiter newRateLimiter(final List<Long> epochsInSeconds, final List<Integer> limits, final long windowLowerBound, final long windowUpperBound) {\n final Map<String, AbstractRateLimiter> limiters = new HashMap<>();\n for (int i = 0; i < epochsInSeconds.size(); i++) {\n try {\n final AbstractRateLimiter limiter = limitingType.getLimiterClass().getConstructor(int.class, long.class, TimeUnit.class).newInstance(limits.get(i), epochsInSeconds.get(i), TimeUnit.SECONDS);\n final long windowLockoutIn = Math.max(0, TimeUnit.SECONDS.toMillis(epochsInSeconds.get(i)) + windowLowerBound - System.currentTimeMillis());\n limiter.restrict(windowLockoutIn, TimeUnit.MILLISECONDS, windowUpperBound - windowLowerBound, TimeUnit.MILLISECONDS);\n limiter.acquire();\n limiter.release();\n limiters.put(epochsInSeconds.get(i).toString(), limiter);\n } catch (InstantiationException | IllegalAccessException | IllegalArgumentException | InvocationTargetException | NoSuchMethodException | SecurityException e) {\n LOGGER.error(\"String_Node_Str\" + limitingType + \"String_Node_Str\", e);\n throw new OriannaException(\"String_Node_Str\" + limitingType + \"String_Node_Str\", e);\n }\n }\n return new MultiRateLimiter(limiters);\n}\n"
|
"protected void createTableViewer(Composite parent) {\n viewer = new PropertyHandleTableViewer(parent, true, true, true) {\n protected void doRemove() {\n int index = viewer.getTable().getSelectionIndex();\n PropertyHandle handle = (PropertyHandle) viewer.getInput();\n int count = (handle.getListValue() == null) ? 0 : handle.getListValue().size();\n if (index > -1 && index < count) {\n ComputedColumnHandle computedColumn = (ComputedColumnHandle) viewer.getTable().getItems()[index].getData();\n removeColumnHint(computedColumn.getName());\n try {\n handle.removeItem(index);\n } catch (PropertyValueException e1) {\n ExceptionHandler.handle(e1);\n }\n viewer.refresh();\n viewer.getTable().setFocus();\n viewer.getTable().select(index);\n updateButtons();\n }\n }\n private void removeColumnHint(String columnName) {\n if (columnName == null)\n return;\n PropertyHandle propertyHandle = ((DataSetHandle) getContainer().getModel()).getPropertyHandle(DataSetHandle.COLUMN_HINTS_PROP);\n Iterator iter = propertyHandle.iterator();\n while (iter.hasNext()) {\n ColumnHintHandle hint = (ColumnHintHandle) iter.next();\n if (columnName.equals(hint.getColumnName())) {\n try {\n propertyHandle.removeItem(hint);\n } catch (PropertyValueException e) {\n ExceptionHandler.handle(e);\n }\n }\n }\n }\n };\n TableColumn column = new TableColumn(viewer.getViewer().getTable(), SWT.LEFT);\n column.setText(cellLabels[COLUMN_NAME_INDEX]);\n column.setWidth(150);\n column = new TableColumn(viewer.getViewer().getTable(), SWT.LEFT);\n column.setText(cellLabels[DATA_TYPE_INDEX]);\n column.setWidth(200);\n column = new TableColumn(viewer.getViewer().getTable(), SWT.LEFT);\n column.setText(cellLabels[EXPRESSION_INDEX]);\n column.setWidth(200);\n column = new TableColumn(viewer.getViewer().getTable(), SWT.LEFT);\n column.setText(cellLabels[AGGREGATION_INDEX]);\n column.setWidth(200);\n column = new TableColumn(viewer.getViewer().getTable(), SWT.LEFT);\n column.setText(cellLabels[FILTER_INDEX]);\n column.setWidth(200);\n viewer.getViewer().setContentProvider(new IStructuredContentProvider() {\n public Object[] getElements(Object inputElement) {\n ArrayList computedColumnsList = new ArrayList(10);\n Iterator iter = computedColumns.iterator();\n if (iter != null) {\n while (iter.hasNext()) {\n computedColumnsList.add(iter.next());\n }\n }\n return computedColumnsList.toArray();\n }\n public void dispose() {\n }\n public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {\n }\n });\n viewer.getViewer().setLabelProvider(new TableProvider());\n viewer.getViewer().setInput(computedColumns);\n}\n"
|
"private Map<Date, BigDecimal> overhead(Connection connection) throws SQLException {\n PreparedStatement s = connection.prepareStatement(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\");\n try {\n s.setInt(1, days);\n s.setInt(2, sarariman.getPaidTimeOff().getPaidTimeOffTask().getId());\n ResultSet r = s.executeQuery();\n try {\n ImmutableSortedMap.Builder<Date, BigDecimal> mapBuilder = ImmutableSortedMap.<Date, BigDecimal>naturalOrder();\n while (r.next()) {\n Date date = r.getDate(\"String_Node_Str\");\n BigDecimal total = r.getBigDecimal(\"String_Node_Str\");\n mapBuilder.put(date, total);\n }\n return mapBuilder.build();\n } finally {\n r.close();\n }\n } finally {\n s.close();\n }\n}\n"
|
"public Packet decode(ByteBuf byteBuf) {\n String locale;\n try {\n locale = ByteBufUtils.readUTF8(byteBuf);\n } catch (IOException e) {\n logger.error(e.getMessage());\n locale = \"String_Node_Str\";\n }\n final byte viewDistance = byteBuf.readByte();\n ChatMode chatMode;\n try {\n chatMode = ChatMode.fromModeID(ByteBufUtils.readVarInt(byteBuf));\n } catch (IOException e) {\n e.printStackTrace();\n chatMode = ChatMode.ENABLED;\n }\n final boolean chatColors = byteBuf.readBoolean();\n final DisplayedSkinParts[] displayedSkinParts = DisplayedSkinParts.fromBitMask(byteBuf.readByte());\n MainHand mainHand;\n try {\n mainHand = MainHand.fromHandID(ByteBufUtils.readVarInt(byteBuf));\n } catch (IOException e) {\n e.printStackTrace();\n mainHand = MainHand.RIGHT;\n }\n return new ClientSettingsPacket(locale, viewDistance, chatMode, chatColors, displayedSkinParts, mainHand);\n}\n"
|
"public long getKeepAliveDuration(HttpResponse response, HttpContext context) {\n return HttpManager.this.getKeepAliveDuration(response);\n}\n"
|
"public Set<Element> getConstrainingElements() {\n if (constrainingElements == null) {\n constrainingElements = new LinkedHashSet<Element>();\n }\n if (type == Type.ANY)\n return constrainingElements;\n Set<Element> filtered = new LinkedHashSet<Element>();\n for (Element c : constrainingElements) {\n if (constraintIsType(c, type)) {\n filtered.add(c);\n }\n }\n return filtered;\n}\n"
|
"private void append(ID fromID, String body) {\n if (!isFirstMessage) {\n chatText.append(Text.DELIMITER);\n }\n int length = chatText.getCharCount();\n String name = getUserName(fromID);\n if (fromID.equals(remoteID)) {\n if (showTimestamps) {\n chatText.append(FORMATTER.format(new Date(System.currentTimeMillis())) + ' ');\n chatText.setStyleRange(new StyleRange(length, 13, redColor, null));\n length = chatText.getCharCount();\n }\n chatText.append(name + \"String_Node_Str\" + body);\n chatText.setStyleRange(new StyleRange(length, name.length() + 1, redColor, null, SWT.BOLD));\n notificationLabel.setText(\"String_Node_Str\");\n if (isFirstMessage) {\n final MessageNotificationPopup popup = new MessageNotificationPopup(getSite().getWorkbenchWindow(), tabFolder.getShell(), remoteID);\n popup.setContent(name, body);\n popup.open();\n new UIJob(tabFolder.getDisplay(), \"String_Node_Str\") {\n public IStatus runInUIThread(IProgressMonitor monitor) {\n Shell shell = popup.getShell();\n if (shell != null && !shell.isDisposed()) {\n popup.close();\n }\n return Status.OK_STATUS;\n }\n }.schedule(5000);\n }\n } else {\n if (showTimestamps) {\n chatText.append(FORMATTER.format(new Date(System.currentTimeMillis())) + ' ');\n chatText.setStyleRange(new StyleRange(length, 13, blueColor, null));\n length = chatText.getCharCount();\n }\n chatText.append(name + \"String_Node_Str\" + body);\n chatText.setStyleRange(new StyleRange(length, name.length() + 1, blueColor, null, SWT.BOLD));\n }\n isFirstMessage = false;\n chatText.invokeAction(ST.PAGE_DOWN);\n}\n"
|
"public void readValues(DataRead dr) throws BasicException {\n m_sTicket = dr.getString(1);\n m_iLine = dr.getInt(2).intValue();\n productid = dr.getString(3);\n attsetinstid = dr.getString(4);\n multiply = dr.getDouble(5);\n price = dr.getDouble(6);\n tax = new TaxInfo(dr.getString(7), dr.getString(8), dr.getString(9), dr.getTimestamp(10), dr.getString(11), dr.getString(12), dr.getDouble(13), dr.getBoolean(14), dr.getInt(15));\n attributes = new Properties();\n try {\n byte[] img = dr.getBytes(16);\n if (img != null) {\n attributes.loadFromXML(new ByteArrayInputStream(img));\n }\n } catch (IOException e) {\n }\n}\n"
|
"public static IOReadableWritable createCopy(IOReadableWritable original) throws IOException {\n final ByteArrayOutputStream baos = new ByteArrayOutputStream();\n final DataOutputStream dos = new DataOutputStream(baos);\n original.write(dos);\n final String className = original.getClass().getName();\n if (className == null) {\n fail(\"String_Node_Str\");\n }\n Class<T> clazz = null;\n try {\n clazz = (Class<? extends IOReadableWritable>) Class.forName(className);\n } catch (ClassNotFoundException e) {\n fail(e.getMessage());\n }\n if (clazz == null) {\n fail(\"String_Node_Str\" + className);\n }\n IOReadableWritable copy = null;\n try {\n copy = clazz.newInstance();\n } catch (InstantiationException e) {\n fail(e.getMessage());\n } catch (IllegalAccessException e) {\n fail(e.getMessage());\n }\n if (copy == null) {\n fail(\"String_Node_Str\" + className + \"String_Node_Str\");\n }\n final ByteArrayInputStream bais = new ByteArrayInputStream(baos.toByteArray());\n final DataInputStream dis = new DataInputStream(bais);\n copy.read(dis);\n return copy;\n}\n"
|
"private Schema keySchema(ExhibitDescriptor descriptor) {\n List<Schema.Field> keyFields = Lists.newArrayList();\n ObsDescriptor od = descriptor.attributes();\n for (String attr : config.attrs) {\n ObsDescriptor.Field f = od.get(od.indexOf(attr));\n keyFields.add(AvroExhibit.getSchemaField(f));\n }\n List<Schema> frameKeySchemas = Lists.newArrayList();\n for (int i = 0; i < config.keys.size(); i++) {\n frameKeySchemas.add(null);\n }\n for (AggConfig ac : config.aggregates) {\n ObsDescriptor fd = ac.getFrameDescriptor(descriptor);\n for (int i = 0; i < ac.keys.size(); i++) {\n ObsDescriptor.Field f = fd.get(fd.indexOf(ac.keys.get(i)));\n Schema s = AvroExhibit.getSchema(f.type);\n if (frameKeySchemas.get(i) == null) {\n frameKeySchemas.set(i, s);\n } else if (!frameKeySchemas.get(i).equals(s)) {\n throw new IllegalStateException(\"String_Node_Str\");\n }\n }\n }\n for (int i = 0; i < config.keys.size(); i++) {\n keyFields.add(new Schema.Field(config.keys.get(i), frameKeySchemas.get(i), \"String_Node_Str\", null));\n }\n Schema wrapper = Schema.createRecord(\"String_Node_Str\" + id, \"String_Node_Str\", \"String_Node_Str\", false);\n wrapper.setFields(keyFields);\n return wrapper;\n}\n"
|
"public boolean equalsAsOption(PossibleAction pa) {\n if (pa == this)\n return true;\n if (!super.equalsAsOption(pa))\n return false;\n BuyCertificate action = (BuyCertificate) pa;\n return Objects.equal(this.company, action.company) && Objects.equal(this.from, action.from) && Objects.equal(this.maximumNumber, action.maximumNumber);\n}\n"
|
"public static boolean checkCC(String cardNumber) {\n int sum = 0;\n if (!StringUtils.isNumber(cardNumber)) {\n return false;\n }\n for (int i = cardNumber.length() - 1; i >= 0; i--) {\n int k = Character.digit(cardNumber.charAt(i), 10);\n flip++;\n if (flip % 2 == 0) {\n k *= 2;\n if (k > 9) {\n k -= 9;\n }\n }\n sum += k;\n }\n return (sum % 10 == 0);\n}\n"
|
"protected void visitCallParamContentNode(CallParamContentNode node) {\n visitRenderUnitNode(node);\n}\n"
|
"public boolean isOnIsland(final Player owner, final Player target) {\n if (target.getWorld().equals(ASkyBlock.getIslandWorld()) || (Settings.newNether && Settings.createNether && target.getWorld().equals(ASkyBlock.getNetherWorld()))) {\n Location islandTestLocation = null;\n if (plugin.getPlayers().inTeam(owner.getUniqueId())) {\n if (plugin.getPlayers().getMembers(plugin.getPlayers().getTeamLeader(owner.getUniqueId())).contains(target.getUniqueId())) {\n return false;\n }\n islandTestLocation = plugin.getPlayers().getTeamIslandLocation(owner.getUniqueId());\n } else {\n islandTestLocation = plugin.getPlayers().getIslandLocation(owner.getUniqueId());\n }\n if (islandTestLocation == null) {\n return false;\n }\n int protectionRange = Settings.islandProtectionRange;\n if (getIslandAt(islandTestLocation) != null) {\n Island island = getProtectedIslandAt(islandTestLocation);\n if (island != null) {\n protectionRange = island.getProtectionSize();\n }\n }\n if (target.getLocation().getX() > islandTestLocation.getX() - protectionRange / 2D && target.getLocation().getX() < islandTestLocation.getX() + protectionRange / 2D && target.getLocation().getZ() > islandTestLocation.getZ() - protectionRange / 2D && target.getLocation().getZ() < islandTestLocation.getZ() + protectionRange / 2D) {\n return true;\n }\n }\n return false;\n}\n"
|
"public void addFileToScan(final String fileName) {\n if (!fParentFiles.containsKey(fileName)) {\n fParentFiles.put(fileName, new HashSet<String>());\n startUpdateTask(Messages.BatchImportTraceWizard_add + ' ' + fileName, fileName);\n }\n}\n"
|
"protected ContextComposite addContextFields(Composite parentComposite) {\n contextHandler = new GenericContextHandler();\n contextHandler.setParameters(getContextParameters());\n ContextComposite contextComp = new ContextComposite(parentComposite, connectionItem, !isRepositoryObjectEditable, contextHandler);\n return contextComp;\n}\n"
|
"public static void main(String[] args) throws Exception {\n NAR n = new DefaultNARBuilder().setConceptBagSize(8192).setTermLinkBagLevels(8).setTaskLinkBagLevels(8).build();\n n.start(0);\n new XMLInput(n, \"String_Node_Str\", \"String_Node_Str\");\n}\n"
|
"public Value next() throws IOException, InterruptedException {\n if (bufferIdx < VALUE_BUFFER_SIZE) {\n return valBuffer[bufferIdx++];\n } else {\n Value nextVal = values.next();\n copyKey = keySerialization.newInstance();\n keyCopier.getCopy(copyKey);\n copyVal = valSerialization.newInstance();\n valCopier.getCopy(copyVal);\n nextValCopier.setCopy(nextVal);\n copyNextVal = valSerialization.newInstance();\n nextValCopier.getCopy(copyNextVal);\n stub.match(copyKey, copyVal, copyNextVal, out);\n return nextVal;\n }\n}\n"
|
"public void map(final NullWritable key, final FaunusVertex value, final Mapper<NullWritable, FaunusVertex, Text, LongWritable>.Context context) throws IOException, InterruptedException {\n long counter = 0;\n for (final Edge edge : value.getEdges(this.direction)) {\n counter++;\n final String label = edge.getLabel();\n final Long count = this.map.get(label);\n if (null == count)\n map.put(label, 1l);\n else\n map.put(label, count + 1l);\n }\n context.getCounter(Counters.VERTICES_COUNTED).increment(1);\n context.getCounter(Counters.EDGES_COUNTED).increment(counter);\n}\n"
|
"public void printBanner(Environment environment, Class<?> sourceClass, PrintStream out) {\n for (String line : BANNER) {\n out.println(line);\n }\n String version = this.getClass().getPackage().getImplementationVersion();\n version = environment.getProperty(\"String_Node_Str\");\n if (version == null || version.equals(\"String_Node_Str\")) {\n Manifest manifest = getManifest(this.getClass());\n version = manifest.getMainAttributes().getValue(\"String_Node_Str\");\n }\n version = (version == null ? \"String_Node_Str\" : \"String_Node_Str\" + version + \"String_Node_Str\");\n String padding = \"String_Node_Str\";\n while (padding.length() < STRAP_LINE_SIZE - (version.length() + VIREO_BOOT.length())) {\n padding += \"String_Node_Str\";\n }\n out.println(AnsiOutput.toString(AnsiElement.GREEN, VIREO_BOOT, AnsiElement.DEFAULT, padding, AnsiElement.FAINT, version));\n out.println();\n}\n"
|
"public static SqlStorage<FormDefRecord> getFormDefStorage() {\n if (sFormDefStorage == null) {\n sFormDefStorage = CommCareApplication.instance().getAppStorage(FormDefRecord.class);\n }\n return sFormDefStorage;\n}\n"
|
"protected Roster getRoster() throws IOException {\n final ECFConnection connection = getECFConnection();\n if (connection != null) {\n return connection.getRoster();\n } else\n return null;\n}\n"
|
"public Calendar getModelValue(Long data) {\n if (data != null) {\n Calendar calendar = Calendar.getInstance();\n calendar.setTimeInMillis(data);\n return calendar;\n } else {\n return null;\n }\n}\n"
|
"public AtlasGlossaryCategory createCategory(AtlasGlossaryCategory glossaryCategory) throws AtlasBaseException {\n if (DEBUG_ENABLED) {\n LOG.debug(\"String_Node_Str\", glossaryCategory);\n }\n if (Objects.isNull(glossaryCategory)) {\n throw new AtlasBaseException(AtlasErrorCode.BAD_REQUEST, \"String_Node_Str\");\n }\n if (Objects.isNull(glossaryCategory.getAnchor())) {\n throw new AtlasBaseException(AtlasErrorCode.MISSING_MANDATORY_ANCHOR);\n }\n if (StringUtils.isEmpty(glossaryCategory.getQualifiedName())) {\n if (StringUtils.isEmpty(glossaryCategory.getDisplayName())) {\n throw new AtlasBaseException(AtlasErrorCode.GLOSSARY_CATEGORY_QUALIFIED_NAME_CANT_BE_DERIVED);\n }\n if (isNameInvalid(glossaryCategory.getDisplayName())) {\n throw new AtlasBaseException(AtlasErrorCode.INVALID_DISPLAY_NAME);\n } else {\n glossaryCategory.setQualifiedName(glossaryCategory.getDisplayName());\n }\n }\n if (categoryExists(glossaryCategory)) {\n throw new AtlasBaseException(AtlasErrorCode.GLOSSARY_CATEGORY_ALREADY_EXISTS, glossaryCategory.getQualifiedName());\n }\n AtlasGlossaryCategory storeObject = dataAccess.save(glossaryCategory);\n Map<String, AtlasGlossaryCategory> impactedCategories = glossaryCategoryUtils.processCategoryRelations(storeObject, glossaryCategory, GlossaryUtils.RelationshipOperation.CREATE);\n dataAccess.save(impactedCategories.values());\n if (StringUtils.equals(glossaryCategory.getQualifiedName(), storeObject.getQualifiedName())) {\n storeObject = dataAccess.load(glossaryCategory);\n } else {\n glossaryCategory.setQualifiedName(storeObject.getQualifiedName());\n storeObject = dataAccess.save(glossaryCategory);\n } else {\n storeObject = dataAccess.load(glossaryCategory);\n }\n setInfoForRelations(storeObject);\n if (DEBUG_ENABLED) {\n LOG.debug(\"String_Node_Str\", storeObject);\n }\n return storeObject;\n}\n"
|
"protected void doOpen() {\n JmsDestination destination = info.getDestination();\n String destnationName = session.getQualifiedName(destination);\n String sourceAddress = getProducerId().toString();\n Source source = new Source();\n source.setAddress(sourceAddress);\n Target target = new Target();\n target.setAddress(destnationName);\n String senderName = sourceAddress + \"String_Node_Str\" + destnationName;\n endpoint = session.getProtonSession().sender(senderName);\n endpoint.setSource(source);\n endpoint.setTarget(target);\n if (presettle) {\n endpoint.setSenderSettleMode(SenderSettleMode.SETTLED);\n } else {\n endpoint.setSenderSettleMode(SenderSettleMode.UNSETTLED);\n }\n endpoint.setReceiverSettleMode(ReceiverSettleMode.FIRST);\n}\n"
|
"public static Map<String, Set<String>> getJMSChanges(Project project) {\n Map<String, Set<String>> changes = new HashMap<String, Set<String>>();\n Set<String> changedIds = new HashSet<String>();\n Set<String> deletedIds = new HashSet<String>();\n Set<String> addedIds = new HashSet<String>();\n changes.put(\"String_Node_Str\", changedIds);\n changes.put(\"String_Node_Str\", deletedIds);\n changes.put(\"String_Node_Str\", addedIds);\n Map<String, Object> projectInstances = ProjectListenerMapping.getInstance().get(project);\n if (projectInstances.containsKey(CONNECTION) || projectInstances.containsKey(SESSION) || projectInstances.containsKey(CONSUMER)) {\n Application.getInstance().getGUILog().log(\"String_Node_Str\");\n return null;\n }\n String projectID = ExportUtility.getProjectId(project);\n String wsID = ExportUtility.getWorkspace();\n Map<String, String> urlInfo = new HashMap<String, String>();\n getJMSUrl(urlInfo);\n String url = urlInfo.get(\"String_Node_Str\");\n if (url == null) {\n Application.getInstance().getGUILog().log(\"String_Node_Str\");\n return null;\n }\n if (wsID == null) {\n Application.getInstance().getGUILog().log(\"String_Node_Str\");\n return null;\n }\n Connection connection = null;\n Session session = null;\n MessageConsumer consumer = null;\n JSONObject previousFailed = getUpdatesOrFailed(project, \"String_Node_Str\");\n if (previousFailed != null) {\n addedIds.addAll((List<String>) previousFailed.get(\"String_Node_Str\"));\n deletedIds.addAll((List<String>) previousFailed.get(\"String_Node_Str\"));\n changedIds.addAll((List<String>) previousFailed.get(\"String_Node_Str\"));\n }\n JSONObject previousConflicts = getConflicts(project);\n if (previousConflicts != null) {\n changedIds.addAll((List<String>) previousConflicts.get(\"String_Node_Str\"));\n }\n try {\n ConnectionFactory connectionFactory = createConnectionFactory(urlInfo);\n String subscriberId = projectID + \"String_Node_Str\" + wsID;\n connection = connectionFactory.createConnection();\n connection.setClientID(subscriberId);\n session = connection.createSession(false, Session.CLIENT_ACKNOWLEDGE);\n Topic topic = null;\n try {\n topic = (Topic) ctx.lookup(JMS_TOPIC);\n } catch (NameNotFoundException nnfe) {\n topic = session.createTopic(JMS_TOPIC);\n }\n String messageSelector = constructSelectorString(projectID, wsID);\n consumer = session.createDurableSubscriber(topic, subscriberId, messageSelector, true);\n connection.start();\n Message m = consumer.receive(1000);\n while (m != null) {\n TextMessage message = (TextMessage) m;\n log.info(\"String_Node_Str\" + message.getText());\n JSONObject ob = (JSONObject) JSONValue.parse(message.getText());\n boolean magicdraw = false;\n if (ob.get(\"String_Node_Str\") != null && ob.get(\"String_Node_Str\").equals(\"String_Node_Str\")) {\n magicdraw = true;\n }\n JSONObject ws2 = (JSONObject) ob.get(\"String_Node_Str\");\n final JSONArray updated = (JSONArray) ws2.get(\"String_Node_Str\");\n final JSONArray added = (JSONArray) ws2.get(\"String_Node_Str\");\n final JSONArray deleted = (JSONArray) ws2.get(\"String_Node_Str\");\n final JSONArray moved = (JSONArray) ws2.get(\"String_Node_Str\");\n for (Object e : updated) {\n String id = (String) ((JSONObject) e).get(\"String_Node_Str\");\n if (!magicdraw)\n changedIds.add(id);\n deletedIds.remove(id);\n }\n for (Object e : added) {\n String id = (String) ((JSONObject) e).get(\"String_Node_Str\");\n if (!magicdraw)\n addedIds.add(id);\n deletedIds.remove(id);\n }\n for (Object e : moved) {\n String id = (String) ((JSONObject) e).get(\"String_Node_Str\");\n if (!magicdraw)\n changedIds.add(id);\n deletedIds.remove(id);\n }\n for (Object e : deleted) {\n String id = (String) ((JSONObject) e).get(\"String_Node_Str\");\n if (!magicdraw)\n deletedIds.add(id);\n addedIds.remove(id);\n changedIds.remove(id);\n }\n m.acknowledge();\n m = consumer.receive(1000);\n }\n SessionManager sm = SessionManager.getInstance();\n sm.createSession(\"String_Node_Str\");\n try {\n setConflicts(project, null);\n sm.closeSession();\n } catch (Exception e) {\n sm.cancelSession();\n }\n return changes;\n } catch (Exception e) {\n log.error(\"String_Node_Str\", e);\n Application.getInstance().getGUILog().log(\"String_Node_Str\" + e.getMessage());\n return null;\n } finally {\n try {\n if (consumer != null)\n consumer.close();\n if (session != null)\n session.close();\n if (connection != null)\n connection.close();\n } catch (JMSException e) {\n }\n }\n}\n"
|
"public Object resolve(URI baseUri, URI uri) {\n URI relativeUri = baseUri.relativize(uri);\n Stack<URI> uris = UriUtils.explode(baseUri, relativeUri);\n if (uris.size() < 1) {\n return null;\n }\n String repoName = UriUtils.path(uris.get(0));\n String sId = UriUtils.path(uris.get(1));\n RepositoryMetadata repoMeta = repositoryMetadataFor(repoName);\n CrudRepository repo;\n if (null == (repo = repoMeta.repository())) {\n return null;\n }\n EntityMetadata entityMeta;\n if (null == (entityMeta = repoMeta.entityMetadata())) {\n return null;\n }\n Class<? extends Serializable> idType = (Class<? extends Serializable>) entityMeta.idAttribute().type();\n Serializable serId = null;\n if (ClassUtils.isAssignable(idType, String.class)) {\n serId = sId;\n } else {\n serId = conversionService.convert(sId, idType);\n }\n return repo.findOne(serId);\n}\n"
|
"public static void main(String[] args) {\n try {\n Workbench w = new Workbench();\n w.parseArgs(args);\n w.setSize(800, 600);\n if (w.openFile != null) {\n File f = new File(w.openFile);\n if (f.canRead()) {\n w.openSchemaFrame(f.getAbsoluteFile(), false);\n }\n }\n w.setVisible(true);\n } catch (Throwable ex) {\n LOGGER.error(\"String_Node_Str\", ex);\n }\n}\n"
|
"public void removeLocalTempTableIndex(Index index) throws SQLException {\n if (localTempTableIndexes != null) {\n localTempTableIndexes.remove(index.getName());\n synchronized (database) {\n index.removeChildrenAndResources(this);\n }\n }\n}\n"
|
"public void run() {\n try {\n barrier.await();\n try (JournalWriter w = wf.writer(m)) {\n if (w != null) {\n writerCount.incrementAndGet();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n errors.incrementAndGet();\n } finally {\n halt.countDown();\n }\n}\n"
|
"public Map<String, Object> getAttributes() {\n if (attributes == null)\n attributes = new AttributeMapWrapper(this, super.getAttributes());\n return attributes;\n}\n"
|
"protected int getMaximumValueForSet(long instant, int value) {\n int maxLessOne = iChronology.getDaysInYearMax() - 1;\n return (value > maxLessOne || value < 1) ? getMaximumValue(instant) : maxLessOne;\n}\n"
|
"final void moveTaskToFrontLocked(TaskRecord tr, boolean noAnimation, Bundle options, String reason) {\n if (DEBUG_SWITCH)\n Slog.v(TAG_SWITCH, \"String_Node_Str\" + tr);\n final int numTasks = mTaskHistory.size();\n final int index = mTaskHistory.indexOf(tr);\n if (numTasks == 0 || index < 0) {\n if (noAnimation) {\n ActivityOptions.abort(options);\n } else {\n updateTransitLocked(AppTransition.TRANSIT_TASK_TO_FRONT, options);\n }\n return;\n }\n insertTaskAtTop(tr, null);\n ActivityRecord r = topRunningActivityLocked(null);\n mService.setFocusedActivityLocked(r, reason);\n if (DEBUG_TRANSITION)\n Slog.v(TAG_TRANSITION, \"String_Node_Str\" + tr);\n if (noAnimation) {\n mWindowManager.prepareAppTransition(AppTransition.TRANSIT_NONE, false);\n if (r != null) {\n mNoAnimActivities.add(r);\n }\n ActivityOptions.abort(options);\n } else {\n updateTransitLocked(AppTransition.TRANSIT_TASK_TO_FRONT, options);\n }\n mStackSupervisor.resumeTopActivitiesLocked();\n EventLog.writeEvent(EventLogTags.AM_TASK_TO_FRONT, tr.userId, tr.taskId);\n if (VALIDATE_TOKENS) {\n validateAppTokensLocked();\n }\n}\n"
|
"public HashMap<Profile, HashMap<ProjectVersionRef, Dependency>> getResolvedProfileManagedDependencies(MavenSessionHandler session) throws ManipulationException {\n if (resolvedProfileManagedDependencies == null) {\n resolvedProfileManagedDependencies = new HashMap<>();\n for (final Profile profile : ProfileUtils.getProfiles(session, model)) {\n HashMap<ArtifactRef, Dependency> profileDeps = new HashMap<>();\n final DependencyManagement dm = profile.getDependencyManagement();\n if (!(dm == null || dm.getDependencies() == null)) {\n resolveDeps(session, dm.getDependencies(), profileDeps);\n resolvedProfileManagedDependencies.put(profile, profileDeps);\n }\n }\n }\n return resolvedProfileManagedDependencies;\n}\n"
|
"private static void writeFeature(Writer w, SequenceAnnotation sa, String role, int offset, boolean inline) throws IOException, SBOLConversionException {\n if (sa.getPreciseLocations().size() == 0) {\n throw new SBOLConversionException(\"String_Node_Str\" + sa.getIdentity() + \"String_Node_Str\");\n } else if (sa.getPreciseLocations().size() == 1) {\n Location loc = sa.getPreciseLocations().iterator().next();\n boolean locReverse = false;\n if (loc.isSetOrientation()) {\n locReverse = loc.getOrientation().equals(OrientationType.REVERSECOMPLEMENT);\n }\n w.write(\"String_Node_Str\" + role + \"String_Node_Str\" + locationStr(loc, offset, ((inline && locReverse) || (!inline && !locReverse)), null) + \"String_Node_Str\");\n } else if (stradlesOrigin(sa)) {\n Location loc = sa.getLocation(\"String_Node_Str\");\n Location loc2 = sa.getLocation(\"String_Node_Str\");\n boolean locReverse = false;\n if (loc.isSetOrientation()) {\n locReverse = loc.getOrientation().equals(OrientationType.REVERSECOMPLEMENT);\n }\n w.write(\"String_Node_Str\" + role + \"String_Node_Str\" + locationStr(loc, offset, ((inline && locReverse) || (!inline && !locReverse)), loc2) + \"String_Node_Str\");\n } else {\n String multiType = \"String_Node_Str\";\n Annotation annotation = sa.getAnnotation(new QName(GBNAMESPACE, MULTIRANGETYPE, GBCONVPREFIX));\n if (annotation != null) {\n multiType = annotation.getStringValue();\n }\n String rangeStr = \"String_Node_Str\" + role + \"String_Node_Str\" + multiType + \"String_Node_Str\";\n boolean first = true;\n for (Location loc : sa.getSortedLocations()) {\n if (!first)\n rangeStr += \"String_Node_Str\";\n else\n first = false;\n boolean locReverse = false;\n if (loc.isSetOrientation()) {\n locReverse = loc.getOrientation().equals(OrientationType.REVERSECOMPLEMENT);\n }\n rangeStr += locationStr(loc, offset, ((inline && locReverse) || (!inline && !locReverse)), null);\n }\n rangeStr += \"String_Node_Str\";\n writeGenBankLine(w, rangeStr, 80, 21);\n }\n for (Annotation a : sa.getAnnotations()) {\n if (a.getQName().getLocalPart().equals(\"String_Node_Str\"))\n continue;\n if (a.isStringValue()) {\n writeGenBankLine(w, \"String_Node_Str\" + a.getQName().getLocalPart() + \"String_Node_Str\" + a.getStringValue(), 80, 21);\n }\n }\n}\n"
|
"public GameProfile getProfile(String name) {\n String playername = name.toLowerCase(Locale.ROOT);\n UserCacheEntry entry = stringToProfile.get(playername);\n if (entry != null && entry.isExpired()) {\n stringToProfile.remove(playername);\n uuidToProfile.remove(entry.getProfile().getId());\n return null;\n }\n if (entry != null) {\n uuidToProfile.get(entry.getProfile().getId());\n return entry.getProfile();\n } else {\n GameProfile profile = lookupProfile(MinecraftServer.getServer(), playername);\n if (profile != null) {\n a(profile);\n return profile;\n }\n return null;\n }\n}\n"
|
"private BitmapIndexReader createBitmapIndexReaderAt(int globalIndex, int columnBase, int columnIndex, int direction) {\n BitmapIndexReader reader;\n if (!metadata.isColumnIndexed(columnIndex)) {\n throw CairoException.instance(0).put(\"String_Node_Str\").put(metadata.getColumnName(columnIndex));\n }\n ReadOnlyColumn col = columns.getQuick(globalIndex);\n if (col instanceof NullColumn) {\n if (direction == BitmapIndexReader.DIR_BACKWARD) {\n reader = new BitmapIndexBwdNullReader();\n bitmapIndexes.setQuick(globalIndex, reader);\n } else {\n reader = new BitmapIndexForwardNullReader();\n bitmapIndexes.setQuick(globalIndex + 1, reader);\n }\n } else {\n Path path = partitionPathGenerator.generate(this, getPartitionIndex(columnBase));\n try {\n if (direction == BitmapIndexReader.DIR_BACKWARD) {\n reader = new BitmapIndexBackwardReader(configuration, path.chopZ(), metadata.getColumnName(columnIndex), getColumnTop(columnBase, columnIndex));\n bitmapIndexes.setQuick(globalIndex, reader);\n } else {\n reader = new BitmapIndexForwardReader(configuration, path.chopZ(), metadata.getColumnName(columnIndex), getColumnTop(columnBase, columnIndex));\n bitmapIndexes.setQuick(globalIndex + 1, reader);\n }\n } finally {\n path.trimTo(rootLen);\n }\n }\n return reader;\n}\n"
|
"private void updateScreen() {\n if (VDBG)\n log(\"String_Node_Str\");\n if (!mIsForegroundActivity) {\n if (VDBG)\n log(\"String_Node_Str\");\n return;\n }\n if (mInCallMenu != null) {\n if (VDBG)\n log(\"String_Node_Str\");\n boolean okToShowMenu = mInCallMenu.updateItems(mPhone);\n if (!okToShowMenu) {\n if (VDBG)\n log(\"String_Node_Str\");\n dismissMenu(true);\n }\n }\n final PhoneApp app = PhoneApp.getInstance();\n if (mInCallScreenMode == InCallScreenMode.OTA_NORMAL) {\n if (VDBG)\n log(\"String_Node_Str\");\n if (otaUtils != null) {\n if (VDBG)\n log(\"String_Node_Str\");\n otaUtils.otaShowProperScreen();\n }\n return;\n } else if (mInCallScreenMode == InCallScreenMode.OTA_ENDED) {\n if (VDBG)\n log(\"String_Node_Str\");\n if (app.cdmaOtaScreenState.otaScreenState == CdmaOtaScreenState.OtaScreenState.OTA_STATUS_ACTIVATION) {\n if (VDBG)\n log(\"String_Node_Str\");\n if (otaUtils != null) {\n if (VDBG)\n log(\"String_Node_Str\" + \"String_Node_Str\");\n otaUtils.otaShowActivateScreen();\n }\n } else {\n if (VDBG)\n log(\"String_Node_Str\");\n if (otaUtils != null) {\n if (VDBG)\n log(\"String_Node_Str\");\n otaUtils.otaShowSuccessFailure();\n }\n }\n return;\n } else if (mInCallScreenMode == InCallScreenMode.MANAGE_CONFERENCE) {\n if (VDBG)\n log(\"String_Node_Str\");\n updateManageConferencePanelIfNecessary();\n return;\n } else if (mInCallScreenMode == InCallScreenMode.CALL_ENDED) {\n if (VDBG)\n log(\"String_Node_Str\");\n updateInCallPanelBackground();\n return;\n }\n if (VDBG)\n log(\"String_Node_Str\");\n mCallCard.updateState(mPhone);\n updateDialpadVisibility();\n updateInCallTouchUi();\n updateMenuButtonHint();\n updateInCallPanelBackground();\n if (!mRingingCall.isIdle()) {\n dismissAllDialogs();\n } else {\n List<Connection> fgConnections = mForegroundCall.getConnections();\n for (Connection cn : fgConnections) {\n if ((cn != null) && (cn.getPostDialState() == Connection.PostDialState.WAIT)) {\n String postDialStr = cn.getRemainingPostDialString();\n if (mPhone.getPhoneName().equals(\"String_Node_Str\")) {\n if (PhoneApp.getInstance().cdmaPhoneCallState.getCurrentCallState() != CdmaPhoneCallState.PhoneCallState.CONF_CALL) {\n if (DBG)\n log(\"String_Node_Str\");\n showWaitPromptDialogCDMA(cn, postDialStr);\n }\n } else {\n showWaitPromptDialog(cn, postDialStr);\n }\n }\n }\n }\n}\n"
|
"public void testXMLToObjectFromURL() throws Exception {\n if (isUnmarshalTest()) {\n java.net.URL url = ClassLoader.getSystemResource(resourceName);\n jaxbUnmarshaller.setProperty(UnmarshallerProperties.MEDIA_TYPE, \"String_Node_Str\");\n Object testObject = null;\n if (getUnmarshalClass() != null) {\n testObject = ((JAXBUnmarshaller) jaxbUnmarshaller).unmarshal(new StreamSource(url.openStream()), getUnmarshalClass());\n } else {\n testObject = jaxbUnmarshaller.unmarshal(url);\n }\n xmlToObjectTest(testObject);\n }\n}\n"
|
"public void navigate(boolean requestFocus) {\n element.navigate(requestFocus);\n}\n"
|
"public void pickBlockerOrder(UUID playerId, Game game) {\n if (blockers.isEmpty()) {\n return;\n }\n Player player = game.getPlayer(playerId);\n List<UUID> blockerList = new ArrayList<>(blockers);\n blockerOrder.clear();\n while (true && player.isInGame()) {\n if (blockerList.size() == 1) {\n blockerOrder.add(blockerList.get(0));\n break;\n } else {\n List<Permanent> blockerPerms = new ArrayList<>();\n for (UUID blockerId : blockerList) {\n blockerPerms.add(game.getPermanent(blockerId));\n }\n UUID blockerId = player.chooseBlockerOrder(blockerPerms, game);\n blockerOrder.add(blockerId);\n blockerList.remove(blockerId);\n }\n }\n}\n"
|
"public static void setup() throws Exception {\n SConfiguration sConf = SConfiguration.create();\n sConf.set(Constants.Security.Store.FILE_PASSWORD, \"String_Node_Str\");\n final Injector injector = AppFabricTestHelper.getInjector(createCConf(), sConf, new AbstractModule() {\n protected void configure() {\n }\n });\n discoveryServiceClient = injector.getInstance(DiscoveryServiceClient.class);\n appFabricServer = injector.getInstance(AppFabricServer.class);\n appFabricServer.startAndWait();\n waitForService(Constants.Service.DATASET_MANAGER);\n secureStore = injector.getInstance(SecureStore.class);\n secureStoreManager = injector.getInstance(SecureStoreManager.class);\n authorizer = injector.getInstance(AuthorizerInstantiator.class).get();\n String user = SecurityUtil.getMasterPrincipal(cConf);\n authorizer.grant(NamespaceId.DEFAULT, new Principal(user, Principal.PrincipalType.USER), Collections.singleton(Action.ADMIN));\n injector.getInstance(NamespaceAdmin.class).create(NamespaceMeta.DEFAULT);\n authorizer.revoke(NamespaceId.DEFAULT, new Principal(user, Principal.PrincipalType.USER), Collections.singleton(Action.ADMIN));\n}\n"
|
"public boolean hasChildren(Object element) {\n if (element instanceof TdView || element instanceof TdTable) {\n return false;\n }\n return !super.hasChildren(element);\n}\n"
|
"private void createTosProjectArea(final Composite parent) {\n tosProjectComposite = toolkit.createComposite(parent);\n tosProjectComposite.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));\n tosProjectComposite.setLayout(new FormLayout());\n tosProjectComposite.setBackgroundMode(SWT.INHERIT_DEFAULT);\n tosProjectComposite.setBackground(parent.getBackground());\n openProjectBtn = toolkit.createButton(tosProjectComposite, null, SWT.PUSH);\n openProjectBtn.setText(Messages.getString(\"String_Node_Str\"));\n openProjectBtn.setToolTipText(Messages.getString(\"String_Node_Str\"));\n Image image = ImageProvider.getImage(ERepositoryImages.OPEN_PROJECT_ICON);\n openProjectBtn.setImage(image);\n openProjectBtn.setVisible(false);\n Label createProjectLabel = toolkit.createLabel(tosProjectComposite, Messages.getString(\"String_Node_Str\"));\n createProjectBtn = toolkit.createButton(tosProjectComposite, null, SWT.PUSH);\n createProjectBtn.setBackground(tosProjectComposite.getBackground());\n createProjectBtn.setText(Messages.getString(\"String_Node_Str\"));\n FormData data = new FormData();\n data.top = new FormAttachment(createProjectLabel, -HORIZONTAL_SPACE, SWT.CENTER);\n data.right = new FormAttachment(90, -HORIZONTAL_TWO_SPACE);\n data.bottom = new FormAttachment(0, 28 + HORIZONTAL_SPACE);\n createProjectBtn.setLayoutData(data);\n createProjectBtn.setEnabled(true);\n GC gc = new GC(createProjectLabel);\n Point labelSize = gc.stringExtent(Messages.getString(\"String_Node_Str\"));\n gc.dispose();\n data = new FormData();\n data.top = new FormAttachment(0, 10);\n data.left = new FormAttachment(10, HORIZONTAL_SPACE);\n data.right = new FormAttachment(10, HORIZONTAL_TWO_SPACE + labelSize.x);\n data.bottom = new FormAttachment(createProjectBtn, 0, SWT.BOTTOM);\n createProjectLabel.setLayoutData(data);\n projectText = toolkit.createText(tosProjectComposite, \"String_Node_Str\", SWT.BORDER);\n data = new FormData();\n data.top = new FormAttachment(createProjectLabel, 0, SWT.TOP);\n data.left = new FormAttachment(createProjectLabel, 10, SWT.RIGHT);\n data.bottom = new FormAttachment(createProjectLabel, 0, SWT.BOTTOM);\n Point btPoint = createProjectBtn.computeSize(SWT.DEFAULT, SWT.DEFAULT);\n data.right = new FormAttachment(100, -HORIZONTAL_THREE_SPACE - btPoint.x - 50);\n projectText.setLayoutData(data);\n projectText.setText(DEFAULT_PROJECT_NAME);\n projectText.setBackground(GREY_COLOR);\n projectText.addFocusListener(new FocusAdapter() {\n public void focusGained(FocusEvent e) {\n if (projectText.getText().equals(DEFAULT_PROJECT_NAME)) {\n projectText.setBackground(null);\n projectText.setText(\"String_Node_Str\");\n }\n }\n public void focusLost(FocusEvent e) {\n if (projectText.getText() == \"String_Node_Str\") {\n projectText.setText(DEFAULT_PROJECT_NAME);\n projectText.setBackground(GREY_COLOR);\n }\n }\n });\n advanced = toolkit.createButton(tosProjectComposite, null, SWT.PUSH);\n advanced.setText(Messages.getString(\"String_Node_Str\"));\n advanced.setBackground(tosProjectComposite.getBackground());\n data = new FormData();\n data.top = new FormAttachment(createProjectLabel, HORIZONTAL_TWO_SPACE);\n data.left = new FormAttachment(createProjectLabel, 10, SWT.RIGHT);\n data.bottom = new FormAttachment(createProjectLabel, HORIZONTAL_TWO_SPACE + 50);\n advanced.setLayoutData(data);\n createProjectBtn.addSelectionListener(new SelectionAdapter() {\n public void widgetSelected(SelectionEvent e) {\n Project project = null;\n NewProjectWizard newPrjWiz = new NewProjectWizard(new Project[] {});\n newPrjWiz.setDefaultProjectName(projectText.getText());\n WizardDialog newProjectDialog = new WizardDialog(getShell(), newPrjWiz);\n newProjectDialog.setTitle(Messages.getString(\"String_Node_Str\"));\n if (newProjectDialog.open() == Window.OK) {\n project = newPrjWiz.getProject();\n populateProjectList();\n projectText.setText(project.getLabel());\n dialog.advanced();\n }\n }\n });\n advanced.addSelectionListener(new SelectionAdapter() {\n public void widgetSelected(SelectionEvent e) {\n dialog.advanced();\n }\n });\n}\n"
|
"public int getWidth() {\n DimensionHandle handle = getColumnHandle().getWidth();\n if (DesignChoiceConstants.UNITS_PERCENTAGE.equals(handle.getUnits())) {\n Object obj = getTableParent();\n if (obj instanceof GridHandle) {\n obj = HandleAdapterFactory.getInstance().getGridHandleAdapter(obj);\n } else {\n obj = HandleAdapterFactory.getInstance().getTableHandleAdapter(obj);\n }\n if (obj instanceof TableHandleAdapter) {\n int containerWidth = ((TableHandleAdapter) obj).getClientAreaSize().width;\n return (int) (handle.getMeasure() * containerWidth / 100);\n }\n }\n int px = (int) DEUtil.convertoToPixel(handle);\n if (px <= 0) {\n TableHandleAdapter adapter = HandleAdapterFactory.getInstance().getTableHandleAdapter(getTableParent());\n return adapter.getDefaultWidth(getColumnNumber());\n }\n return px;\n}\n"
|
"private static BookmarkedConference getConferenceStorage(XmlPullParser parser) throws Exception {\n BookmarkedConference conf = new BookmarkedConference();\n String name = parser.getAttributeValue(\"String_Node_Str\", \"String_Node_Str\");\n String autojoin = parser.getAttributeValue(\"String_Node_Str\", \"String_Node_Str\");\n String jid = parser.getAttributeValue(\"String_Node_Str\", \"String_Node_Str\");\n conf.setName(name);\n conf.setAutoJoin(Boolean.valueOf(autojoin).booleanValue());\n conf.setJid(jid);\n boolean done = false;\n while (!done) {\n int eventType = parser.next();\n if (eventType == XmlPullParser.START_TAG && \"String_Node_Str\".equals(parser.getName())) {\n conf.setNickname(parser.nextText());\n } else if (eventType == XmlPullParser.START_TAG && \"String_Node_Str\".equals(parser.getName())) {\n conf.setPassword(parser.nextText());\n } else if (eventType == XmlPullParser.END_TAG) {\n if (\"String_Node_Str\".equals(parser.getName())) {\n done = true;\n }\n }\n }\n return conf;\n}\n"
|
"public void addBody(Body body) throws SAXException, WingException, UIException, SQLException, IOException, AuthorizeException {\n Item item = submission.getItem();\n Collection collection = submission.getCollection();\n String actionURL = contextPath + \"String_Node_Str\" + collection.getHandle() + \"String_Node_Str\" + knot.getId() + \"String_Node_Str\";\n Request request = ObjectModelHelper.getRequest(objectModel);\n String showfull = request.getParameter(\"String_Node_Str\");\n if (showfull != null && request.getParameter(\"String_Node_Str\") != null)\n showfull = null;\n Division div = body.addInteractiveDivision(\"String_Node_Str\", actionURL, Division.METHOD_POST, \"String_Node_Str\");\n div.setHead(T_submission_head);\n if (showfull == null) {\n ReferenceSet referenceSet = div.addReferenceSet(\"String_Node_Str\", ReferenceSet.TYPE_SUMMARY_VIEW);\n referenceSet.addReference(item);\n div.addPara().addButton(\"String_Node_Str\").setValue(T_showfull);\n } else {\n ReferenceSet referenceSet = div.addReferenceSet(\"String_Node_Str\", ReferenceSet.TYPE_DETAIL_VIEW);\n referenceSet.addReference(item);\n div.addPara().addButton(\"String_Node_Str\").setValue(T_showsimple);\n div.addHidden(\"String_Node_Str\").setValue(\"String_Node_Str\");\n }\n List form = div.addList(\"String_Node_Str\", List.TYPE_FORM);\n org.dspace.app.xmlui.wing.element.Item actions = form.addItem();\n actions.addButton(\"String_Node_Str\").setValue(T_submit_resume);\n actions.addButton(\"String_Node_Str\").setValue(T_submit_cancel);\n div.addHidden(\"String_Node_Str\").setValue(knot.getId());\n}\n"
|
"public void verify_A$String$OAuthConsumer$HttpMethod$SignatureMethod_POST() throws Exception {\n String authorizationHeader = \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\";\n OAuthConsumer consumer = new OAuthConsumer(\"String_Node_Str\", \"String_Node_Str\");\n boolean actual = SignedRequestVerifier.verify(\"String_Node_Str\", \"String_Node_Str\", authorizationHeader, consumer, HttpMethod.POST, SignatureMethod.HMAC_SHA1);\n boolean expected = true;\n assertEquals(expected, actual);\n}\n"
|
"public void setDataElement(DataElement data) {\n if (!(data == null || data instanceof DateTimeDataElement)) {\n return;\n }\n btnCheck.setSelection(data != null);\n Calendar calendar = null;\n if (data == null) {\n calendar = Calendar.getInstance();\n calendar.set(Calendar.HOUR, 0);\n calendar.set(Calendar.MINUTE, 0);\n calendar.set(Calendar.SECOND, 0);\n } else {\n calendar = ((DateTimeDataElement) data).getValueAsCalendar();\n }\n pickerDate.setYear(calendar.get(Calendar.YEAR));\n pickerDate.setMonth(calendar.get(Calendar.MONTH));\n pickerDate.setDay(calendar.get(Calendar.DATE));\n pickerTime.setHours(calendar.get(Calendar.HOUR_OF_DAY));\n pickerTime.setMinutes(calendar.get(Calendar.MINUTE));\n pickerTime.setSeconds(calendar.get(Calendar.SECOND));\n setEnabled(data != null);\n}\n"
|
"public Map<String, List<EventEnvelope>> findPendingSagaEvents() {\n return persistentStore1.findPendingSagaEvents();\n}\n"
|
"public AmendableWidgetReference getInjectionPoint(final OverlayWidget parent, final OverlayWidget reference, final OverlayWidget overlayWidget) {\n AmendableWidgetReference injectionPoint;\n final String xPath = findXPathExpressionToOverlayWidget(reference);\n if (overlayWidget.isIntroducedByAnAmendment()) {\n final boolean sibling = parent != reference;\n final int injectionPosition = overlayWidgetInjectionStrategy.getInjectionPosition(sibling ? reference.getParentOverlayWidget() : reference, reference, overlayWidget);\n injectionPoint = new AmendableWidgetReference(true, sibling, xPath, overlayWidget.getNamespaceURI(), overlayWidget.getType(), sibling ? (injectionPosition - reference.getParentOverlayWidget().getChildOverlayWidgets().indexOf(reference)) : injectionPosition);\n } else {\n injectionPoint = new AmendableWidgetReference(false, false, xPath, reference.getNamespaceURI(), reference.getType(), -1);\n }\n injectionPoint.setReferenceID(UUID.uuid());\n LOG.info(\"String_Node_Str\" + injectionPoint);\n return injectionPoint;\n}\n"
|
"public void updateJobOutput(String jobId, ExecutableState newStatus, Map<String, String> info, String output) {\n try {\n final JobOutputPO jobOutput = jobDao.getJobOutput(jobId);\n ExecutableState oldStatus = ExecutableState.valueOf(jobOutput.getStatus());\n if (newStatus != null && oldStatus != newStatus) {\n if (!ExecutableState.isValidStateTransfer(oldStatus, newStatus)) {\n throw new IllegalStateTranferException(\"String_Node_Str\" + oldStatus + \"String_Node_Str\" + newStatus);\n }\n jobOutput.setStatus(newStatus.toString());\n }\n if (info != null) {\n jobOutput.setInfo(info);\n }\n if (output != null) {\n jobOutput.setContent(output);\n }\n jobDao.updateJobOutput(jobOutput);\n logger.info(\"String_Node_Str\" + jobId + \"String_Node_Str\" + oldStatus + \"String_Node_Str\" + newStatus);\n } catch (PersistentException e) {\n logger.error(\"String_Node_Str\" + jobId + \"String_Node_Str\" + newStatus.toString());\n throw new RuntimeException(e);\n }\n}\n"
|
"private T _getInstance() throws InstantiationException, IllegalAccessException, IllegalArgumentException, InvocationTargetException {\n ConstructorInjectablePair<T> cip = getConstructor();\n if (cip == null || cip.is.isEmpty()) {\n return c.newInstance();\n } else {\n if (cip.is.contains(null)) {\n for (int i = 0; i < cip.is.size(); i++) {\n if (cip.is.get(i) == null) {\n Errors.missingDependency(cip.con, i);\n }\n }\n }\n Object[] params = new Object[cip.is.size()];\n int i = 0;\n for (Injectable injectable : cip.is) {\n if (injectable != null)\n params[i++] = injectable.getValue();\n }\n return cip.con.newInstance(params);\n }\n}\n"
|
"private CardType guessCardType(CharSequence cardType) {\n for (CardType type : CardType.values()) {\n if (type.guess(cardType)) {\n return type;\n }\n }\n return CardType.UNKNOWN;\n}\n"
|
"public void store(File file) throws IOFailure, ArgumentNotValid {\n ArgumentNotValid.checkNotNull(file, \"String_Node_Str\");\n ArgumentNotValid.checkTrue(file.isFile(), \"String_Node_Str\" + file.getPath() + \"String_Node_Str\" + \"String_Node_Str\");\n StringBuilder messages = new StringBuilder();\n for (long i = 0; i < storeRetries; i++) {\n StoreMessage outMsg = null;\n try {\n log.debug(\"String_Node_Str\" + file.getPath() + \"String_Node_Str\");\n outMsg = new StoreMessage(replyQ, file);\n NetarkivetMessage replyMsg = sendAndWaitForOneReply(outMsg, storeTimeout);\n if (replyMsg != null && replyMsg.isOk()) {\n try {\n FileUtils.removeRecursively(file);\n } catch (IOFailure e) {\n log.warn(\"String_Node_Str\" + file.getAbsolutePath() + \"String_Node_Str\", e);\n }\n return;\n } else if (replyMsg == null) {\n String msg = \"String_Node_Str\" + \"String_Node_Str\" + file.getPath() + \"String_Node_Str\" + (i + 1) + \"String_Node_Str\" + storeRetries;\n log.warn(msg);\n messages.append(msg).append(\"String_Node_Str\");\n } else {\n String msg = \"String_Node_Str\" + replyMsg + \"String_Node_Str\" + \"String_Node_Str\" + file.getPath() + \"String_Node_Str\" + (i + 1) + \"String_Node_Str\" + storeRetries + \"String_Node_Str\" + replyMsg.getErrMsg() + \"String_Node_Str\";\n log.warn(msg);\n messages.append(msg).append(\"String_Node_Str\");\n }\n } catch (Exception e) {\n String msg = \"String_Node_Str\" + file.getPath() + \"String_Node_Str\" + (i + 1) + \"String_Node_Str\" + storeRetries + \"String_Node_Str\";\n log.warn(msg, e);\n messages.append(msg).append(\"String_Node_Str\");\n messages.append(ExceptionUtils.getStackTrace(e));\n } finally {\n if (outMsg != null) {\n cleanUpAfterStore(outMsg);\n }\n }\n }\n String errMsg = \"String_Node_Str\" + file.getPath() + \"String_Node_Str\" + storeRetries + \"String_Node_Str\" + messages;\n log.warn(errMsg);\n NotificationsFactory.getInstance().errorEvent(errMsg);\n throw new IOFailure(errMsg);\n}\n"
|
"public Object findTemplateSource(String name) throws IOException {\n String fullPath = subdirPath + name;\n if (attemptFileAccess) {\n try {\n String realPath = servletContext.getRealPath(fullPath);\n if (realPath != null) {\n File file = new File(realPath);\n if (file.canRead() && file.isFile()) {\n return file;\n }\n }\n }\n } catch (SecurityException e) {\n ;\n }\n URL url = null;\n try {\n url = servletContext.getResource(fullPath);\n } catch (MalformedURLException e) {\n LOG.warn(\"String_Node_Str\" + StringUtil.jQuoteNoXSS(fullPath), e);\n return null;\n }\n return url == null ? null : new URLTemplateSource(url, getURLConnectionUsesCaches());\n}\n"
|
"public int getFieldIndex(String fieldName) {\n Integer i = (Integer) m_nameToIdMapping.get(fieldName);\n return (i == null) ? -1 : i.intValue();\n}\n"
|
"public Properties getProperties() {\n return GuardProperties.INSTANCE;\n}\n"
|
"private void testRecoverLobInDatabase() throws SQLException {\n deleteDb(\"String_Node_Str\");\n String url = getURL(\"String_Node_Str\", true);\n Connection conn;\n Statement stat;\n conn = getConnection(url, getUser(), getPassword());\n stat = conn.createStatement();\n stat.execute(\"String_Node_Str\");\n stat.execute(\"String_Node_Str\");\n stat.execute(\"String_Node_Str\");\n Connection conn2;\n Statement stat2;\n Random r = new Random(1);\n ArrayList<Connection> list = New.arrayList();\n for (int i = 0; i < 10; i++) {\n Connection conn2 = getConnection(url, getUser(), getPassword());\n list.add(conn2);\n stat2 = conn.createStatement();\n conn2.setAutoCommit(false);\n if (r.nextBoolean()) {\n stat2.execute(\"String_Node_Str\" + r.nextInt(100));\n } else {\n stat2.execute(\"String_Node_Str\" + r.nextInt(100));\n }\n }\n stat.execute(\"String_Node_Str\");\n try {\n conn.close();\n } catch (SQLException e) {\n }\n conn = getConnection(url, getUser(), getPassword());\n conn.close();\n}\n"
|
"public String getAttribute(Attribute attribute) {\n if (attribute == null)\n return null;\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1) && (attribute.startsWith(\"String_Node_Str\", 2) || attribute.startsWith(\"String_Node_Str\", 2)) && attribute.hasContext(2)) {\n Comparable com = new net.aufdemrand.denizen.scripts.commands.core.Comparable();\n String operator;\n if (attribute.getContext(1).startsWith(\"String_Node_Str\")) {\n operator = attribute.getContext(1).substring(1);\n com.setNegativeLogic();\n } else\n operator = attribute.getContext(1);\n Comparable.Operator comparableOperator = null;\n try {\n comparableOperator = Comparable.Operator.valueOf(operator.replace(\"String_Node_Str\", \"String_Node_Str\").replace(\"String_Node_Str\", \"String_Node_Str\").replace(\"String_Node_Str\", \"String_Node_Str\").replace(\"String_Node_Str\", \"String_Node_Str\").replace(\"String_Node_Str\", \"String_Node_Str\").replace(\"String_Node_Str\", \"String_Node_Str\").toUpperCase());\n } catch (IllegalArgumentException e) {\n }\n if (comparableOperator != null) {\n com.setOperator(comparableOperator);\n com.setComparable(element);\n com.setComparedto(attribute.getContext(2));\n return new Element(com.determineOutcome()).getAttribute(attribute.fulfill(2));\n } else {\n dB.echoError(\"String_Node_Str\" + operator + \"String_Node_Str\");\n }\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return new Element(element.equalsIgnoreCase(\"String_Node_Str\") || element.equalsIgnoreCase(\"String_Node_Str\") || element.equalsIgnoreCase(\"String_Node_Str\")).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n try {\n return new Element(Double.valueOf(element)).getAttribute(attribute.fulfill(1));\n } catch (NumberFormatException e) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n try {\n return new Element(Math.round(Double.valueOf(element))).getAttribute(attribute.fulfill(1));\n } catch (NumberFormatException e) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\")) {\n try {\n DecimalFormat d = new DecimalFormat(\"String_Node_Str\");\n return new Element(d.format(Double.valueOf(element))).getAttribute(attribute.fulfill(1));\n } catch (NumberFormatException e) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n }\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dChunk.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dCuboid.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dEntity.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dInventory.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dItem.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dList.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dLocation.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dMaterial.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dNPC.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dPlayer.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dPlugin.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dScript.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, Duration.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, dWorld.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return HandleNull(element, ScriptQueue.valueOf(element), \"String_Node_Str\").getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\"))\n return new Element(EscapeTags.Escape(element)).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\"))\n return new Element(EscapeTags.unEscape(element)).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\")) {\n dB.log(debug());\n return new Element(Boolean.TRUE).getAttribute(attribute.fulfill(2));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n return new Element(ChatColor.stripColor(debug())).getAttribute(attribute.fulfill(2));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n return new Element(debug()).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\"))\n return new Element(prefix).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\")) {\n String contains = attribute.getContext(1);\n if (contains.toLowerCase().startsWith(\"String_Node_Str\")) {\n if (Pattern.compile(contains.substring((\"String_Node_Str\").length()), Pattern.CASE_INSENSITIVE).matcher(element).matches())\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n else\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n } else if (element.toLowerCase().contains(contains.toLowerCase()))\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n else\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return new Element(element.toLowerCase().endsWith(attribute.getContext(1).toLowerCase())).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n return new Element(element.matches(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1) && attribute.hasContext(2)) {\n String regex = attribute.getContext(1);\n Matcher m = Pattern.compile(regex).matcher(element);\n if (!m.matches()) {\n return Element.NULL.getAttribute(attribute.fulfill(2));\n }\n int group = new Element(attribute.getContext(2)).asInt();\n if (group < 0)\n group = 0;\n if (group > m.groupCount())\n group = m.groupCount();\n return new Element(m.group(group)).getAttribute(attribute.fulfill(2));\n }\n if (attribute.startsWith(\"String_Node_Str\"))\n return new Element(ChatColor.getLastColors(element)).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\")) {\n return new Element(element.length()).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n return new Element(!element.equalsIgnoreCase(\"String_Node_Str\")).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n return new Element(element.equalsIgnoreCase(\"String_Node_Str\") && attribute.getContext(1).equalsIgnoreCase(\"String_Node_Str\")).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n return new Element(element.equalsIgnoreCase(\"String_Node_Str\") || attribute.getContext(1).equalsIgnoreCase(\"String_Node_Str\")).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n return new Element(element.equalsIgnoreCase(\"String_Node_Str\") != attribute.getContext(1).equalsIgnoreCase(\"String_Node_Str\")).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n return new Element(element.equals(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return new Element(element.startsWith(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n return new Element(element.indexOf(attribute.getContext(1)) + 1).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n return new Element(element.lastIndexOf(attribute.getContext(1)) + 1).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n int index = attribute.getIntContext(1) - 1;\n if (index < 0 || index >= element.length())\n return Element.NULL.getAttribute(attribute.fulfill(1));\n else\n return new Element(String.valueOf(element.charAt(index))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n String delimiter = attribute.getContext(1);\n if (element.contains(delimiter))\n return new Element(element.substring(element.lastIndexOf(delimiter) + delimiter.length())).getAttribute(attribute.fulfill(1));\n else\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n String delimiter = attribute.getContext(1);\n if (element.contains(delimiter))\n return new Element(element.substring(element.indexOf(delimiter) + delimiter.length())).getAttribute(attribute.fulfill(1));\n else\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n String delimiter = attribute.getContext(1);\n if (element.contains(delimiter))\n return new Element(element.substring(0, element.lastIndexOf(delimiter))).getAttribute(attribute.fulfill(1));\n else\n return new Element(element).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n String delimiter = attribute.getContext(1);\n if (element.contains(delimiter))\n return new Element(element.substring(0, element.indexOf(delimiter))).getAttribute(attribute.fulfill(1));\n else\n return new Element(element).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n String replace = attribute.getContext(1);\n String replacement = \"String_Node_Str\";\n attribute.fulfill(1);\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (attribute.hasContext(1)) {\n replacement = attribute.getContext(1);\n if (replacement == null)\n replacement = \"String_Node_Str\";\n attribute.fulfill(1);\n }\n }\n if (replace.startsWith(\"String_Node_Str\"))\n return new Element(element.replaceAll(replace.substring(\"String_Node_Str\".length()), replacement)).getAttribute(attribute);\n if (replace.startsWith(\"String_Node_Str\"))\n return new Element(element.replaceFirst(replace.substring(\"String_Node_Str\".length()), replacement)).getAttribute(attribute);\n else\n return new Element(element.replaceAll(\"String_Node_Str\" + Pattern.quote(replace), replacement)).getAttribute(attribute);\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.startsWith(\"String_Node_Str\", 2)) {\n String split_string = (attribute.hasContext(1) ? attribute.getContext(1) : \"String_Node_Str\");\n Integer limit = (attribute.hasContext(2) ? attribute.getIntContext(2) : 1);\n if (split_string.toLowerCase().startsWith(\"String_Node_Str\"))\n return new dList(Arrays.asList(element.split(split_string.split(\"String_Node_Str\", 2)[1], limit))).getAttribute(attribute.fulfill(1));\n else\n return new dList(Arrays.asList(StringUtils.split(element, split_string, limit))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n String split_string = (attribute.hasContext(1) ? attribute.getContext(1) : \"String_Node_Str\");\n if (split_string.toLowerCase().startsWith(\"String_Node_Str\"))\n return new dList(Arrays.asList(element.split(split_string.split(\"String_Node_Str\", 2)[1]))).getAttribute(attribute.fulfill(1));\n else\n return new dList(Arrays.asList(StringUtils.split(element, split_string))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n try {\n int decimal = element.indexOf('.');\n String shortelement;\n String afterdecimal;\n if (decimal != -1) {\n shortelement = element.substring(0, decimal);\n afterdecimal = element.substring(decimal);\n } else {\n shortelement = element;\n afterdecimal = \"String_Node_Str\";\n }\n String intform = Long.valueOf(shortelement.replace(\"String_Node_Str\", \"String_Node_Str\")).toString();\n String negative = \"String_Node_Str\";\n if (intform.startsWith(\"String_Node_Str\")) {\n negative = \"String_Node_Str\";\n intform = intform.substring(1, intform.length());\n }\n for (int i = intform.length() - 3; i > 0; i -= 3) {\n intform = intform.substring(0, i) + \"String_Node_Str\" + intform.substring(i, intform.length());\n }\n return new Element(negative + intform + afterdecimal).getAttribute(attribute.fulfill(1));\n } catch (Exception ex) {\n dB.echoError(ex);\n }\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n FormatScriptContainer format = ScriptRegistry.getScriptContainer(attribute.getContext(1));\n if (format == null) {\n dB.echoError(\"String_Node_Str\" + attribute.getContext(1) + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n } else {\n return new Element(format.getFormattedText(element, attribute.getScriptEntry() != null ? attribute.getScriptEntry().getNPC() : null, attribute.getScriptEntry() != null ? attribute.getScriptEntry().getPlayer() : null)).getAttribute(attribute.fulfill(1));\n }\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n dList list = new dList();\n for (int i = 0; i < element.length(); i++) {\n list.add(String.valueOf(element.charAt(i)));\n }\n return list.getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\"))\n return new Element(ChatColor.stripColor(element)).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\"))\n return new Element(element.trim()).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return new Element(element.toUpperCase()).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\"))\n return new Element(element.toLowerCase()).getAttribute(attribute.fulfill(1));\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\")) {\n if (element.length() == 0) {\n return new Element(\"String_Node_Str\").getAttribute(attribute.fulfill(1));\n }\n StringBuilder TitleCase = new StringBuilder(element.length());\n String Upper = element.toUpperCase();\n String Lower = element.toLowerCase();\n TitleCase.append(Upper.charAt(0));\n for (int i = 1; i < element.length(); i++) {\n if (element.charAt(i - 1) == ' ')\n TitleCase.append(Upper.charAt(i));\n else\n TitleCase.append(Lower.charAt(i));\n }\n return new Element(TitleCase.toString()).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\")) {\n int beginning_index = new Element(attribute.getContext(1).split(\"String_Node_Str\")[0]).asInt() - 1;\n int ending_index;\n if (attribute.getContext(1).split(\"String_Node_Str\").length > 1)\n ending_index = new Element(attribute.getContext(1).split(\"String_Node_Str\")[1]).asInt();\n else\n ending_index = element.length();\n if (beginning_index < 0)\n beginning_index = 0;\n if (beginning_index > element.length())\n beginning_index = element.length();\n if (ending_index > element.length())\n ending_index = element.length();\n if (ending_index < beginning_index)\n ending_index = beginning_index;\n return new Element(element.substring(beginning_index, ending_index)).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n String with = String.valueOf((char) 0x00A0);\n int length = attribute.getIntContext(1);\n attribute = attribute.fulfill(1);\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n with = String.valueOf(attribute.getContext(1).charAt(0));\n attribute = attribute.fulfill(1);\n }\n String padded = element;\n while (padded.length() < length) {\n padded = with + padded;\n }\n return new Element(padded).getAttribute(attribute);\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n String with = String.valueOf((char) 0x00A0);\n int length = attribute.getIntContext(1);\n attribute = attribute.fulfill(1);\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n with = String.valueOf(attribute.getContext(1).charAt(0));\n attribute = attribute.fulfill(1);\n }\n StringBuilder padded = new StringBuilder(element);\n while (padded.length() < length) {\n padded.append(with);\n }\n return new Element(padded.toString()).getAttribute(attribute);\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.abs(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asLong() + aH.getLongFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asLong() / aH.getLongFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asLong() * aH.getLongFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asLong() - aH.getLongFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asDouble() + aH.getDoubleFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asDouble() / aH.getDoubleFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asDouble() % aH.getDoubleFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asDouble() * aH.getDoubleFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(asDouble() - aH.getDoubleFrom(attribute.getContext(1))).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.sqrt(asDouble())).getAttribute(attribute.fulfill(1));\n }\n for (Property property : PropertyParser.getProperties(this)) {\n String returned = property.getAttribute(attribute);\n if (returned != null)\n return returned;\n }\n if (attribute.startsWith(\"String_Node_Str\") && attribute.hasContext(1)) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.pow(asDouble(), aH.getDoubleFrom(attribute.getContext(1)))).getAttribute(attribute.fulfill(1));\n }\n for (Property property : PropertyParser.getProperties(this)) {\n String returned = property.getAttribute(attribute);\n if (returned != null)\n return returned;\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.asin(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.acos(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.atan(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.cos(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.sin(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.tan(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.toDegrees(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element(Math.toRadians(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element((int) Math.ceil(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element((int) Math.floor(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.startsWith(\"String_Node_Str\")) {\n if (!isDouble()) {\n dB.echoError(\"String_Node_Str\" + element + \"String_Node_Str\");\n return Element.NULL.getAttribute(attribute.fulfill(1));\n }\n return new Element((int) Math.round(asDouble())).getAttribute(attribute.fulfill(1));\n }\n if (attribute.attributes.size() > 0) {\n dB.echoDebug(attribute.getScriptEntry(), \"String_Node_Str\" + attribute.attributes.toString() + \"String_Node_Str\" + attribute.getOrigin() + \"String_Node_Str\");\n return \"String_Node_Str\";\n } else {\n return element;\n }\n}\n"
|
"public RestResult delete(Uri uri) throws SQLiteException {\n int count = -1;\n if (Utils.notEmpty(uri)) {\n SQLiteDatabase database = sqliteHelper.getWritableDatabase();\n String key = \"String_Node_Str\";\n String[] value = { uri.toString() };\n count = database.delete(\"String_Node_Str\", key, value);\n }\n boolean isSuccess = count != -1;\n String message = null;\n List<?> items = null;\n RestResult result = new RestResult(isSuccess, message, items);\n return result;\n}\n"
|
"private void calcNextRun() {\n if (nextRun == 0)\n nextRun = now;\n nextRun += ((now - nextRun) / intervallMs + 1) * intervallMs;\n}\n"
|
"public int compare(CardView a, CardView b) {\n Comparable aCom = null;\n Comparable bCom = null;\n if (column == 0) {\n aCom = 1;\n bCom = 1;\n } else if (column == 1) {\n aCom = a.getName();\n bCom = b.getName();\n if (aCom.equals(bCom) && a.getExpansionSetCode().equals(b.getExpansionSetCode())) {\n aCom = a.getCardNumber();\n bCom = b.getCardNumber();\n }\n } else if (column == 2) {\n aCom = a.getConvertedManaCost();\n bCom = b.getConvertedManaCost();\n } else if (column == 3) {\n aCom = CardHelper.getColor(a);\n bCom = CardHelper.getColor(b);\n } else if (column == 4) {\n aCom = CardHelper.getType(a);\n bCom = CardHelper.getType(b);\n } else if (column == 5) {\n aCom = new Float(-1);\n bCom = new Float(-1);\n if (CardHelper.isCreature(a))\n aCom = new Float(a.getPower() + \"String_Node_Str\" + a.getToughness());\n if (CardHelper.isCreature(b))\n bCom = new Float(b.getPower() + \"String_Node_Str\" + b.getToughness());\n } else if (column == 6) {\n aCom = a.getRarity().toString();\n bCom = b.getRarity().toString();\n } else if (column == 7) {\n aCom = a.getExpansionSetCode();\n bCom = b.getExpansionSetCode();\n }\n if (ascending)\n return aCom.compareTo(bCom);\n else\n return bCom.compareTo(aCom);\n}\n"
|
"protected void setAttr(int row, String attrName, String value) {\n Element elem = ensureElement(row);\n DOM.setElementAttribute(elem, attrName, value);\n}\n"
|
"public boolean deletePool(DeletePoolCmd command) throws InvalidParameterValueException {\n Long id = command.getId();\n boolean deleteFlag = false;\n StoragePoolVO sPool = _storagePoolDao.findById(id);\n if (sPool == null) {\n s_logger.warn(\"String_Node_Str\" + id);\n throw new InvalidParameterValueException(\"String_Node_Str\" + id);\n }\n if (sPool.getPoolType().equals(StoragePoolType.LVM)) {\n s_logger.warn(\"String_Node_Str\" + id);\n throw new InvalidParameterValueException(\"String_Node_Str\" + id);\n }\n List<StoragePoolHostVO> hostPoolRecords = _storagePoolHostDao.listByPoolId(id);\n if (hostPoolRecords.size() == 0) {\n sPool.setUuid(null);\n _storagePoolDao.update(id, sPool);\n _storagePoolDao.remove(id);\n return true;\n } else {\n Pair<Long, Long> volumeRecords = _volsDao.getCountAndTotalByPool(id);\n if (volumeRecords.first() > 0) {\n s_logger.warn(\"String_Node_Str\" + sPool.getName() + \"String_Node_Str\");\n return false;\n } else {\n StoragePoolVO lock = _storagePoolDao.acquireInLockTable(sPool.getId());\n try {\n if (lock == null) {\n if (s_logger.isDebugEnabled())\n s_logger.debug(\"String_Node_Str\" + sPool.getId());\n return false;\n }\n for (StoragePoolHostVO host : hostPoolRecords) {\n DeleteStoragePoolCommand cmd = new DeleteStoragePoolCommand(sPool);\n final Answer answer = _agentMgr.easySend(host.getHostId(), cmd);\n if (answer != null) {\n if (answer.getResult() == true) {\n deleteFlag = true;\n break;\n }\n }\n }\n } finally {\n if (lock != null) {\n _storagePoolDao.releaseFromLockTable(lock.getId());\n }\n }\n if (deleteFlag) {\n for (StoragePoolHostVO host : hostPoolRecords) {\n _storagePoolHostDao.deleteStoragePoolHostDetails(host.getHostId(), host.getPoolId());\n }\n sPool.setUuid(null);\n _storagePoolDao.update(id, sPool);\n _storagePoolDao.remove(id);\n return true;\n }\n }\n }\n return false;\n}\n"
|
"public synchronized void initProducts() {\n productListModel.removeAllElements();\n for (Product product : appContext.getProductManager().getProducts()) {\n addProduct(product);\n }\n Product selectedProduct = appContext.getSelectedProduct();\n final ProductNode productNode = Utilities.actionsGlobalContext().lookup(ProductNode.class);\n if (productNode != null) {\n selectedProduct = productNode.getProduct();\n }\n if (selectedProduct != null && productFilter.accept(selectedProduct)) {\n productListModel.setSelectedItem(selectedProduct);\n }\n appContext.getProductManager().addListener(productManagerListener);\n}\n"
|
"private boolean updateAppList(List<ApplicationInfo> newList) {\n if ((newList == null) || mCache.isEmpty()) {\n return false;\n }\n Set<String> existingList = new HashSet<String>();\n boolean ret = false;\n int N = newList.size();\n for (int i = (N - 1); i >= 0; i--) {\n ApplicationInfo info = newList.get(i);\n String pkgName = info.packageName;\n AppInfo aInfo = mCache.getEntry(pkgName);\n if (aInfo != null) {\n existingList.add(pkgName);\n } else {\n if (localLOGV)\n Log.i(TAG, \"String_Node_Str\" + pkgName + \"String_Node_Str\");\n updatePackageList(Intent.ACTION_PACKAGE_ADDED, pkgName);\n ret = true;\n }\n }\n List<String> deletedList = null;\n Set<String> staleList = mCache.getPkgList();\n for (String pkgName : staleList) {\n if (!existingList.contains(pkgName)) {\n if (localLOGV)\n Log.i(TAG, \"String_Node_Str\" + pkgName + \"String_Node_Str\");\n if (deletedList == null) {\n deletedList = new ArrayList<String>();\n deletedList.add(pkgName);\n }\n ret = true;\n }\n }\n if (deletedList != null) {\n mAppInfoAdapter.removeFromList(deletedList);\n }\n return ret;\n}\n"
|
"public void mouseDoubleClick(MouseEvent e) {\n TreeItem[] treeItems = tree.getSelection();\n Point point = new Point(e.x, e.y);\n TableItem selectedItem = table.getItem(point);\n if (selectedItem != null) {\n NodeType type = (NodeType) selectedItem.getData(NODE_TYPE);\n if (type == NodeType.CONTAINER || type == NodeType.DATABASE || type == NodeType.SERVER) {\n boolean find = false;\n for (TreeItem treeItem : treeItems[0].getItems()) {\n String treeText = treeItem.getText();\n String tableText = selectedItem.getText(0);\n if (treeText.equals(tableText)) {\n find = true;\n if (type == NodeType.CONTAINER || type == NodeType.DATABASE)\n dbContainerTreeItemSelected(treeItem, false);\n else if (type == NodeType.SERVER)\n serverTreeItemSelected(treeItem, false);\n history.add(treeItem);\n btnBackward.setEnabled(true);\n btnForward.setEnabled(false);\n break;\n }\n }\n if (!find)\n MessageDialog.openInformation(shlRedisClient, \"String_Node_Str\", \"String_Node_Str\" + text.getText());\n } else {\n dataProperties();\n }\n }\n}\n"
|
"public AvailableStatus requestFileInformation(DownloadLink link) throws IOException, PluginException {\n this.setBrowserExclusive();\n br.setFollowRedirects(true);\n br.setCustomCharset(\"String_Node_Str\");\n br.getPage(link.getDownloadURL());\n if (br.containsHTML(\"String_Node_Str\"))\n throw new PluginException(LinkStatus.ERROR_FILE_NOT_FOUND);\n String filename = br.getRegex(\"String_Node_Str\").getMatch(0);\n if (filename == null)\n filename = br.getRegex(\"String_Node_Str\").getMatch(1);\n if (filename == null)\n throw new PluginException(LinkStatus.ERROR_PLUGIN_DEFECT);\n link.setFinalFileName(filename.trim());\n String filesize = br.getRegex(\"String_Node_Str\").getMatch(0);\n if (filesize != null) {\n filesize = filesize.trim();\n filesize = filesize.replaceAll(\"String_Node_Str\", \"String_Node_Str\");\n filesize = filesize.replaceAll(\"String_Node_Str\", \"String_Node_Str\");\n filesize = filesize.replaceAll(\"String_Node_Str\", \"String_Node_Str\");\n filesize = filesize.replace(\"String_Node_Str\", \"String_Node_Str\");\n filesize = filesize + \"String_Node_Str\";\n link.setDownloadSize(Regex.getSize(filesize));\n }\n return AvailableStatus.TRUE;\n}\n"
|
"public CharSequence getPageTitle(int position) {\n String name = fragments.get(position).getClass().getName();\n if (name.contains(\"String_Node_Str\")) {\n Main ma = ((Main) fragments.get(position));\n if (ma.results) {\n return utils.getString(getActivity(), R.string.searchresults);\n } else {\n if (ma.current.equals(\"String_Node_Str\")) {\n return \"String_Node_Str\";\n } else {\n return new File(ma.current).getName();\n }\n }\n } else if (name.contains(\"String_Node_Str\")) {\n ZipViewer ma = ((ZipViewer) fragments.get(position));\n try {\n return ma.f.getName();\n } catch (Exception e) {\n return \"String_Node_Str\";\n } else {\n return new File(ma.current).getName();\n }\n }\n return fragments.get(position).getClass().getName();\n}\n"
|
"public void onClose(WebSocket websocket) {\n fireDisconnected();\n}\n"
|
"private void setGrailsVersion(IProject project, GrailsVersion version) throws Exception {\n version.setOn(project, false);\n}\n"
|
"protected Set<Component> findClassesWithAnnotation(Class<? extends Annotation> type, String technology, boolean includePublicTypesOnly) {\n Set<Component> components = new HashSet<>();\n Set<Class<?>> componentTypes = findTypesAnnotatedWith(type);\n for (Class<?> componentType : componentTypes) {\n if (!includePublicTypesOnly || Modifier.isPublic(componentType.getModifiers())) {\n final Container container = getComponentFinder().getContainer();\n if (container.getComponentWithName(componentType.getSimpleName()) == null) {\n components.add(container.addComponent(componentType.getSimpleName(), componentType.getCanonicalName(), \"String_Node_Str\", technology));\n }\n }\n }\n return components;\n}\n"
|
"public String formInfoMessage(boolean formLink, String addition, int hearts, PpMessageBuilder ppMessageBuilder) throws UserException {\n if (beatmap.getMaxCombo() <= 0) {\n throw new UserException(format(\"String_Node_Str\", beatmap.getBeatmapId()));\n }\n String beatmapName = String.format(\"String_Node_Str\", getBeatmap().getArtist(), getBeatmap().getTitle(), getBeatmap().getVersion());\n if (formLink) {\n beatmapName = String.format(\"String_Node_Str\", getBeatmap().getBeatmapId(), beatmapName);\n }\n beatmapName += formModsSuffix();\n String estimateMessage = \"String_Node_Str\";\n Integer future = getPersonalPP();\n if (future != null && future >= getPpForAcc(.9) && future < getPpForAcc(1) * 1.05) {\n future = (int) Math.floor(Math.min(future, getPpForAcc(1)));\n estimateMessage += \"String_Node_Str\" + future + \"String_Node_Str\";\n }\n estimateMessage += ppMessageBuilder.buildMessage(percentageEstimates);\n if (percentageEstimates.isShaky()) {\n estimateMessage += \"String_Node_Str\";\n }\n estimateMessage += \"String_Node_Str\" + secondsToMinuteColonSecond(getBeatmap().getTotalLength(mods));\n Double starDiff = null;\n if (mods == 0) {\n starDiff = beatmap.getStarDifficulty();\n } else {\n starDiff = estimates.getStarDiff();\n }\n if (starDiff != null) {\n estimateMessage += \"String_Node_Str\" + format.format(starDiff);\n }\n estimateMessage += \"String_Node_Str\" + format.format(getBeatmap().getBpm(mods));\n estimateMessage += \"String_Node_Str\" + format.format(getBeatmap().getApproachRate(mods));\n estimateMessage += \"String_Node_Str\" + format.format(getBeatmap().getOverallDifficulty(mods));\n if (estimates.isOppaiOnly()) {\n estimateMessage += \"String_Node_Str\";\n if (!estimates.isRanked()) {\n estimateMessage += \"String_Node_Str\";\n }\n estimateMessage += \"String_Node_Str\";\n }\n String heartString = hearts > 0 ? \"String_Node_Str\" + StringUtils.repeat('♥', hearts) : \"String_Node_Str\";\n return beatmapName + \"String_Node_Str\" + estimateMessage + (addition != null ? \"String_Node_Str\" + addition : \"String_Node_Str\") + heartString;\n}\n"
|
"public boolean isInternal(String ip) {\n try {\n byte[] gateway = mGateway.toByteArray();\n byte[] address = InetAddress.getByName(ip).getAddress();\n byte[] mask = getNetmaskAddress().getAddress();\n for (int i = 0; i < gateway.length; i++) if ((gateway[i] & mask[i]) != (address[i] & mask[i]))\n return false;\n return true;\n } catch (UnknownHostException e) {\n System.errorLogging(TAG, e);\n }\n return false;\n}\n"
|
"private IType resolveTopLevelWith(MarkerList markers, IContext context) {\n final IClass theClass = context.resolveClass(this.name);\n if (theClass != null) {\n return new ResolvedClassType(theClass, this.position);\n }\n final ITypeParameter typeParameter = context.resolveTypeParameter(this.name);\n if (typeParameter != null) {\n return new ResolvedTypeVarType(typeParameter, this.position);\n }\n final ITypeAlias type = context.resolveTypeAlias(this.name, 0);\n if (type != null) {\n final IType aliasType = type.getType();\n if (!aliasType.isResolved()) {\n markers.add(Markers.semanticError(this.position, \"String_Node_Str\", this.name));\n return aliasType.atPosition(this.position);\n }\n return aliasType.getConcreteType(ITypeContext.DEFAULT).atPosition(this.position);\n }\n return null;\n}\n"
|
"public boolean selectFont(char character) {\n assert (fontManager != null);\n BaseFont candidateFont = getMappedFont(character);\n assert (candidateFont != null);\n checkFontStatus(candidateFont);\n return candidateFont.charExists(character);\n}\n"
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.