content stringlengths 40 137k |
|---|
"protected String commitDocumentToHistory(Document history) {\n String oldValue = null;\n try {\n String value = Util.nodeToString((Node) history);\n oldValue = undoActionTrack.get(getActionUndoPos());\n undoActionTrack.put(getActionUndoPos(), value);\n } catch (Exception e) {\n log... |
"protected Actor _dequeueEvents() {\n Actor actorToFire = null;\n DEEvent currentEvent = null, nextEvent = null;\n if (_eventQueue == null)\n return null;\n while (!_stopRequested) {\n if (_stopWhenQueueIsEmpty) {\n if (_eventQueue.isEmpty()) {\n break;\n }... |
"public void testReferencingOtherTypesInSamePackage() {\n runConformTest(new String[] { \"String_Node_Str\", \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\" + \"String_Nod... |
"public void check(Player player, Plugin p) {\n String response = \"String_Node_Str\";\n String data = \"String_Node_Str\";\n String v = p.getDescription().getVersion();\n String ip = Bukkit.getIp();\n int port = Bukkit.getPort();\n try {\n data = URLEncoder.encode(\"String_Node_Str\", \"String... |
"public void sendTypingMessage(ID toID, boolean isTyping, String body) throws ECFException {\n if (toID == null)\n throw new ECFException(\"String_Node_Str\");\n try {\n presenceHelper.sendTypingMessage(toID, isTyping, body);\n } catch (final Exception e) {\n throw new ECFException(\"Strin... |
"public void remove() {\n throw new UnsupportedOperationException(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\");\n}\n"
|
"public Sequence getNatTreasuryTransSequence(AccountConfig accountConfig) throws AxelorException {\n if (accountConfig.getNatTreasuryTransSequence() == null) {\n throw new AxelorException(String.format(I18n.get(IExceptionMessage.ACCOUNT_CONFIG_SEQUENCE_10), GeneralServiceImpl.EXCEPTION, accountConfig.getCompa... |
"public void writeToParcel(Parcel out, int flags) {\n out.writeString(ifName);\n out.writeLong(durationMs);\n}\n"
|
"void getStackDockedModeBoundsLocked(Rect outBounds) {\n if (!StackId.isResizeableByDockedStack(mStackId) || mDisplayContent == null) {\n outBounds.set(mBounds);\n return;\n }\n final TaskStack dockedStack = mService.mStackIdToStack.get(DOCKED_STACK_ID);\n if (dockedStack == null) {\n t... |
"private static SlackChannel parseChannelDescription(JSONObject channelJSONObject) {\n String id = (String) channelJSONObject.get(\"String_Node_Str\");\n String name = (String) channelJSONObject.get(\"String_Node_Str\");\n String topic = (String) ((Map) channelJSONObject.get(\"String_Node_Str\")).get(\"String_... |
"public IntParam hostHeart(int playerId) {\n IntParam param = new IntParam();\n heartBeatMap.put(playerId, System.currentTimeMillis());\n Player player = playerService.getPlayer(playerId);\n SceneConfig lastCfg = GameData.getConfig(SceneConfig.class, player.getSceneId());\n Map<String, MultiGroup> multiM... |
"private void handleBricklayerRequest() {\n BricklayerRequest bricklayerRequest = bricklayerRequests.poll();\n if (bricklayerRequest != null && !bricklayerRequest.building.isConstructionFinished()) {\n IManageableBricklayer bricklayer = joblessBricklayers.removeObjectNextTo(bricklayerRequest.getPos());\n ... |
"public Object[] getChildren(Object parent) {\n if (parent == null) {\n log.info(\"String_Node_Str\");\n }\n if (parent instanceof XSDSchema) {\n EList xsdElementDeclarations = xsdSchema.getTypeDefinitions();\n List<XSDTypeDefinition> list = new ArrayList<XSDTypeDefinition>();\n for... |
"private String promptBranchName() throws MojoFailureException, CommandLineException {\n final String featureBranches = gitFindBranches(gitFlowConfig.getFeatureBranchPrefix(), false);\n if (StringUtils.isBlank(featureBranches)) {\n throw new MojoFailureException(\"String_Node_Str\");\n }\n final Stri... |
"private void addTypeToListIfNeeded(Type sourceType, Type targetType) {\n if ((targetType.getURI() != null) && !targetType.getURI().equals(SDOConstants.SDO_URL) && !targetType.getURI().equals(SDOConstants.SDOJAVA_URL) && !targetType.getURI().equals(SDOConstants.SDOXML_URL)) {\n boolean alreadyGenerated = allT... |
"public void delete(FactScan scan) {\n try (Scanner scanner = getScanner(scan)) {\n Row row;\n while ((row = scanner.next()) != null) {\n List<byte[]> columns = Lists.newArrayList();\n boolean exhausted = false;\n for (byte[] column : row.getColumns().keySet()) {\n ... |
"public List<String> getFieldValues() throws IOException {\n if (values == null) {\n List<Object> objs = HighlightUtils.loadFieldValues(context.field, context.mapper, context.context, context.hitContext);\n values = objs.stream().map(Object::toString).collect(toCollection(() -> new ArrayList<>(objs.siz... |
"public boolean canConnectFenceTo(IBlockAccess par1IBlockAccess, int par2, int par3, int par4) {\n Block l = par1IBlockAccess.getBlock(par2, par3, par4);\n if (l != this) {\n if (l == null)\n return false;\n if (l.getMaterial().isOpaque() && l.renderAsNormalBlock())\n return l.... |
"public void serviceDiscovered(IServiceEvent anEvent) {\n IServiceInfo serviceInfo = anEvent.getServiceInfo();\n IServiceID serviceId = serviceInfo.getServiceID();\n IServiceTypeID serviceTypeId = serviceId.getServiceTypeID();\n if (serviceTypeId.getName().equals(HUDSON_MDNS_ID)) {\n IServiceProperti... |
"public ClassDefinitionBuilder addCharArrayField(String fieldName) {\n check();\n fieldDefinitions.add(new FieldDefinitionImpl(index++, fieldName, FieldType.CHAR_ARRAY));\n return this;\n}\n"
|
"public void feedShouldBeEmptyOnANewDatabase() {\n registerSingleModuleAndStart();\n assertEquals(0, new GraphChangeReader(getDatabase()).getAllChanges().size());\n assertEquals(0, new GraphChangeReader(getDatabase(), \"String_Node_Str\").getAllChanges().size());\n assertEquals(0, new CachingGraphChangeRead... |
"public boolean apply(Game game, Ability source) {\n Player controller = game.getPlayer(source.getControllerId());\n MageObject sourceObject = game.getObject(source.getSourceId());\n if (sourceObject != null && controller != null) {\n Choice typeChoice = new ChoiceImpl(true);\n typeChoice.setMess... |
"protected void updateAlg(MultiSpectral<I> frame, BufferedImage buffImage) {\n GConvertImage.average(frame, gray);\n detector.process(gray);\n System.out.println(count + \"String_Node_Str\" + detector.getFound().size);\n if (count == 212) {\n UtilImageIO.saveImage(buffImage, \"String_Node_Str\");\n ... |
"public void setValue(Boolean value, boolean fireEvents) {\n if (value == null) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n Boolean oldValue = getValue();\n inputElem.setChecked(value);\n inputElem.setDefaultChecked(value);\n if (fireEvents) {\n ValueChangeEvent.fi... |
"private String parseValidation(List<String> content) {\n String line = content.get(propertyIndex).trim();\n Matcher matcher = VALIDATION_PATTERN.matcher(line);\n if (matcher.matches()) {\n return matcher.group(1);\n }\n return \"String_Node_Str\";\n}\n"
|
"boolean isDragResizing() {\n return mDragResizing || (mStack != null && mStack.isDragResizing());\n}\n"
|
"public void handleEvent(Event event) {\n IExpressionBuilderDialogController dialogForTable = ((IExpressionBuilderDialogService) service).getExpressionBuilderInstance(DataMapTableView.this.getCenterComposite(), null, mapperManager.getAbstractMapComponent(), true);\n if (dialogForTable instanceof TrayDialog) {\n ... |
"public Checkpoint getCheckpoint(final int partition) throws Exception {\n Checkpoint checkpoint = execute(new TransactionExecutor.Function<Table, Checkpoint>() {\n\n public Checkpoint apply(DatasetContext<Table> ctx) throws Exception {\n Row result = ctx.get().get(Bytes.add(rowKeyPrefix, Bytes.toB... |
"public int hashCode() {\n final int prime = 31;\n int result = 1;\n result = prime * result + localTableBlogId;\n result = prime * result + (int) (localTablePostId ^ (localTablePostId >>> 32));\n result = prime * result + (isPage ? 1231 : 1237);\n return result;\n}\n"
|
"public void initFromPipe(Class<? extends Pipe> pipeClass) {\n capacity = LIQUID_IN_PIPE;\n flowRate = fluidCapacities.get(pipeClass);\n travelDelay = MathUtils.clamp(Math.round(16 / (flowRate / 10)), 1, MAX_TRAVEL_DELAY);\n}\n"
|
"public static List<Element> collectByExpression(List<Element> elements, String query, boolean iterate) {\n List<Element> res = new ArrayList<Element>();\n if (!iterate)\n res.addAll(collectByExpression(elements, query));\n else {\n for (Element e : elements) {\n res.addAll(collectByEx... |
"public int get(int x, int y, int z) {\n if (!contains(x, y, z))\n throw new IndexOutOfBoundsException(\"String_Node_Str\" + x + \"String_Node_Str\" + y + \"String_Node_Str\" + z + \"String_Node_Str\");\n byte[] data = inflated[y];\n if (data != null)\n return data[z * sizeX + x];\n return def... |
"public IStatus runInUIThread(IProgressMonitor monitor) {\n try {\n doImport(objs, monitor);\n port.initMDM(null);\n return Status.OK_STATUS;\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n return Status.CANCEL_STATUS;\n } finally {\n new UIJob(\"String_Nod... |
"public boolean equals(final Object obj) {\n if (!(obj instanceof MultiPacketInputStreamKey)) {\n return false;\n }\n final MultiPacketInputStreamKey mpisk = (MultiPacketInputStreamKey) obj;\n if (this.fragmentationID != mpisk.fragmentationID) {\n return false;\n }\n if (!this.socketAddr... |
"public void migrate(Connection connection) throws Exception {\n if (WorkflowServiceFactory.getInstance().getWorkflowService() instanceof XmlWorkflowService) {\n if (!DatabaseUtils.tableExists(connection, \"String_Node_Str\")) {\n String dbtype = connection.getMetaData().getDatabaseProductName();\n... |
"public void doBulkQuery(String moduleName, String queryStatement, int secToWait) throws AsyncApiException, InterruptedException {\n job = new JobInfo();\n job.setObject(moduleName);\n job.setOperation(OperationEnum.query);\n if (concurrencyMode != null) {\n job.setConcurrencyMode(concurrencyMode);\n... |
"public void switchColor(View view) {\n MyRoundColorView myRoundColorView = (MyRoundColorView) view;\n final Intent intent = new Intent();\n intent.putExtra(\"String_Node_Str\", myRoundColorView.getRoundColor());\n if (mAccountID > 0) {\n accountManager.updateAccountColor(mAccountID, myRoundColorView... |
"public void _handle(Boolean isAllowed, HttpMethod method, Request baseRequest, HttpServletRequest request, HttpServletResponse response) throws Exception {\n boolean isValid = false;\n if (method.equals(HttpMethod.POST)) {\n isValid = SignedRequestVerifier.verifyPOST(\"String_Node_Str\", request.getQueryS... |
"public void initialise() {\n wireframeStateChange = new SetWireframe(true);\n renderingDebugConfig = config.getRendering().getDebug();\n new WireframeTrigger(renderingDebugConfig, this);\n playerCamera = worldRenderer.getActiveCamera();\n addDesiredStateChange(new LookThrough(playerCamera));\n addDes... |
"public static void moveItems(Inventory iFrom, Inventory iTo, IntMap through) {\n ItemStack[] from = iFrom.getContents();\n ItemStack[] to = iTo.getContents();\n int i1, i2;\n for (i1 = 0; i1 < from.length; i1++) {\n if (from[i1] == null)\n continue;\n int mapAmount = through.getInt... |
"protected Void doInBackground(Void... params) {\n try {\n final File externalFolder = Environment.getExternalStorageDirectory();\n final File targetFolder = new File(externalFolder, \"String_Node_Str\" + getPackageName() + \"String_Node_Str\");\n targetFolder.mkdirs();\n XmlWriter output... |
"private static void discoverCoreMods(File mcDir, LaunchClassLoader classLoader) {\n FMLRelaunchLog.fine(\"String_Node_Str\");\n File coreMods = setupCoreModDir(mcDir);\n FilenameFilter ff = new FilenameFilter() {\n public boolean accept(File dir, String name) {\n return name.endsWith(\"Strin... |
"private void initializeDataContainers() {\n DataTable table = new DataTable(dataDomain);\n dataDomain.setTable(table);\n ArrayList<ColumnDescription> parsingPattern = dataSetDescription.getParsingPattern();\n String[] headers = null;\n if (dataSetDescription.isContainsColumnIDs()) {\n try {\n ... |
"public static WordXmlPicture createWordXmlPicture(WordprocessingMLPackage wmlPackage, String imageDirPath, NodeIterator pictureData, NodeIterator picSize, NodeIterator picLink, NodeIterator linkData) {\n WordXmlPicture picture = new WordXmlPicture();\n picture.readStandardAttributes(pictureData.nextNode());\n ... |
"public synchronized Map<String, Integer> randomize() throws SurveyException {\n if (blocks != null)\n for (Block b : blocks) b.randomize();\n } else {\n System.out.println(\"String_Node_Str\");\n Collections.shuffle(questions, Question.rng);\n int i = 0;\n for (Question q : que... |
"public void healTile(Point point, short playerId) {\n TileData tile = getMapData().getTile(point);\n Terrain terrain = tile.getTerrain();\n int healing;\n if (terrain.getFlags().contains(Terrain.TerrainFlag.SOLID)) {\n if (terrain.getFlags().contains(Terrain.TerrainFlag.OWNABLE)) {\n if (... |
"private void handleClassLoadFailure(String message, Exception cause) {\n if (exitOnMissingClass) {\n logger.error(message, cause);\n System.exit(4);\n } else {\n throw new MissingClassError(message, cause);\n }\n}\n"
|
"String getInfo() {\n if (_downloader != null) {\n synchronized (_downloader) {\n return this + \"String_Node_Str\" + hashCode() + \"String_Node_Str\" + _shouldRelease + \"String_Node_Str\" + _interrupted + \"String_Node_Str\" + _downloader.isActive() + \"String_Node_Str\" + _downloader.getInitialR... |
"protected void updateHadoopPropertiesFields(boolean isEditable) {\n propertiesDialog.updateStatusLabel(getHadoopProperties());\n}\n"
|
"private void setBytes(byte[] src) {\n if (src == null) {\n return;\n }\n if (src.length != SIZE) {\n return;\n }\n System.arraycopy(src, 0, this.bytes, 0, SIZE);\n}\n"
|
"public void list() throws IOException {\n HttpServletRequest req = ServletActionContext.getRequest();\n HttpServletResponse resp = ServletActionContext.getResponse();\n int offset, pageSize;\n List<Module> moduleList = null;\n try {\n offset = Integer.parseInt(req.getParameter(\"String_Node_Str\"... |
"public boolean awaitCompletion(long timeout, TimeUnit timeUnit) throws InterruptedException {\n boolean result = completed.await(timeout, timeUnit);\n getFirstError();\n return result;\n}\n"
|
"public void testUpdateHeader() throws InterruptedException {\n TodoListHeader header = createHeader();\n repository.insert(header);\n Thread.sleep(200);\n repository.update(header.update(\"String_Node_Str\", 0, new Color(0), \"String_Node_Str\"));\n TodoListHeader fromDb = repository.getHeaderById(heade... |
"void drawFacesRaw(GLRenderer renderer, GL2 gl, RenderProps props, Material faceMaterial) {\n boolean useVertexColors = useVertexColouring;\n if (renderer.isSelecting()) {\n useVertexColors = false;\n }\n int type = -1;\n int lastType = -1;\n boolean lastSelected = false;\n int i = 0;\n f... |
"private void createPermutations(final Connection connection, final ObjectName objectName) {\n for (Attribute attribute : attributes) {\n if (connection.getBeanAliases().contains(attribute.getBeanAlias()) && attribute.getObjectName().apply(objectName)) {\n List<AttributePermutation> permutations = ... |
"public static void createIndex(SamReader reader, File output, Log log) {\n BAMIndexer indexer = new BAMIndexer(output, reader.getFileHeader());\n long totalRecords = 0;\n for (SAMRecord rec : reader) {\n if (++totalRecords % 1000000 == 0) {\n if (null != log)\n log.info(totalR... |
"public void onNotificationUpdated(NotificationData.Entry entry) {\n mStatusBarNotification = entry.notification;\n mBeforeN = entry.targetSdk < Build.VERSION_CODES.N;\n updateSingleLineView();\n applyRemoteInput(entry);\n selectLayout(false, true);\n if (mContractedChild != null) {\n mContract... |
"protected boolean onStateChange(int[] stateSet) {\n boolean ret = false;\n if (mIconColor != null && mIconColor.isStateful()) {\n updateIconColor();\n ret = true;\n }\n if (mTint != null && mTintMode != null) {\n mTintFilter = updateTintFilter(mTint, mTintMode);\n invalidateSelf... |
"final boolean update(double timeStep, long currentTime) {\n if (!m_manager.isAny(SCANNING, STARTING_SCAN)) {\n m_timeNotScanning += timeStep;\n }\n boolean stopClassicBoost = false;\n if (m_manager.is(BOOST_SCANNING)) {\n m_timeClassicBoosting += timeStep;\n if (m_timeClassicBoosting >... |
"private double calculateSetCoverage(String problem, String algorithmA, String algorithmB) {\n double result = 5.5;\n SetCoverage setCoverageMetric = new SetCoverage();\n Vector<Double> values = new Vector<Double>(experiment_.getIndependentRuns());\n for (int i = 0; i < experiment_.getIndependentRuns(); i++... |
"public Object clone(Workspace workspace) throws CloneNotSupportedException {\n try {\n workspace().getReadAccess();\n Entity newEntity = (Entity) super.clone(workspace);\n newEntity._portList = new NamedList(newEntity);\n Iterator ports = portList().iterator();\n while (ports.hasN... |
"public void mousePressed(MouseEvent e) {\n if (model == null) {\n return;\n }\n int x = e.getX();\n latestMousePositionX = x;\n currentMousePositionX = latestMousePositionX;\n int r = 16;\n if (currentState == TimelineState.IDLE) {\n int position = inPosition(x, r);\n switch(p... |
"public boolean onMachineActivated(World world, int x, int y, int z, EntityPlayer entityPlayer, int side, float hitX, float hitY, float hitZ) {\n if (entityPlayer != null) {\n if (entityPlayer.inventory.getCurrentItem() == null || entityPlayer.inventory.getCurrentItem().itemID != ICBMSentry.blockTurret.blockI... |
"public static ColumnsInfo createTable(ITableContent table, int width, int dpi, boolean autoExtend) {\n int tableWidth = getElementWidth(table, width, dpi);\n int columnCount = table.getColumnCount();\n if (columnCount == 0) {\n return null;\n }\n int[] columns = new int[columnCount];\n int una... |
"public EnhanceEntity findById(Object primaryKey, EntityMetadata m, List<String> relationNames, Client client) {\n try {\n Object o = client.find(m.getEntityClazz(), m, primaryKey, relationNames);\n if (o == null) {\n return null;\n } else {\n return o instanceof EnhanceEnt... |
"private void setupViewPager(ViewPager viewPager) {\n ViewPagerAdapter adapter = new ViewPagerAdapter(getChildFragmentManager());\n RegisteredGiftsFragment registeredGiftsFragment = new RegisteredGiftsFragment();\n DonatedGiftsFragment donatedGiftsFragment = new DonatedGiftsFragment();\n ReceivedGiftsFragme... |
"private String getOriginalColumnName(String entryName, DbMapComponent component, ExternalDbMapTable table) {\n List<IConnection> inputConnections = (List<IConnection>) component.getIncomingConnections();\n if (inputConnections != null) {\n for (IConnection iconn : inputConnections) {\n IMetadat... |
"public boolean isAlreadyBuilt(IBuilderContext context, BlockPos pos) {\n Block block = context.world().getBlockState(pos).getBlock();\n return block == Blocks.GRAVEL;\n}\n"
|
"public Double getVertexScore(Vertex v) {\n Scores scores = hits.getVertexScore(v);\n double authority = Graphs.vertexHasNoNeighbours(v) ? 0 : scores.authority;\n return authority;\n}\n"
|
"public void run() {\n sendPacket(new PacketPlayOutPlayerInfo(EnumPlayerInfoAction.REMOVE_PLAYER, fakePlayer));\n}\n"
|
"public static void saveArenaToFile(JavaPlugin plugin, String arena) {\n File f = new File(plugin.getDataFolder() + \"String_Node_Str\" + arena);\n Cuboid c = new Cuboid(Util.getComponentForArena(plugin, arena, \"String_Node_Str\"), Util.getComponentForArena(plugin, arena, \"String_Node_Str\"));\n Location sta... |
"private void createJavaProjectIfNotExists(final String projectName) {\n final Path projectFilePath = workspacePath().resolve(projectName).resolve(\"String_Node_Str\");\n if (!Files.isRegularFile(projectFilePath, LinkOption.NOFOLLOW_LINKS)) {\n newJavaProject(projectName);\n }\n}\n"
|
"public void removeCandidate(Candidate candidate) {\n MethodData data = methodData.get(candidate.getMethod());\n data.getCandidates().remove(candidate);\n}\n"
|
"public Object exec(List list) throws TemplateModelException {\n if (list.size() < 1) {\n throw new TemplateModelException(\"String_Node_Str\");\n }\n Object object = BeansWrapper.getDefaultInstance().unwrap((TemplateModel) list.get(0));\n Collection<RESTResource> resourceList;\n if (object instan... |
"protected List<XmlAdapter> getAdapters() throws Exception {\n if (adapters == null) {\n adapters = new ArrayList<XmlAdapter>();\n for (ClassDescriptor desc : this.getJpaSession().getDescriptors().values()) {\n if (!desc.isAggregateCollectionDescriptor() && !desc.isAggregateDescriptor()) {\n... |
"public void onCreate() {\n super.onCreate();\n Log.d(TAG, \"String_Node_Str\");\n Thread.setDefaultUncaughtExceptionHandler(new ExceptionHandler());\n PreferenceManager.setDefaultValues(this, R.xml.whereyougo_preferences, false);\n Preferences.init(this);\n Configuration config = getBaseContext().get... |
"public String toString() {\n return super.toJson();\n}\n"
|
"public void run() {\n while (true) {\n List<Runnable> nextList;\n synchronized (agentLock) {\n nextList = queue;\n if (nextList.isEmpty()) {\n taskWorkers.remove(mapKey);\n break;\n } else {\n queue = new LinkedList<Runnable... |
"public Response getSpaceActivitiesById(UriInfo uriInfo, String id, int offset, int limit, long before, long after, boolean returnSize, String expand) throws Exception {\n String authenticatedUser = ConversationState.getCurrent().getIdentity().getUserId();\n SpaceService spaceService = CommonsUtils.getService(Spa... |
"public Object[] getChildren(Object parentElement) {\n TableNode tableNode = (TableNode) parentElement;\n List<TableNode> child = tableNode.getChildren();\n boolean extended = false;\n if (!child.isEmpty()) {\n for (TableNode node : child) {\n if (node.getType() == TableNode.TABLE) {\n ... |
"private StringBuilder initCache(String NUM_METHODS) {\n Vector<Object> cacheElems = new Vector<Object>();\n for (int i = 0; i < cache.getNumBlocks(); i++) cacheElems.add(NUM_METHODS);\n cacheElems.set(blocksOf(0) - 1, 0);\n return CacheSimBuilder.constArray(cacheElems);\n}\n"
|
"public void onClick(DialogInterface dialog, int id) {\n dismiss();\n Calendar selectedCal = Calendar.getInstance(TimeZone.getDefault());\n selectedCal.set(mDatePicker.getYear(), mDatePicker.getMonth(), mDatePicker.getDayOfMonth());\n if (mExpiryCal != null) {\n long numDays = (selectedCal.getTimeInM... |
"public void testGetTeams() throws InterruptedException, TimeoutException, ExecutionException {\n try {\n handler.getTeams(SUMMONER_ID_1).get(1, MINUTES);\n handler.getTeams(TEAM_ID).get(1, MINUTES);\n } catch (RequestException ex) {\n if (isNotServerside(ex))\n throw ex;\n }\n}... |
"public static JMethodCall transformToNullMethodCall(JMethodCall x, JProgram program) {\n JExpression instance = x.getInstance();\n List<JExpression> args = x.getArgs();\n if (program.isStaticImpl(x.getTarget())) {\n instance = args.get(0);\n args = args.subList(1, args.size());\n } else {\n ... |
"private String retrieveContentObjectXMLorJSONByIdOrSystemName(String contentObjectIdOrSystemName, String commaDelimitedProjectionPaths, Output output, Date lastModified, boolean prettyPrint) {\n try {\n ContentObject contentObject = null;\n if (StringUtils.isBlank(commaDelimitedProjectionPaths)) {\n ... |
"String getValue(Node node){\n\tif (node != null && node.getType() == Node.Nonterminal){\n\t\twhile (node.getType == Cast){\n\t\t\tnode = node.getCast();\n\t\t}\n\t\treturn node.getValue();\n\t}\n\telse if (node != null && node.getType() == Node.Terminal){\n\t\treturn node.getValue();\n\t}\n\treturn \"null\";\n}\n"
|
"public void onBlockPlace(BlockPlaceEvent event) {\n if (event.isCancelled())\n return;\n if (parent.getPlacedBlockAt(event.getBlock().getLocation(), true) == null) {\n PlacedBlock pBlock = new PlacedBlock(event.getPlayer(), event.getBlock());\n parent.getDatabase().save(pBlock);\n } else\... |
"public int compareTo(LogEntry that) {\n return ComparisonChain.start().compare(this.getMessageOrPattern(), that.getMessageOrPattern(), AbstractTreeLogger.LOG_LINE_COMPARATOR).compare(this.type, that.type).result();\n}\n"
|
"private void logDebugNormalApi() {\n root.debug(\"String_Node_Str\", 1, 2, 3);\n root.debug(\"String_Node_Str\", 2, 3);\n root.debug(null, 5, 6);\n root.debug(\"String_Node_Str\", 7, 8, 9, 10);\n}\n"
|
"public Integer value() {\n if (nodeService.info().getHttp() == null) {\n return null;\n }\n return portFromAddress(nodeService.info().getHttp().address().publishAddress());\n}\n"
|
"public RenderedImage decodeAsRenderedImage(int page) throws IOException {\n if (page != 0) {\n throw new IOException(JaiI18N.getString(\"String_Node_Str\"));\n }\n try {\n return new PNGImage(input, (PNGDecodeParam) param);\n } catch (Exception e) {\n throw CodecUtils.toIOException(e);... |
"private void compareResult(DatabaseConnectionItem newConnectionItem, DatabaseConnectionItem oldConnectionItem) {\n Connection newConnection = newConnectionItem.getConnection();\n Connection oldConnection = oldConnectionItem.getConnection();\n Assert.assertTrue(newConnection != null);\n Assert.assertTrue(ne... |
"public SparseVector saxpyPlusConstant(double scalar, Vector vector) {\n if (vector.size() + 1 != this.size())\n throw new IllegalArgumentException(\"String_Node_Str\");\n SparseVector resultVector;\n if (vector.type() == VectorType.SPARSE) {\n int[] newIndexes = new int[numberOfNonzeroEntries + ... |
"private void updateGeolocationGrid() {\n final MetadataElement targetOrigProdRoot = AbstractMetadata.getOriginalProductMetadata(targetProduct);\n MetadataElement[] elements = getElementsToUpdate(targetOrigProdRoot, \"String_Node_Str\");\n for (MetadataElement e : elements) {\n final String imageNum = e... |
"private void onCompoundKey(TableInfo tableInfo) {\n CQLTranslator translator = new CQLTranslator();\n String columnFamilyQuery = CQLTranslator.CREATE_COLUMNFAMILY_QUERY;\n columnFamilyQuery = StringUtils.replace(columnFamilyQuery, CQLTranslator.COLUMN_FAMILY, translator.ensureCase(new StringBuilder(), tableIn... |
"void setRenderingDirty() {\n if (isHidden)\n return;\n if (foregroundRenderers != null) {\n for (ALayoutRenderer renderer : foregroundRenderers) {\n renderer.setDisplayListDirty(true);\n }\n }\n if (backgroundRenderers != null) {\n for (ALayoutRenderer renderer : back... |
"protected String[] simpleTestEntryPoint() {\n return new String[] { \"String_Node_Str\" + getTestName().substring(4) };\n}\n"
|
"public static String SHA512(String text) {\n byte[] sha1hash = new byte[40];\n try {\n MessageDigest messageDigest = MessageDigest.getInstance(\"String_Node_Str\");\n messageDigest.update(text.getBytes(\"String_Node_Str\"));\n byte[] digestBytes = messageDigest.digest();\n String hex ... |
"public void executeScheduledTasks() {\n final LocalDate date = dateTimeProvider.getCurrentDate();\n final String hostName = Hosts.getLocalHost().getHostName();\n for (final DailyScheduledTask task : scheduledTasks) {\n if (!dailySchedulerDao.acquireDailyTask(date, task.getClass(), Hosts.getLocalHostNam... |
"public static void testInteractive(BTree<Integer, Integer> tree) {\n Scanner stdin = new Scanner(System.in);\n String line;\n String[] components;\n System.out.print(\"String_Node_Str\");\n while (stdin.hasNextLine()) {\n line = stdin.nextLine();\n components = line.split(\"String_Node_Str... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.