content
stringlengths
40
137k
"public void showSetPinDialog(final Activity activity, final Optional<Runnable> afterDialogClosed) {\n if (this.getMetadataStorage().getMasterSeedBackupState() != MetadataStorage.BackupState.VERIFIED) {\n Utils.showSimpleMessageDialog(activity, R.string.pin_backup_first, afterDialogClosed.get());\n ret...
"private void createKeyspace() {\n try {\n CassandraCli.getClient().execute_cql3_query(ByteBuffer.wrap(\"String_Node_Str\".getBytes(\"String_Node_Str\")), Compression.NONE, ConsistencyLevel.ONE);\n } catch (Exception e) {\n }\n}\n"
"public void run(ProgressStatus progressStatus) {\n progressStatus.setDescription(\"String_Node_Str\");\n if (ProjectUtilities.isFromEsiServer(project.getPrimaryProject()) && EsiUtils.getLoggedUserName() == null) {\n Utils.guilog(\"String_Node_Str\");\n return;\n }\n try {\n if (!Ticket...
"public FormStatus process(String actionName) {\n FormStatus retVal = null;\n if (actionName.equals(processActionName)) {\n ListComponent<Material> matList = (ListComponent<Material>) form.getComponent(matListId);\n ArrayList<Slab> slabs = new ArrayList<Slab>();\n for (Material mat : matList)...
"private LocalFolder scanFolder(Path path, boolean useCache) {\n LocalFolder folder = null;\n if (Files.isReadable(path) && Files.isExecutable(path)) {\n if (useCache && folderCache.containsKey(path)) {\n folder = folderCache.get(path);\n } else {\n LocalFolderScannerContext co...
"protected void saveReloadResult() {\n Item item = null;\n if (selectedObj instanceof Connection) {\n Connection con = (Connection) selectedObj;\n Property property = PropertyHelper.getProperty(con);\n if (property != null) {\n item = property.getItem();\n if (con.isCont...
"private void updateFileListModel(File currentlySelectedDirectory) {\n File[] filesToList = showFileListSorted(currentlySelectedDirectory);\n List<File> selectValuesListBeforeUpdate = fileList.getSelectedValuesList();\n listModelFiles.removeAllElements();\n for (File file : filesToList) {\n listModel...
"private void solve() {\n if (!preCheck()) {\n return;\n }\n HelicalRepeatUnit unit = new HelicalRepeatUnit(subunits);\n List<Point3d> repeatUnitCenters = unit.getRepeatUnitCenters();\n List<Point3d[]> repeatUnits = unit.getRepeatUnits();\n Set<List<Integer>> permutations = new HashSet<List<Int...
"private void testSecureStorePipeline(Engine engine, String prefix) throws Exception {\n ETLBatchConfig etlConfig = ETLBatchConfig.builder(\"String_Node_Str\").addStage(new ETLStage(\"String_Node_Str\", MockRuntimeDatasetSource.getPlugin(\"String_Node_Str\", \"String_Node_Str\" + prefix + \"String_Node_Str\"))).addS...
"private void async(final AsyncContext context, long userId) {\n context.setTimeout(ASYNC_TIMEOUT);\n HttpServletRequest req = (HttpServletRequest) context.getRequest();\n synchronized (ASYNC_SESSIONS) {\n if (Boolean.parseBoolean(req.getParameter(\"String_Node_Str\")) || !ASYNC_SESSIONS.containsKey(use...
"public void listChanged(ListEvent<S> listChanges) {\n updates.beginEvent(true);\n if (listChanges.isReordering()) {\n final int[] reorderMap = listChanges.getReorderMap();\n final List<E> originalMappedElements = new ArrayList<E>(mappedElements);\n for (int i = 0; i < reorderMap.length; i++)...
"private void runTestImpl(GWTTestCase testCase, TestResult testResult) throws UnableToCompleteException {\n if (mustNotExecuteTest(getBannedPlatforms(testCase.getClass(), testCase.getName()))) {\n return;\n }\n if (lastLaunchFailed) {\n throw new UnableToCompleteException();\n }\n String mo...
"public void die(Object cause) {\n super.die(cause);\n yell(\"String_Node_Str\");\n}\n"
"protected void saveUser() {\n String insertSql = \"String_Node_Str\";\n TransactionLegacy txn = TransactionLegacy.currentTxn();\n try {\n PreparedStatement stmt = txn.prepareAutoCloseStatement(insertSql);\n stmt.executeUpdate();\n } catch (SQLException ex) {\n s_logger.error(\"String_N...
"public String getTimeEnd(int stNum) {\n if (profileData != null && profileList.containsKey((Integer) stNum)) {\n return df.toDateTimeStringISO(profileList.get(stNum).getTime());\n } else {\n return ERROR_NULL_DATE;\n }\n}\n"
"public static List<RuleRepNode> getRuleRepNodes(IRepositoryNode parrentNode, boolean recursiveFind, boolean withDeleted) {\n List<RuleRepNode> result = new ArrayList<RuleRepNode>();\n if (parrentNode != null && (parrentNode instanceof RulesSQLFolderRepNode || parrentNode instanceof RulesSQLSubFolderRepNode || pa...
"private static void close(Closeable closeable) {\n if (closeable != null) {\n try {\n closeable.close();\n } catch (IOException ignore) {\n }\n }\n}\n"
"public void mouseMoved(MouseEvent e) {\n if (e.getSource() instanceof ResultTable) {\n ResultTable result = ((ResultTable) e.getSource());\n int column = result.columnAtPoint(e.getPoint());\n int row = result.rowAtPoint(e.getPoint());\n if (column == 0 && row >= 0 && row <= 9) {\n ...
"public boolean isValidValue(Double value) {\n double tolerance = 0.0001;\n return ((value >= lowerLimit - tolerance) && (value <= upperLimit + tolerance));\n}\n"
"private static Type structLoad(Context context, SwiftAST tree) throws UserException, TypeMismatchException {\n Type structType = findExprType(context, tree.child(0));\n String fieldName = tree.child(1).getText();\n Type fieldType;\n fieldType = findStructFieldType(context, fieldName, structType);\n if (...
"public void widgetSelected(SelectionEvent e) {\n boolean show = jobScriptButton.getSelection();\n addBSButton.setEnabled(show);\n addAntBSButton.setEnabled(addBSButton.getSelection());\n addMavenBSButton.setEnabled(addBSButton.getSelection());\n if (!show) {\n addAntBSButton.setEnabled(show);\n ...
"private List<Command> createRefreshingPropertiesCommand(RepositoryNode selectedNode, Node node) {\n List<Command> list = new ArrayList<Command>();\n if (selectedNode.getObject().getProperty().getItem() instanceof ConnectionItem) {\n String propertyId = selectedNode.getObject().getProperty().getId();\n ...
"public CompletableFuture<Boolean> replaceIssueLabels(TurboIssue issue, List<String> newLabels) {\n logger.info(\"String_Node_Str\" + issue + \"String_Node_Str\");\n if (!models.replaceIssueLabels(issue, newLabels)) {\n return CompletableFuture.completedFuture(false);\n }\n refreshUI();\n return u...
"public void testProject1() {\n Issue issue67 = issuesMap.get(67);\n Integer expectedProjectId = 25;\n String expectedProjectName = \"String_Node_Str\";\n Project actualProect = issue17611.getProject();\n assertNotNull(\"String_Node_Str\", actualProect);\n assertEquals(\"String_Node_Str\", expectedPro...
"private void updatePathwayDatasets() {\n pathwayDatasets.clear();\n pathwayDatasets.add(new GLElement() {\n protected void renderImpl(GLGraphics g, float w, float h) {\n g.drawText(\"String_Node_Str\", 0, -2, w, h);\n }\n }.setSize(150, 15));\n RadioController radio = new RadioCont...
"private void init() throws XMPPException {\n try {\n reader = new BufferedReader(new InputStreamReader(socket.getInputStream(), \"String_Node_Str\"));\n writer = new BufferedWriter(new OutputStreamWriter(socket.getOutputStream(), \"String_Node_Str\"));\n } catch (IOException ioe) {\n throw n...
"protected final <T extends Item> void deleteUniqueConstraintIndexes(final T item, final ItemConfiguration itemConfiguration, final Collection<PropertyDescriptor> constraintPropertyDescriptors) {\n if (constraintPropertyDescriptors.isEmpty()) {\n return;\n }\n for (final UniqueConstraint uniqueConstrain...
"public void initialize(Prevayler prevayler, CDBAccess cdbAccess, Context context, Logger logger, ManagerContainerServices managerContainerServices) {\n this.prevayler = prevayler;\n this.remoteDirectory = context;\n this.logger = logger;\n initializeDefaultConfiguration();\n if (cdbAccess != null)\n ...
"public void update() {\n super.update();\n if (brightness < 1.0f && brightness > MIN_BRIGHTNESS) {\n if ((brightness -= Game.elapsed) <= MIN_BRIGHTNESS) {\n brightness = MIN_BRIGHTNESS;\n }\n updateBrightness();\n }\n}\n"
"public Set<ModelContainerDefinition> getModelContainers(String databaseName) {\n Map<TypeName, ModelContainerDefinition> modelContainerDefinitionMap = modelContainers.get(databaseName);\n if (modelContainerDefinitionMap != null) {\n return Sets.newHashSet(modelContainers.get(databaseName).values());\n ...
"private void switchToModeForId(int id) {\n Fragment fragment;\n switch(id) {\n default:\n case R.id.nav_item_events:\n fragment = EventsByWeekFragment.newInstance(Constants.MAX_COMP_YEAR - mCurrentSelectedYearPosition);\n break;\n case R.id.nav_item_teams:\n ...
"public void testFindAllResourcesUnpaginated() {\n this.request(\"String_Node_Str\").jsonPost(new Sample(\"String_Node_Str\"));\n this.request(\"String_Node_Str\").jsonPost(new Sample(\"String_Node_Str\"));\n Response response = this.request(\"String_Node_Str\").setQueryParameter(\"String_Node_Str\", \"String_...
"public void process(ActionContext ac) throws Throwable {\n RequestIocContext reqContext = null;\n try {\n if (null != moduleObj) {\n ac.setModule(moduleObj);\n } else {\n Ioc ioc = ac.getIoc();\n if (null == ioc)\n throw Lang.makeThrow(\"String_Node_S...
"private void setDefaultPrivileges(Map<String, Boolean> defaultPrivileges) {\n for (Map.Entry<String, Boolean> entry : defaultPrivileges.entrySet()) {\n courseLevel.put(entry.getKey(), entry.getValue());\n }\n}\n"
"public void addAggregateOn(String aggreValue) {\n if (aggregateOn == null)\n aggregateOn = new ArrayList();\n aggregateOn.add(aggreValue);\n}\n"
"private String getAbsoluteConfDirPath(String dir, YamlConfig config) {\n String result = null, response = null;\n if (dir == null || dir.trim().isEmpty() || !dir.contains(\"String_Node_Str\")) {\n throw new IllegalArgumentException(error_message);\n }\n response = RemotingUtil.executeCommand(config,...
"private void updateCharts() {\n ConnectivityManager connectivityManager = (ConnectivityManager) getActivity().getSystemService(Context.CONNECTIVITY_SERVICE);\n NetworkInfo networkInfo = connectivityManager.getActiveNetworkInfo();\n if (networkInfo == null || !networkInfo.isConnected()) {\n Toast.makeTe...
"private ExecutionVertex getCandidateVertex(TraversalEntry te, boolean forward) {\n if (forward) {\n while (true) {\n if (this.confinedToStage && te.getCurrentChannel() == 0) {\n while (currentGateLeadsToOtherStage(te, this.forward)) {\n te.increaseCurrentGate();\n...
"public boolean equals(Object o) {\n return o == this || (o instanceof License && ((License) o).licenseTypes.equals(this.licenseTypes) && ((License) o).exceptions.equals(this.exceptions));\n}\n"
"public void onGoHomeClick(View v) {\n populateListView();\n}\n"
"public void inventoryClick(InventoryClickEvent event) {\n if (event.getRawSlot() < 0)\n return;\n if (event.getWhoClicked() instanceof Player) {\n Player p = (Player) event.getWhoClicked();\n if (state.containsKey(p.getName())) {\n TraderStatus trader = state.get(p.getName());\n ...
"public ShortPoint2D findBestConstructionPosition(AiStatistics aiStatistics, AbstractConstructionMarkableMap constructionMap, byte playerId) {\n AiPositions rivers = aiStatistics.getRiversForPlayer(playerId);\n if (rivers.size() == 0) {\n return null;\n }\n List<ScoredConstructionPosition> scoredCons...
"private void scanFile(final File file, final String absolutePath, final String relativePath, final boolean scanTimestampsOnly) throws IOException {\n lastModified = Math.max(lastModified, file.lastModified());\n if (!scanTimestampsOnly) {\n if (relativePath.endsWith(\"String_Node_Str\")) {\n tr...
"public void registerAliases(String packageName, Class<?> superType) {\n ResolverUtil<Class<?>> resolverUtil = new ResolverUtil<Class<?>>();\n resolverUtil.find(new ResolverUtil.IsA(superType), packageName);\n Set<Class<? extends Class<?>>> typeSet = resolverUtil.getClasses();\n for (Class<?> type : typeSet...
"private void renderEntry(IEntry entry, int index) {\n for (IEntryComposite entryTemp : entryMap.values()) {\n if (entryTemp.getEntry().equals(entry)) {\n return;\n }\n }\n IEntryComposite entryComposite = null;\n IEntryCompositeProvider provider = new DefaultEntryCompositeProvider(...
"public void getBlock() throws ConnectorException, IOException {\n int blockHeight = ontSdk.getConnectMgr().getBlockHeight();\n Block b = ontSdk.getConnectMgr().getBlock(blockHeight);\n Assert.assertNotNull(b);\n}\n"
"public void onClick(View v) {\n IconListPreference pref = (IconListPreference) mPreferenceGroup.findPreference(prefKey);\n if (pref == null)\n return;\n if (prefKey.equals(CameraSettings.KEY_CAMERA_ID)) {\n mUI.hideUI();\n }\n int index = pref.findIndexOfValue(pref.getValue());\n CharSe...
"public Entry next() {\n Entry e = super.shadowed;\n while (isBogus()) e = e.shadowed;\n return e;\n}\n"
"private String EinzelLinks(String url) {\n String links = \"String_Node_Str\";\n boolean fileDownloaded = false;\n if (!url.startsWith(\"String_Node_Str\")) {\n url = \"String_Node_Str\" + url;\n }\n try {\n if (!url.matches(\"String_Node_Str\")) {\n url = url.replaceAll(\"Strin...
"public boolean applies(GameEvent event, Ability source, Game game) {\n return event.getPlayerId().equals(source.getControllerId());\n}\n"
"public void execute(AdminCommandContext context) {\n ActionReport report = context.getActionReport();\n Logger logger = context.getLogger();\n logger.log(Level.INFO, Strings.get(\"String_Node_Str\", clusterName));\n if (!checkEnvAndParams()) {\n return;\n }\n gmsAdapter = gmsAdapterService.get...
"public static void main(String[] args) {\n int sceneWidth = 808;\n int sceneHeight = 808;\n int blockSide = 8;\n EventQueue.invokeLater(() -> {\n AlgoFrame frame = new AlgoFrame(\"String_Node_Str\", sceneWidth, sceneHeight);\n int N = sceneHeight / blockSide;\n int M = sceneWidth / blo...
"public void markProcessedTilesForRow(final int rowY, final RenderParameters renderParameters) {\n final int rowMaxY = rowY + boxHeight;\n if (rowY > currentRowY) {\n currentRowY = rowY;\n currentRowPartialTileSum = 0;\n }\n if (renderParameters != null) {\n for (TileSpec tileSpec : ren...
"private AResult testSelect(EndpointResult epr) {\n AResult result = new AResult();\n result.setEndpointResult(epr);\n long start = System.currentTimeMillis();\n try {\n QueryExecution qe = QueryManager.getExecution(epr.getEndpoint(), SELECTQUERY);\n boolean response = qe.execSelect().hasNext(...
"public String downloadFileFromServer(String url, String fileName) throws Exception {\n String localTmpDir = getLocalDownloadDirPath(true);\n String localDir = getLocalDownloadDirPath(false);\n RemoteUrl remoteUrl = new RemoteUrl(url, hostList);\n return restfulMgr.downloadFromServer(remoteUrl, fileName, lo...
"public void checkTypes(MarkerList markers, IContext context) {\n if (this.type != null) {\n this.type.checkType(markers, context, TypePosition.CLASS);\n }\n if (this.value != null) {\n this.value.checkTypes(markers, context);\n }\n}\n"
"protected void doWork() throws Throwable {\n componentService.validateProperty(getParameterName(), getSubProperties());\n}\n"
"public void setLocation(Location location) {\n this.location = location == null ? null : location.clone();\n if (offset != null && location != null) {\n this.location = location.add(offset);\n lastLocationUpdate = System.currentTimeMillis();\n }\n}\n"
"public void onBackPressed() {\n if (alertView != null && alertView.isShowing()) {\n alertView.dismiss();\n return;\n }\n anim(ivDetailedCard, getPosition(getIntent()), false, new Animation.AnimationListener() {\n public void onAnimationStart(Animation animation) {\n mLlDetailed...
"public void testSelenium() {\n System.getProperties().setProperty(\"String_Node_Str\", \"String_Node_Str\");\n Map<String, Object> contentSettings = new HashMap<String, Object>();\n contentSettings.put(\"String_Node_Str\", 2);\n Map<String, Object> preferences = new HashMap<String, Object>();\n preferen...
"public final void testServletInitAndConfig() throws ServletException {\n Injector injector = createMock(Injector.class);\n expect(injector.getBinding(Key.get(HttpServlet.class))).andReturn(createMock(Binding.class));\n final HttpServlet mockServlet = new HttpServlet() {\n };\n expect(injector.getInstanc...
"public void sortDifferential(StructureDefinition base, StructureDefinition diff, String name, List<String> errors) throws FHIRException {\n final List<ElementDefinition> diffList = diff.getDifferential().getElement();\n if (diffList.isEmpty())\n return;\n ElementDefinitionHolder edh = null;\n int i ...
"public void onEnable() {\n logger = this.getLogger();\n manager = new AnticheatManager(this);\n config = manager.getConfiguration();\n checkConfig();\n verbose = config.verboseStartup();\n updateFolder = config.updateFolder();\n if (verbose) {\n logger.log(Level.INFO, \"String_Node_Str\");\...
"private static Response makeURLConnectionRequest(RequestMethod method, String url, String params, String data) throws APIConnectionException, IOException {\n CloseableHttpResponse response = null;\n try {\n switch(method) {\n case GET:\n response = createGetConnection(url, params...
"public void run() {\n _native.setVisible(false);\n if (_native instanceof SwingSystemTrayMenuWindowsPopup) {\n ((SwingSystemTrayMenuWindowsPopup) _native).close();\n } else if (_native instanceof SwingSystemTrayMenuPopup) {\n ((SwingSystemTrayMenuPopup) _native).close();\n }\n SwingMenu pa...
"protected Manifest getManifest(ExportFileResource libResource, List<ProcessItem> itemToBeExport, String bundleName) throws IOException {\n Manifest manifest = new Manifest();\n Attributes a = manifest.getMainAttributes();\n String symbolicName = bundleName;\n Project project = ProjectManager.getInstance()....
"protected boolean _saveAs() {\n if (_tableau == null) {\n throw new InternalErrorException(\"String_Node_Str\");\n }\n JFileChooser fileDialog = new JFileChooser();\n if (_fileFilter != null) {\n fileDialog.addChoosableFileFilter(_fileFilter);\n }\n fileDialog.setDialogTitle(\"String_No...
"public synchronized void run() {\n if (eatTask.isActive())\n return;\n if (ticksWait > 0) {\n ticksWait--;\n return;\n }\n World world = bot.getWorld();\n MainPlayerEntity player = bot.getPlayer();\n System.out.println(\"String_Node_Str\");\n BlockLocation ourLocation = new Bl...
"public void testSort1() throws Exception {\n DataEngine engine = DataEngine.newDataEngine(DataEngineContext.newInstance(DataEngineContext.DIRECT_PRESENTATION, null, null, null));\n this.createCube(engine);\n ICubeQueryDefinition cqd = new CubeQueryDefinition(cubeName);\n IEdgeDefinition columnEdge = cqd.cr...
"public boolean add(T e) {\n boolean toRet = list.add(e);\n minModified = Math.min(minModified, size() - 1);\n maxModified = size();\n modified = true;\n return flush(toRet);\n}\n"
"public List<ExtractAndMoveMethodCandidateRefactoring> getExtractAndMoveMethodCandidateRefactorings() {\n List<ExtractAndMoveMethodCandidateRefactoring> extractMethodCandidateRefactoringList = new ArrayList<ExtractAndMoveMethodCandidateRefactoring>();\n Map<String, ArrayList<ExtractAndMoveMethodCandidateRefactori...
"public void write(FtpReply response) throws IOException {\n session.write(response);\n}\n"
"private void translateWhenInsideContainerChange(Phantom phantom) {\n Collection<Diff> changes = Collections2.filter(getDiffAncestors(phantom.getDifference()), new Predicate<Diff>() {\n\n public boolean apply(Diff difference) {\n return difference.getKind() == DifferenceKind.MOVE;\n }\n }...
"void checkIdleStates(int checkUserId) {\n if (!mAppIdleEnabled) {\n return;\n }\n final int[] userIds;\n try {\n if (checkUserId == UserHandle.USER_ALL) {\n userIds = ActivityManagerNative.getDefault().getRunningUserIds();\n } else {\n userIds = new int[] { checkU...
"public void testsimpleExp() {\n Boolean flag;\n flag = limiterUtils.getFinalresult(\"String_Node_Str\");\n assertEquals(\"String_Node_Str\", false, flag);\n flag = limiterUtils.getFinalresult(\"String_Node_Str\");\n assertEquals(\"String_Node_Str\", false, flag);\n flag = limiterUtils.getFinalresult(...
"private void definitelyDeleteBackspaceDeletedMediaItems() {\n for (String mediaId : mAztecBackspaceDeletedMediaItemIds) {\n if (!TextUtils.isEmpty(mediaId)) {\n MediaModel mediaModel = mMediaStore.getMediaWithLocalId(StringUtils.stringToInt(mediaId));\n if (mediaModel == null) {\n ...
"public void removeAttribute(String name) {\n Object value = null;\n boolean found = false;\n synchronized (attributesLock) {\n if (readOnlyAttributes.containsKey(name))\n return;\n found = attributes.containsKey(name);\n if (found) {\n value = attributes.get(name);\n...
"protected Dialog onCreateDialog(int id, Bundle args) {\n switch(id) {\n case DIALOG_WARNING:\n {\n CharSequence msg = args.getCharSequence(DeviceAdminReceiver.EXTRA_DISABLE_WARNING);\n AlertDialog.Builder builder = new AlertDialog.Builder(DeviceAdminAdd.this);\n ...
"protected final void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {\n try {\n resp.setContentType(APPLICATION_JSON);\n resp.setCharacterEncoding(CharsetUtil.UTF_8.name());\n resp.setHeader(HttpHeaders.Names.ACCESS_CONTROL_ALLOW_HEADERS, ALLOW_HE...
"public void initZygote(StartupParam startupParam) throws Throwable {\n mSettingHelper = new SettingHelper(new XSharedPreferences(Constant.PKG_NAME, SettingHelper.PREF));\n XposedBridge.hookAllConstructors(Activity.class, new XC_MethodHook() {\n protected void afterHookedMethod(MethodHookParam param) throw...
"protected void doRun() {\n ISelection selection = getSelection();\n if (selection == null) {\n return;\n }\n Object obj = ((IStructuredSelection) selection).getFirstElement();\n if (obj == null) {\n return;\n }\n RepositoryNode node = (RepositoryNode) obj;\n opendTextEditor(node);...
"public Object clone(Workspace workspace) throws CloneNotSupportedException {\n ExceptionEmailer newObject = (ExceptionEmailer) super.clone(workspace);\n newObject._newline = (Parameter) newObject.getAttribute(\"String_Node_Str\");\n newObject._newline.setExpression(\"String_Node_Str\");\n newObject._passwo...
"public void run() {\n try {\n try {\n if (Hosts.contains(Internets.localHostIdentifier())) {\n Hosts.remove(Internets.localHostIdentifier());\n }\n } catch (final Exception ex) {\n LOG.error(ex, ex);\n }\n hostMap.stop();\n } catch (fina...
"public Promise<QueryResponse, ResourceException> queryCollection(final Context context, final QueryRequest request, final QueryResourceHandler handler) {\n try {\n if (request.getQueryExpression() != null) {\n return new BadRequestException(HttpUtils.PARAM_QUERY_EXPRESSION + \"String_Node_Str\").a...
"public void testMageRingNetwork2() {\n addCard(Zone.BATTLEFIELD, playerA, \"String_Node_Str\", 1);\n addCounters(1, PhaseStep.UPKEEP, playerA, \"String_Node_Str\", CounterType.STORAGE, 4);\n addCard(Zone.BATTLEFIELD, playerA, \"String_Node_Str\", 1);\n addCard(Zone.BATTLEFIELD, playerA, \"String_Node_Str\"...
"private IQueryResults executeProcess(DataRequestSession session, ExecutionContext context) {\n errorList = new ArrayList();\n try {\n metaData = ((DataSetEditor) this.getContainer()).getCurrentItemModel();\n columnCount = metaData == null ? 0 : metaData.length;\n QueryDefinition query = new ...
"public ItemStack getCraftingResult(InventoryCrafting inventoryCrafting) {\n ItemStack stack = super.getCraftingResult(inventoryCrafting);\n if (stack != null) {\n NBTTagCompound tagCompound = getNBTFromObject(inventoryCrafting);\n if (tagCompound != null) {\n int damage = tagCompound.get...
"public void handleJoinedRoomSync(RoomSync roomSync, boolean isInitialSync) {\n RoomState liveState = getLiveState();\n String membership = null;\n RoomSummary currentSummary = null;\n mIsV2Syncing = true;\n RoomMember selfMember = getLiveState().getMember(mMyUserId);\n if (null != selfMember) {\n ...
"static byte[] rowAfterPrefix(byte[] prefix) {\n Preconditions.checkNotNull(prefix, \"String_Node_Str\");\n for (int i = prefix.length - 1; i >= 0; i--) {\n if (prefix[i] != (byte) 0xff) {\n byte[] after = Arrays.copyOf(prefix, i + 1);\n ++after[i];\n return after;\n ...
"public void onPlaceBlock(ActivateEvent event, EntityRef item) {\n if (!event.getTarget().exists()) {\n event.consume();\n return;\n }\n BlockItemComponent blockItem = item.getComponent(BlockItemComponent.class);\n BlockFamily type = blockItem.blockFamily;\n Side surfaceSide = Side.inDirect...
"public void run() {\n if (Config.movedPlayers.isEmpty() || server == null)\n return;\n for (Iterator<String> p = Config.movedPlayers.iterator(); p.hasNext(); ) {\n String playerName = p.next();\n Player player = server.getPlayer(playerName);\n p.remove();\n if (player == null |...
"public static SimplePathState getPathState(InferredPath path, Vector state) {\n Preconditions.checkArgument(!path.isNullPath() || state.getDimensionality() == 4);\n final Vector adjState = PathUtils.checkAndConvertState(state, path);\n return new SimplePathState(path, adjState);\n}\n"
"public static String encodeFromFile(String filename) {\n String encodedData = null;\n FileInputStream fileInputStream = null;\n BufferedInputStream bufferedInputStream = null;\n Base64InputStream base64InputStream = null;\n try {\n File file = new File(filename);\n byte[] buffer = new byte...
"public void onPlayerInteractEvent(PlayerInteractEvent event) {\n if (event instanceof PlayerInteractEvent.LeftClickBlock) {\n checkCreativeClick(event);\n }\n ItemStack heldItem = event.getEntityPlayer().getHeldItem(event.getHand());\n if (heldItem == null || heldItem.getItem() == null) {\n r...
"public void generateAnyObjectMapping(Property property, XMLDescriptor descriptor, NamespaceInfo namespaceInfo) {\n XMLAnyObjectMapping mapping = new XMLAnyObjectMapping();\n mapping.setAttributeName(property.getPropertyName());\n if (property.isMethodProperty()) {\n if (property.getSetMethodName() != n...
"private void writeSameStatNumber(int proNum, String fileName) {\n try {\n totalWriter.write(String.valueOf(proNum));\n totalWriter.write(String.valueOf(fileName.substring(0, fileName.indexOf(\"String_Node_Str\"))));\n totalWriter.write(String.valueOf(numCall));\n totalWriter.write(String...
"private void readLink(final XMLStreamReader reader, final EntityInfoAggregator eia, final EntityProviderReadProperties readProperties) throws EntityProviderException, XMLStreamException, EdmException {\n reader.require(XMLStreamConstants.START_ELEMENT, Edm.NAMESPACE_ATOM_2005, FormatXml.ATOM_LINK);\n final Strin...
"public double[] computeGradients() {\n CompletionService<double[]> completionService = new ExecutorCompletionService<double[]>(this.threadPool);\n this.subGradients = new SubGradient[this.threadCount];\n Random dropoutRandom = new Random();\n for (int i = 0; i < this.threadCount; i++) {\n if (this.s...
"public String getAttribute(Attribute attribute) {\n if (attribute == null) {\n return null;\n }\n if (attribute.startsWith(\"String_Node_Str\") || attribute.startsWith(\"String_Node_Str\")) {\n Material mat = item.getItemStack().getType();\n if (NMSHandler.getVersion().isAtLeast(NMSVersio...
"protected void createResultSection(Composite parent) {\n executeData = getAnalysisHandler().getExecuteData();\n graphicsAndTableSection = this.createSection(form, parent, DefaultMessagesImpl.getString(\"String_Node_Str\"), null);\n Composite sectionClient = toolkit.createComposite(graphicsAndTableSection);\n ...