content stringlengths 40 137k |
|---|
"public static boolean rename(File src, String newName) {\n if (src == null || newName == null)\n return false;\n if (src.exists()) {\n File newFile = new File(src.getParent() + \"String_Node_Str\" + newName);\n if (newFile.exists())\n return false;\n Files.makeDir(newFile.g... |
"public void testPassThroughCacheMergePolicy() {\n String cacheName = randomMapName();\n Config config = newConfig();\n HazelcastInstance h1 = Hazelcast.newHazelcastInstance(config);\n HazelcastInstance h2 = Hazelcast.newHazelcastInstance(config);\n TestMemberShipListener memberShipListener = new TestMem... |
"protected static void initializeAndStartService(CConfiguration cConf) throws Exception {\n injector = Guice.createInjector(new ConfigModule(cConf), new DiscoveryRuntimeModule().getInMemoryModules(), new NonCustomLocationUnitTestModule().getModule(), new NamespaceClientRuntimeModule().getInMemoryModules(), new Syste... |
"public void setRenditionKindMapping(Map<String, List<String>> renditionKinds) {\n this.kindToThumbnailNames = renditionKinds;\n for (Entry<String, List<String>> entry : renditionKinds.entrySet()) {\n CMISRenditionKind kind = CMISRenditionKind.valueOfLabel(entry.getKey());\n for (String thumbnailNam... |
"public Shell createWindow(final Display display) {\n Shell activeShell = display.getActiveShell();\n int style = SWT.DIALOG_TRIM | SWT.MIN | SWT.MAX | SWT.RESIZE;\n if (activeShell == null) {\n mapperShell = new Shell(mapperShell, style);\n } else {\n mapperShell = new Shell(activeShell, styl... |
"public void onPersonSelected(Person person) {\n PersonDetailFragment personDetailFragment = getDetailFragment();\n long personID = person.getPersonID();\n int localTableBlogID = person.getLocalTableBlogId();\n boolean isFollower = person.isFollower();\n boolean isViewer = person.isViewer();\n if (per... |
"public TableCell<Profile.PairLogoRelativeRectangle, Boolean> call(TableColumn<Profile.PairLogoRelativeRectangle, Boolean> p) {\n return new LogoButtonCell(imageHandler, logoList, pservice, windowManager.getStage(), selectedProfile.getId(), previewLogo, txLogoName);\n}\n"
|
"public void startRequest(MRCRequest rq) {\n try {\n final openRequest rqArgs = (openRequest) rq.getRequestArgs();\n final VolumeManager vMan = master.getVolumeManager();\n final FileAccessManager faMan = master.getFileAccessManager();\n Path p = new Path(rqArgs.getPath());\n Volum... |
"public void testCreateModel() throws MLHttpClientException, IOException {\n createModel(analysisId, versionSetId);\n}\n"
|
"private void fixLongJumps(List<BuilderInstruction> instructions, LabelAssigner labelAssigner, StmtVisitor stmtV) {\n boolean hasChanged;\n l0: do {\n hasChanged = false;\n Map<Label, Integer> labelToInsOffset = new HashMap<Label, Integer>();\n for (int i = 0; i < instructions.size(); i++) {\... |
"public void undimBackground() {\n if (fileTable.hasFocus())\n newColor = backgroundColor;\n else\n scrollPane.getViewport().setBackground(unfocusedBackgroundColor);\n}\n"
|
"public <T> Queue<T> build() {\n return new BasicQueue<>(this.getName(), this.getPollWait(), this.getPollTimeUnit(), this.getEnqueueTimeout(), this.getEnqueueTimeoutTimeUnit(), this.getBatchSize(), this.getQueueClass(), this.isCheckIfBusy(), this.getSize(), this.getCheckEvery(), this.isTryTransfer(), this.getUnableT... |
"public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException {\n String sourceUrl = (String) request.getAttribute(AbstractGatewayFilter.SOURCE_REQUEST_CONTEXT_URL_ATTRIBUTE_NAME);\n String topologyName = getTopologyName(sourceUrl);\n String ser... |
"protected void configure() {\n bind(TableRefFactory.class).to(TableRefFactoryImpl.class).asEagerSingleton();\n int maxCriticalAttempts = 100;\n int maxInfrequentAttempts = 5;\n int maxFrequentAttempts = 100;\n int maxDefaultAttempts = 10;\n bind(Retrier.class).toInstance(new SmartRetrier(attempts -> ... |
"private void handleUrlSymlinkRequest(HttpExchange exchange, boolean internalCall, JSONObject internalResp, String linksToUrl) {\n try {\n String tailResources = getTailResourceUri(exchange, true);\n tailResources = getTailResourceUri(exchange, false);\n String thisUrl = linksToUrl + tailResourc... |
"private void updateMasterBroker(String serverName, String oldMasterBroker, String newMasterBroker) throws Exception {\n MQJMXConnectorInfo mqInfo = getMQJMXConnectorInfo(serverName, config, serverContext, domain, connectorRuntime);\n try {\n MBeanServerConnection mbsc = mqInfo.getMQMBeanServerConnection()... |
"public void testIssue290() throws Exception {\n String mapName = \"String_Node_Str\";\n Config config = new XmlConfigBuilder().build();\n MapConfig mapConfig = new MapConfig();\n mapConfig.setName(mapName);\n mapConfig.setTimeToLiveSeconds(1);\n config.getMapConfigs().put(mapName, mapConfig);\n Ha... |
"public Object doPostServiceReference(HttpContext httpContext, HttpServletRequest request, String body) throws Exception {\n EasySOAApiSession api = EasySOALocalApiFactory.createLocalApi(SessionFactory.getSession(request));\n Map<String, String> params = getFirstValues(request.getParameterMap());\n try {\n ... |
"public void writePortableData(EntityPlayer player, NBTTagCompound tag) {\n if (!canPlayerAccess(player)) {\n return;\n }\n RedstoneControlHelper.setItemStackTagRS(tag, this);\n tag.setInteger(\"String_Node_Str\", frequency);\n tag.setByte(\"String_Node_Str\", modeItem);\n tag.setByte(\"String_... |
"private void onCompoundKey(TableInfo tableInfo) throws InvalidRequestException, TException, SchemaDisagreementException {\n CQLTranslator translator = new CQLTranslator();\n String columnFamilyQuery = CQLTranslator.CREATE_COLUMNFAMILY_QUERY;\n columnFamilyQuery = StringUtils.replace(columnFamilyQuery, CQLTran... |
"public void initializeNew() {\n if (!rootSchemaDef.hasStereotype(\"String_Node_Str\"))\n createStereotype(rootSchemaDef, \"String_Node_Str\", Fields.UNKNOWN, null);\n ProtocolHandlers<Protocol, Format> protocolHandlers = getProtocolHandlers();\n for (Protocol protocol : protocolHandlers.getProtocols())... |
"public void testFindByKernelBundle() {\n this.bundles = getBundles();\n this.regionBundleFindHook.find(getBundleContext(KERNEL_BUNDLE_INDEX), this.bundles);\n assertBundlePresent(SYSTEM_BUNDLE_INDEX, KERNEL_BUNDLE_INDEX);\n}\n"
|
"public void testLatchMigration() throws InterruptedException {\n TestHazelcastInstanceFactory factory = createHazelcastInstanceFactory(5);\n HazelcastInstance hz1 = factory.newHazelcastInstance(new Config());\n HazelcastInstance hz2 = factory.newHazelcastInstance(new Config());\n final ICountDownLatch latc... |
"public void testInheritanceQuery() {\n EntityManager em = createEntityManager();\n beginTransaction(em);\n LargeProject project = new LargeProject();\n em.persist(project);\n commitTransaction(em);\n clearCache();\n ClassDescriptor descriptor = getServerSession().getClassDescriptor(Project.class);... |
"protected void openAnotherVersion(final RepositoryNode node, final boolean readonly) {\n try {\n if (node.getObject() != null) {\n Item item = node.getObject().getProperty().getItem();\n IWorkbenchPage page = getActivePage();\n IEditorPart editorPart = null;\n Repo... |
"public static Object[] filterOutDuplicatedElems(XSDNamedComponent[] checkedElements) {\n List<XSDNamedComponent> list = new ArrayList<XSDNamedComponent>();\n for (XSDNamedComponent el : checkedElements) {\n boolean exist = false;\n for (XSDNamedComponent xsdEl : list) {\n if (xsdEl.getNa... |
"public Set<Entity> getCandidateEntities(String s) {\n Set<Entity> res = trie.get(s);\n return res == null ? new HashSet<Entity>() : trie.get(s);\n}\n"
|
"public void deviceInformationTypeTest4() {\n List<DeviceInformation> allDevicesInformation = message.devices;\n DeviceInformation deviceInformation = allDevicesInformation.get(5);\n assertEquals(DeviceType.ShutterContact, deviceInformation.getDeviceType());\n}\n"
|
"public boolean doInteraction(Object arg) {\n Configuration configuration = JDUtilities.getConfiguration();\n retries++;\n logger.info(\"String_Node_Str\" + retries);\n String ipBefore;\n String ipAfter;\n RouterData routerData = configuration.getRouterData();\n if (routerData == null) {\n t... |
"public void visit(ASTNode[] nodes, SourceUnit source) {\n checkNodesForAnnotationAndType(nodes[0], nodes[1]);\n ClassNode classNode = (ClassNode) nodes[1];\n if (!classNode.implementsInterface(MVC_HANDLER_TYPE)) {\n apply(classNode);\n }\n}\n"
|
"private void finishScanCycle() {\n LogManager.d(TAG, \"String_Node_Str\");\n try {\n mCycledLeScanCallback.onCycleEnd();\n if (mScanning) {\n if (getBluetoothAdapter() != null) {\n if (getBluetoothAdapter().isEnabled()) {\n long now = System.currentTimeM... |
"public void onCreate(Bundle savedInstanceState) {\n surveyManager = new SurveyManager(this);\n super.onCreate(savedInstanceState);\n lrzId = Utils.getSetting(this, Const.LRZ_ID, \"String_Node_Str\");\n registerReceiver(connectivityChangeReceiver, new IntentFilter(ConnectivityManager.CONNECTIVITY_ACTION));\... |
"public Usr addUser(String firstname, String lastname, String password, int pensum, SystemRole role, double holiday) throws WaktuGeneralException {\n EntityManager em = PersistenceController.getInstance().getEMF().createEntityManager();\n Usr newUsr = new Usr(generateUsername(firstname, lastname), firstname, last... |
"public void listContextsByPrefix(HttpRequest request, HttpResponder responder, final String scope, final String context, String search) throws IOException {\n try {\n if (search == null || !search.equals(\"String_Node_Str\")) {\n responder.sendJson(HttpResponseStatus.BAD_REQUEST, \"String_Node_Str... |
"public static EventHandlerChain<DeleteLoadbalancerEvent> onDeleteLoadbalancer() {\n return (new EventHandlerChainDelete()).build();\n}\n"
|
"public void onUpdate() {\n super.onUpdate();\n if (world.isRemote) {\n boolean hasFuel = (this.getLiquidAmount() > 0 || !Config.isFuelRequired(gauge));\n if (ConfigSound.soundEnabled) {\n if (this.horn == null) {\n this.horn = ImmersiveRailroading.proxy.newSound(this.getDe... |
"public PortletPreference[] getDefaultPreferences() {\n if (defaultPreferences == null) {\n PortletDD portletDD = getPortletDefinition();\n PortletPreferencesDD prefsDD = portletDD.getPortletPreferences();\n if (prefsDD != null) {\n List prefs = new ArrayList();\n for (Iter... |
"public int doWork(final List<String> args) {\n if (this.bedFile == null || !this.bedFile.exists()) {\n LOG.error(\"String_Node_Str\");\n return -1;\n }\n if (args.isEmpty()) {\n LOG.error(\"String_Node_Str\");\n return -1;\n }\n if (this.minCoverages.isEmpty()) {\n thi... |
"public synchronized void addDataSet(FlowerPower fp, String seriesId) throws Exception {\n if ((fp.getBatteryLevelTimestamp() > 0) && isEnabled(TIMESERIES_TYPE_BATTERY, seriesId)) {\n if (fp.getBatteryLevel() >= 0)\n seriesToBePersisted.get(TIMESERIES_TYPE_BATTERY + \"String_Node_Str\" + seriesId).... |
"private void createPropertyAccessor(ClassNode classNode, PropertyNode fxProperty, FieldNode fxFieldShortName, Expression initExp) {\n FieldExpression fieldExpression = new FieldExpression(fxFieldShortName);\n ArgumentListExpression ctorArgs = initExp == null ? ArgumentListExpression.EMPTY_ARGUMENTS : new Argumen... |
"public <E> List<E> doQuery(MappedStatement ms, Object parameterObject, RowBounds rowBounds, ResultHandler resultHandler, BoundSql boundSql) throws SQLException {\n Statement stmt = null;\n try {\n flushStatements();\n Configuration configuration = ms.getConfiguration();\n StatementHandler ha... |
"public String toString() {\n StringBuilder sb = new StringBuilder(\"String_Node_Str\");\n boolean first = true;\n for (int cnt = 0; cnt < end - start; cnt++) {\n if (!first) {\n sb.append(\"String_Node_Str\");\n } else {\n first = false;\n }\n sb.append(Intege... |
"public static INDArray toOffsetZeroCopy(INDArray arr) {\n if (arr.isRowVector()) {\n if (arr instanceof IComplexNDArray) {\n IComplexNDArray ret = Nd4j.createComplex(arr.shape());\n for (int i = 0; i < ret.length(); i++) ret.putScalar(i, ((IComplexNDArray) arr).getComplex(i));\n ... |
"private void processNodes(Element ele, boolean needEscape, HashMap cssStyles, IContent content) {\n int level = 0;\n for (Node node = ele.getFirstChild(); node != null; node = node.getNextSibling()) {\n if (node.getNodeName().equals(\"String_Node_Str\")) {\n if (node.getFirstChild() instanceof ... |
"public void refreshUsersList() {\n MXDataHandler dataHandler = (MXDataHandler) mDataHandler;\n Collection<User> users = dataHandler.getStore().getUsers();\n for (User user : users) {\n user.setDataHandler(dataHandler);\n }\n}\n"
|
"private final InsertImpl<R> values0(List<Field<?>> values) {\n if (fields.size() == 0) {\n fields.addAll(into.getFields());\n }\n if (fields.size() != values.size()) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n getDelegate().newRecord();\n for (int i = 0; i < field... |
"private void removeDecrCandidates(Continuation cont, RefCountType type, Set<Var> candidates) {\n if (type == RefCountType.READERS) {\n for (Var v : cont.requiredVars(false)) {\n candidates.remove(v);\n }\n }\n if (isForeachLoop(cont)) {\n AbstractForeachLoop loop = (AbstractFor... |
"public void configure(Set<Parameter> stepParameters) throws EoulsanException {\n for (Parameter p : stepParameters) {\n if (FORMAT_PARAMETER.equals(p.getName())) {\n final DataFormatRegistry registry = DataFormatRegistry.getInstance();\n for (String formatName : Splitter.on(',').split(p... |
"public int[] getColumnCoordinatesInRange(int start, int end) {\n int startColumnIndex = getColumnIndexByCoordinate(start);\n int endColumnIndex = getColumnIndexByCoordinate(end);\n List<Integer> list = columnCoordinates.subList(startColumnIndex, endColumnIndex + 1);\n int length = list.size();\n int[] c... |
"public boolean onPreferenceChange(Preference preference, Object newValue) {\n float min = Float.parseFloat((String) newValue);\n float max = Float.parseFloat(terrainMaxPreference.getValue());\n if (min > max) {\n terrainMaxPreference.setValue(terrainMinPreference.getValue());\n }\n return true;\n... |
"public void loadImage() {\n if (image_url.startsWith(\"String_Node_Str\")) {\n closeAsync();\n localAsync = new LocalAsync();\n localAsync.execute(image_url);\n getActivity().invalidateOptionsMenu();\n } else if (image_url.startsWith(\"String_Node_Str\")) {\n Bitmap selectedBit... |
"protected BoundingBox computeBox(IDisplayServer xs, RunTimeContext rtc) throws ChartException {\n Label la = getLabel().copyInstance();\n final String sPreviousValue = la.getCaption().getValue();\n la.getCaption().setValue(rtc.externalizedMessage(sPreviousValue));\n la.setEllipsis(1);\n Map<Label, Label... |
"protected boolean visit(IResourceDelta delta, Collection<Runnable> runnables) {\n VisitResourceHelper visitHelper = new VisitResourceHelper(delta);\n boolean merged = ProjectRepositoryNode.getInstance().getMergeRefProject();\n Set<RepositoryNode> topLevelNodes = getTopLevelNodes();\n boolean visitChildren ... |
"public void clearCraftingGrid() {\n for (int i = 0; i < 9; i++) {\n inventory[getMatrixOffset() + i] = null;\n }\n PacketHandler.sendToServer(CoFHTileInfoPacket.getTileInfoPacket(this).addByte(PacketInfoID.CLEAR_GRID.ordinal()));\n}\n"
|
"public void testGetJsonWithResources() throws NoSuchFieldException, ClassNotFoundException {\n IdsHelper.loadValues(com.scurab.android.anuitorsample.R.class);\n String s = IdsHelper.toJson(Robolectric.application.getResources());\n HashMap hashMap = new Gson().fromJson(s, HashMap.class);\n List<LinkedTreeM... |
"public StringBuilder toString(StringBuilder sb) {\n sb.append(\"String_Node_Str\");\n sb.append(\"String_Node_Str\");\n if (resourceDef != null) {\n resourceDef.toString(sb);\n }\n sb.append(\"String_Node_Str\");\n sb.append(\"String_Node_Str\");\n if (policyResource != null) {\n pol... |
"private FetchResult fetch(Git git, String label) {\n FetchCommand fetch = git.fetch();\n fetch.setRemote(\"String_Node_Str\");\n fetch.setTagOpt(TagOpt.FETCH_TAGS);\n setTimeout(fetch);\n try {\n setCredentialsProvider(fetch);\n FetchResult result = fetch.call();\n if (result.getTra... |
"public int readInt() throws IOException {\n timeStart();\n try {\n int i = 0;\n i |= (readCacheByte() & 0xFF) << 24;\n i |= (readCacheByte() & 0xFF) << 16;\n i |= (readCacheByte() & 0xFF) << 8;\n i |= (readCacheByte() & 0xFF) << 0;\n return i;\n } finally {\n t... |
"public void unlock(CharSequence name) {\n long thread = Thread.currentThread().getId();\n Entry e = entries.get(name);\n if (e == null) {\n notifyListener(thread, name, PoolListener.EV_NOT_LOCKED);\n return;\n }\n if (e.owner == thread) {\n if (e.writer != null) {\n notif... |
"public void attributeChanged(Attribute attribute) throws IllegalActionException {\n if (attribute == directorClass) {\n Director director = getDirector();\n String className = directorClass.stringValue();\n if (director == null || !director.getClass().getName().equals(className)) {\n ... |
"public void testEncodedDefaultSignatureVerification() throws Exception {\n Signer signer = factory.getInstance(true, privateKey);\n Signer verifier = factory.getInstance(false, publicKey, signer.getEncoded());\n runTestSignatureVerification(signer, verifier);\n}\n"
|
"public void onMessage(String channel, String sender, String login, String hostname, String message) {\n if (message.trim().startsWith(pref)) {\n message = message.replaceFirst(Matcher.quoteReplacement(pref), \"String_Node_Str\");\n String[] parts = message.split(\"String_Node_Str\");\n String f... |
"public void afterFindBy(By by, WebElement element, WebDriver driver) {\n ((SearchingEventListener) dispatcher).afterFindBy(by, element, driver);\n}\n"
|
"protected void buildAndExecuteRestOfQuery(int userId, Filter filter, Set<Dimension> dimensions, final List<Bucket> buckets, StringBuilder from, StringBuilder columns, StringBuilder where, StringBuilder groupBy, int nextColumnIndex, Bundler valueBundler) {\n final List<Bundler> bundlers = new ArrayList<Bundler>();\n... |
"protected void act(Game game) {\n if (actions == null || actions.isEmpty()) {\n pass(game);\n } else {\n boolean usedStack = false;\n while (actions.peek() != null) {\n Ability ability = actions.poll();\n logger.info(new StringBuilder(\"String_Node_Str\").append(game.ge... |
"static final AutoScale computeScale(IDisplayServer xs, OneAxis ax, DataSetIterator dsi, int iType, double dStart, double dEnd, Scale scModel, AxisOrigin axisOrigin, FormatSpecifier fs, RunTimeContext rtc, int direction, double zoomFactor, int iMarginPercent) throws ChartException {\n final Label la = ax.getLabel();... |
"public JsonNode migrate(final JsonNode input) throws SwaggerTransformException {\n Objects.requireNonNull(input, \"String_Node_Str\");\n final ObjectNode ret = input.deepCopy();\n JsonNode node;\n for (final String memberName : memberNames) {\n node = input.path(memberName);\n if (node.isMiss... |
"public boolean needsToCache(IBaseDataSetDesign dataSetDesign, int cacheOption, int alwaysCacheRowCount) {\n return needsToDteCache() || DataSetCacheUtil.needsToCache(dataSetDesign, cacheOption, alwaysCacheRowCount);\n}\n"
|
"public void testSimple() {\n ApplicationContext applicationContext = new ClassPathXmlApplicationContext(\"String_Node_Str\");\n IdService idService = (IdService) applicationContext.getBean(\"String_Node_Str\");\n long id = idService.genId();\n Id ido = idService.expId(id);\n long id1 = idService.makeId(... |
"private String getCompletedStringForQuantiles(Indicator indicator, Expression sqlExpression, String colName, String table, List<String> whereExpression) throws AnalysisExecutionException {\n String catalogOrSchema = getCatalogOrSchemaName(indicator.getAnalyzedElement());\n long count = getCount(cachedAnalysis, c... |
"private void parseAttribute(final Attributes atts, final String attrName) throws SAXException {\n String attrValue = atts.getValue(attrName);\n String filename = null;\n final String attrClass = atts.getValue(ATTRIBUTE_NAME_CLASS);\n final String attrScope = atts.getValue(ATTRIBUTE_NAME_SCOPE);\n final ... |
"public String toString() {\n if (this.indexes.size() == 0) {\n return \"String_Node_Str\";\n }\n final StringBuffer buf = new StringBuffer();\n for (int i = 0; i < indexes.size(); i++) {\n if (buf.length() == 0) {\n buf.append(\"String_Node_Str\");\n } else {\n bu... |
"public void testOneThreadGetRelease() throws Exception {\n final JournalMetadata<?> m = theFactory.getConfiguration().buildWithRootLocation(new JournalStructure(\"String_Node_Str\").$date(\"String_Node_Str\").$());\n CachingWriterFactory wf = theFactory.getCachingWriterFactory();\n JournalWriter x;\n Journ... |
"public ScriptInfo generateScriptInfo(SourceGeneratorLocalData localData, List<GraphTargetItem> commands) throws ParseException, CompilationException {\n ScriptInfo si = new ScriptInfo();\n localData.currentScript = si;\n Trait[] traitArr = generateTraitsPhase1(null, null, false, localData, commands, si.traits... |
"public void onDataConnectionStateChanged(int state, int networkType) {\n mDataState = state;\n updateDataNetType(networkType);\n updateDataIcon();\n updateSignalStrength();\n}\n"
|
"public boolean isSymmetric(OWLObjectProperty property) {\n String query = \"String_Node_Str\" + property.toStringID() + \"String_Node_Str\" + OWL2.SymmetricProperty.getURI() + \"String_Node_Str\";\n return qef.createQueryExecution(query).execAsk();\n}\n"
|
"protected void prepareQuery() throws DataException {\n try {\n IBinding[] bindings = null;\n if (this.queryDefn.getSourceQuery() instanceof SubqueryLocator) {\n IQueryDefinition baseQueryDefn = getBaseQueryDefinition((SubqueryLocator) (queryDefn.getSourceQuery()));\n if (engine.g... |
"private void setlocal(LuaState vm) {\n LuaState threadVm = vm;\n if (vm.gettop() >= 5) {\n threadVm = vm.checkthread(2).vm;\n vm.remove(2);\n }\n int level = vm.checkint(2);\n int local = vm.checkint(3);\n vm.settop(4);\n LString name = setlocal(threadVm, threadVm.cc - (level - 1), l... |
"protected void updatePublicContentView(Entry entry, StatusBarNotification sbn) {\n final RemoteViews publicContentView = entry.cachedPublicContentView;\n View inflatedView = entry.getPublicContentView();\n if (entry.autoRedacted && publicContentView != null && inflatedView != null) {\n final boolean di... |
"public RandomAccessView get(DataOutput out, int offset, int length) throws IOException {\n if (offset >= 0 && offset < this.size && length >= 0 && offset + length < this.size) {\n out.write(this.memory, this.offset + offset, length);\n return this;\n } else {\n throw new IndexOutOfBoundsExce... |
"protected void beforeHookedMethod(MethodHookParam param) throws Throwable {\n XSharedPreferences prefs = new XSharedPreferences(nlpFix.class.getPackage().getName());\n prefs.reload();\n String wakeLockName = (String) param.args[2];\n if (wakeLockName.equals(\"String_Node_Str\")) {\n int collectorMax... |
"public static int[] convertNameToCoordinates(String namedCoordinate) {\n if (StringUtils.equalsIgnoreCase(namedCoordinate, \"String_Node_Str\")) {\n return new int[] { BOARD_SIZE, BOARD_SIZE };\n } else {\n int x = alphabet.indexOf(namedCoordinate.charAt(0));\n if (x < 0) {\n retu... |
"public void testAcsii() throws IOException {\n ByteArrayOutputStream bos = new ByteArrayOutputStream();\n TableFormatterConfig config = new TableFormatterConfig(Locale.US, \"String_Node_Str\");\n AsciiTableFormatterFactory factory = new AsciiTableFormatterFactory();\n try (TableFormatter formatter = factor... |
"protected boolean calculateEnabled() {\n if (getSelectedObjects().isEmpty()) {\n return false;\n }\n Object s = getSelectedObjects().get(0);\n if (s instanceof List && !((List) s).isEmpty()) {\n List selectedarts = (List) s;\n Object obj = selectedarts.get(selectedarts.size() - 1);\n ... |
"private void printCube(CubeCursor cursor, List columnEdgeBindingNames, List rowEdgeBindingNames, String measureBindingNames, String columnAggr, String rowAggr, String overallAggr) throws Exception {\n this.printCube(cursor, columnEdgeBindingNames, rowEdgeBindingNames, measureBindingNames, columnAggr, rowAggr, overa... |
"public void setState(boolean showing) {\n cancel();\n boolean animate = curPanel.isAnimationEnabled;\n if (curPanel.animType != AnimationType.CENTER && !showing) {\n animate = false;\n }\n this.showing = showing;\n if (showing) {\n nativePreviewHandlerRegistration = Event.addNativePrevi... |
"private void startAppFreezingScreenLocked(AppWindowToken wtoken) {\n if (DEBUG_ORIENTATION)\n logWithStack(TAG, \"String_Node_Str\" + wtoken.appToken + \"String_Node_Str\" + wtoken.hidden + \"String_Node_Str\" + wtoken.mAppAnimator.freezingScreen);\n if (!wtoken.hiddenRequested) {\n if (!wtoken.mAp... |
"public void Annotate(String description, Location loc) throws Exception {\n Date now;\n if (useSatelliteTime) {\n now = new Date(loc.getTime());\n } else {\n now = new Date();\n }\n String dateTimeString = Utilities.GetIsoDateTime(now);\n Gpx10AnnotateHandler annotateHandler = new Gpx10... |
"public void addFunds(FundsAddedCommand command) {\n Request request = requestRepository.findOne(command.getRequestId()).orElseThrow(() -> new RuntimeException(\"String_Node_Str\"));\n Fund fund = Fund.builder().amountInWei(command.getAmountInWei()).requestId(command.getRequestId()).token(command.getToken()).time... |
"public MapKey withKeyAsLong(long value) {\n key.startAddress = kPos;\n key.appendAddress = kPos + keyDataOffset;\n if (key.appendAddress + 8 > kLimit) {\n resize(8);\n }\n Unsafe.getUnsafe().putLong(key.appendAddress, value);\n key.appendAddress += 8;\n return key;\n}\n"
|
"void updateGridLabels(double startValue, double endValue, double gridDensity, GridScaleType scale_mode) {\n int scale_mode_id = scale_mode.getValue();\n double[][] gridPoints = gridPointsArray[scale_mode_id];\n StringBuilder[] gridPointsStr = gridPointsStrArray[scale_mode_id];\n double[] oldGridPointBounda... |
"public String toConf() {\n StringBuffer buf = new StringBuffer();\n if (value != null) {\n buf.append(getName());\n buf.append('=');\n if (allowsContinuation()) {\n String text = getConfValue(value);\n String[] lines = StringUtil.splitAll(text, '\\n');\n for ... |
"private void findPose() {\n final List<DMatch> matchesList = mMatches.toList();\n if (matchesList.size() < 4) {\n return;\n }\n List<KeyPoint> referenceKeypointsList = mReferenceKeypoints.toList();\n List<KeyPoint> sceneKeypointsList = mSceneKeypoints.toList();\n double maxDist = 0.0;\n dou... |
"public boolean isGivenTimestampInSelectedWindow(long timestamp) {\n boolean returnedValue = true;\n if ((timestamp < fullExperimentCanvas.getCurrentWindow().getTimestampOfLeftPosition()) || (timestamp > fullExperimentCanvas.getCurrentWindow().getTimestampOfRightPosition())) {\n returnedValue = false;\n ... |
"protected void _updateOutputTokenProductionRates(TypedCompositeActor actor) throws IllegalActionException {\n Iterator refineOutPorts = actor.outputPortList().iterator();\n ComponentEntity refineOutPortContainer = (ComponentEntity) actor.getContainer();\n while (refineOutPorts.hasNext()) {\n IOPort ref... |
"private void collectDumpInfoFromParcelFLOCK(Parcel in, PrintWriter pw, String date, boolean isCompactOutput) {\n StringBuilder sb = new StringBuilder(512);\n if (isCompactOutput) {\n sb.append(\"String_Node_Str\");\n sb.append(CHECKIN_VERSION);\n sb.append(',');\n } else {\n sb.app... |
"public LinkedList<ForgeDirection> getPossibleMovements(EntityData data) {\n LinkedList<ForgeDirection> result = new LinkedList<ForgeDirection>();\n data.blacklist.add(data.input.getOpposite());\n for (ForgeDirection o : ForgeDirection.VALID_DIRECTIONS) {\n if (!data.blacklist.contains(o) && container.p... |
"protected Statement visitMsgFallbackGroupNode(MsgFallbackGroupNode node) {\n MsgNode msg = node.getMsg();\n MsgPartsAndIds idAndParts = MsgUtils.buildMsgPartsAndComputeMsgIdForDualFormat(msg);\n ImmutableList<String> escapingDirectives = node.getEscapingDirectiveNames();\n Statement renderDefault = getMsgC... |
"protected ATTRIBUTE_ITEM getItem(String[] attributePath, boolean create) {\n ATTRIBUTE_ITEM item = null;\n CoreAttributeGroup<ATTRIBUTE_ITEM, DESCRIPTOR> currentGroup = (CoreAttributeGroup) this;\n for (int index = 0; index < attributePath.length; index++) {\n String attrName = attributePath[index];\n ... |
"public void sendToAll(FMLProxyPacket pkt) {\n channels.get(Side.SERVER).attr(FMLOutboundHandler.FML_MESSAGETARGET).set(FMLOutboundHandler.OutboundTarget.ALL);\n channels.get(Side.SERVER).writeAndFlush(pkt).addListener(ChannelFutureListener.FIRE_EXCEPTION_ON_FAILURE);\n}\n"
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.