content stringlengths 40 137k |
|---|
"public void setSparkContext() {\n if (JavaSparkProgram.class.isAssignableFrom(userJobClass)) {\n sparkContext = new JavaSparkContext();\n } else if (ScalaSparkProgram.class.isAssignableFrom(userJobClass)) {\n sparkContext = new ScalaSparkContext();\n scalaJobFlag = true;\n } else {\n ... |
"private boolean allParentTerminated(List<ApplicationChildContext> parentContexts, String instanceId) {\n boolean parentsTerminated = false;\n for (ApplicationChildContext context1 : parentContexts) {\n if (this.inactiveInstancesMap.containsKey(context1.getId()) && this.inactiveInstancesMap.get(context1.ge... |
"public Move getBestMove(MachineState state, Role role, long timeout) throws MoveDefinitionException, GoalDefinitionException, TransitionDefinitionException {\n t = new Timer((int) (timeout - System.currentTimeMillis()), TimeoutHandler);\n t.setRepeats(false);\n t.start();\n List<Move> moves = stateMachine.... |
"private ModDiscoverer identifyMods() {\n FMLLog.fine(\"String_Node_Str\", injectedContainers);\n mods.add(new InjectedModContainer(mcp, new File(\"String_Node_Str\")));\n File coremod = new File(minecraftDir, \"String_Node_Str\");\n for (String cont : injectedContainers) {\n ModContainer mc;\n ... |
"public void generateSnapshot(StructureDefinition base, StructureDefinition derived, String url, String profileName) throws DefinitionException, FHIRException {\n if (base == null)\n throw new DefinitionException(\"String_Node_Str\");\n if (derived == null)\n throw new DefinitionException(\"String_N... |
"private void processGlobalSimpleType(String targetNamespace, String defaultNamespace, SimpleType simpleType) {\n QName qname = new QName(targetNamespace, simpleType.getName());\n if (!processedSimpleTypes.containsKey(qname)) {\n processSimpleType(targetNamespace, defaultNamespace, simpleType.getName(), si... |
"public void parse(Node node) {\n Element element = (Element) node;\n id = Integer.parseInt(element.getAttribute(\"String_Node_Str\"));\n NodeList nodes = element.getElementsByTagName(\"String_Node_Str\");\n if (nodes.getLength() > 0)\n properties.parse(nodes.item(0));\n nodes = element.getElement... |
"private <T> ExportedInstance<T> getExportedInstance(Class<T> requestedType, Class<T> actualType) {\n Assert.notNull(requestedType, \"String_Node_Str\");\n Assert.notNull(actualType, \"String_Node_Str\");\n Addons.waitUntilStarted(addon);\n final Class<T> requestedLoadedType;\n final Class<? extends T> a... |
"public synchronized void create(NamespaceMeta metadata) throws Exception {\n Preconditions.checkArgument(metadata != null, \"String_Node_Str\");\n NamespaceId namespace = new NamespaceId(metadata.getName());\n if (exists(namespace.toId())) {\n throw new NamespaceAlreadyExistsException(namespace.toId())... |
"public static AddressedBinaryMessage fromEncodedMessage(EncodedAISMessage encodedMessage) {\n if (!encodedMessage.isValid())\n throw new InvalidEncodedMessage(encodedMessage);\n if (!encodedMessage.getMessageType().equals(AISMessageType.AddressedBinaryMessage))\n throw new UnsupportedMessageType(en... |
"protected void reply(Transport<byte[][]> t, byte[] message) {\n t.write(\"String_Node_Str\".getBytes(), false);\n t.write(message, false);\n t.write(\"String_Node_Str\".getBytes(), true);\n}\n"
|
"public void updateKeyPairs() {\n String username = System.getProperty(\"String_Node_Str\");\n Boolean devel = Boolean.valueOf(_configDao.getValue(\"String_Node_Str\"));\n if (!username.equalsIgnoreCase(\"String_Node_Str\") && !devel) {\n s_logger.warn(\"String_Node_Str\");\n return;\n }\n ... |
"public static GroupElementHandle getMultiSelectionHandle(List modelList) {\n ReportDesignHandle designHandle = SessionHandleAdapter.getInstance().getReportDesignHandle();\n GroupElementHandle handle = new GroupElementHandle(designHandle, modelList);\n return handle;\n}\n"
|
"private void createInnerTypeRefProperty(JstType currentType, JstType innerType) {\n if (currentType.isOType())\n return;\n JstModifiers mod = innerType.getModifiers().getCopy();\n JstSynthesizedProperty property = new JstSynthesizedProperty(getTypeRef(innerType), innerType.getSimpleName(), (JstIdentifi... |
"protected static CQLStatementIterator makeCQLforInsert(CDefinition def, Map<String, String> data, UUID uuid, long timestamp, int ttl) throws CQLGenerationException {\n List<String> ret = Lists.newArrayList();\n if (uuid == null) {\n uuid = UUIDs.timeBased();\n }\n if (timestamp == 0) {\n time... |
"protected Response createResponse(Map<String, String> reHeaders) throws IOException {\n Response rep = null;\n if (reHeaders != null) {\n rep = new Response(conn, reHeaders);\n if (rep.isOK()) {\n InputStream is1 = conn.getInputStream();\n InputStream is2 = null;\n ... |
"public static Result deleteUser(long id) {\n createNewEm();\n entityManager.remove(entityManager.find(UserForm.class, id));\n entityManager.getTransaction().commit();\n flash(\"String_Node_Str\", \"String_Node_Str\");\n return redirect(routes.Users.users());\n}\n"
|
"public void modifyText(ModifyEvent e) {\n String lowerStr = lowerText.getText();\n String higherStr = higherText.getText();\n if (lowerStr != \"String_Node_Str\" && !CheckValueUtils.isNumberWithNegativeValue(lowerStr)) {\n updateStatus(IStatus.ERROR, MSG_ONLY_NUMBER);\n } else if (!lowerStr.equals(\... |
"public void sortLayout() {\n int height = Plugins.getInstance().sortPermanents(ui, permanents.values());\n BattlefieldPanel.this.jPanel.setPreferredSize(new Dimension(width - 30, height));\n this.jScrollPane.repaint();\n this.jScrollPane.revalidate();\n if (battlefield == null) {\n return;\n }... |
"public int skipBytes(int n) throws IOException {\n if (this.position <= this.end - n) {\n this.position += n;\n return n;\n } else {\n n = this.end - position;\n position = this.end;\n return n;\n }\n}\n"
|
"public long createRow(String mode, long time, String status, Float speed, long timestamp, Float accuracy, String provider, String wifiData, Vector<ArrayList<Double>> samples, Double latitude, Double longitude) {\n ContentValues vals = new ContentValues();\n SharedPreferences settings = mCtx.getSharedPreferences(... |
"public void restoreAll() {\n Path tfpath = cfg.getTfPath();\n Path customBackupPath = tfpath.resolve(\"String_Node_Str\");\n Path customPath = tfpath.resolve(\"String_Node_Str\");\n Path configBackupPath = tfpath.resolve(\"String_Node_Str\");\n Path configPath = tfpath.resolve(\"String_Node_Str\");\n ... |
"public void init(ServletConfig config) throws ServletException {\n super.init(config);\n pickUpSharedManagerIfExists(config);\n String urlPrefix = config.getInitParameter(URL_PREFIX_INIT_PARAMETER);\n initRequestProcessor(urlPrefix);\n String pluginClasses = config.getInitParameter(PLUGIN_CLASSES_INIT_P... |
"public double fitness(Organism<T> individual) {\n TorusAgent[] prey = game.getPrey();\n double numCaught = 0;\n for (TorusAgent p : prey) {\n if (p == null) {\n numCaught++;\n }\n }\n if (numCaught == 0)\n return ALL_PREY_SCORE;\n double fewPreyCaughtScore = (ALL_PREY_... |
"static LineLatLng findClosestLine(LatLng point, List<LineLatLng> list) {\n LineLatLng answer = list.get(0);\n double shortest = Double.MAX_VALUE;\n for (LineLatLng line : list) {\n double ans1 = getDistance(point, line.p1);\n double ans2 = getDistance(point, line.p2);\n LatLng shorterpnt ... |
"public HearthTreeNode<BoardState> use_core(int thisCardIndex, int playerIndex, int minionIndex, HearthTreeNode<BoardState> boardState, Deck deck) {\n if (playerIndex == 1 || minionIndex > 0) {\n return null;\n }\n for (int index = 0; index < 2; ++index) {\n Card card = deck.drawCard(boardState.d... |
"private static int scale(double x, int index) {\n return GraphicsUtil.scale(x, maxes.get(index) - mins.get(index), mins.get(index));\n}\n"
|
"private void onVideoLoaded() {\n runOnUiThread(new Runnable() {\n public void run() {\n Log.d(TAG, \"String_Node_Str\");\n isPlayingJpg = false;\n startTimeCounter();\n }\n });\n}\n"
|
"public String updateBulkStatus() {\n Map sessionAttributes = ActionContext.getContext().getSession();\n try {\n String[] checkedItemsInSession = (String[]) sessionAttributes.get(\"String_Node_Str\");\n for (String checkValue : checkedItemsInSession) {\n Integer bulkId = Integer.parseInt(... |
"public int read(byte[] buffer, int offset, int length) throws IOException {\n int nBytesRead = bufferedStream.read(buffer, offset, length);\n if (nBytesRead > 0) {\n position += nBytesRead;\n }\n return nBytesRead;\n}\n"
|
"public boolean calcDate(SSDate date, boolean strict) {\n if (this.era == 0 && this.year > 0) {\n this.year = -(this.year - 1);\n }\n if (this.year > Integer.MIN_VALUE) {\n date.setYear(this.year - JS_START_YEAR);\n }\n int orgDayOfMonth = date.getDate();\n date.setDate(1);\n if (this... |
"public String getLatest(String channel, String limitPath) {\n logger.trace(\"String_Node_Str\", channel, limitPath);\n String[] split = StringUtils.split(limitPath, \"String_Node_Str\");\n split = new String[] { split[0], split[1], split[2], split[3], split[4], split[5] + split[6] + split[7] };\n String la... |
"private CaptureSearchResult genericResult(WARCRecord rec) {\n CaptureSearchResult result = new CaptureSearchResult();\n result.setMimeType(DEFAULT_VALUE);\n result.setHttpCode(DEFAULT_VALUE);\n result.setRedirectUrl(DEFAULT_VALUE);\n ArchiveRecordHeader header = rec.getHeader();\n String file = trans... |
"public LoadBalancer createPublicLoadBalancerRule(String xId, String name, String description, int srcPortStart, int srcPortEnd, int defPortStart, int defPortEnd, Long ipAddrId, String protocol, String algorithm, long networkId, long lbOwnerId, boolean openFirewall, String lbProtocol, Boolean forDisplay) throws Network... |
"protected void addEdgeToOrder(int e, BipartiteGraph<Var, Factor> bg, boolean[] markedGF) {\n if (!bg.isT1T2(e) && bg.t2E(e) instanceof GlobalFactor) {\n if (!markedGF[bg.parentE(e)]) {\n order.add(bg.t2E(e));\n markedGF[bg.parentE(e)] = true;\n if (warnGF) {\n ... |
"public boolean matches(InventoryCrafting inv, World world) {\n boolean b1 = false, b2 = false;\n for (int i = 0; i < inv.getSizeInventory(); i++) {\n ItemStack s = inv.getStackInSlot(i);\n if (s != null) {\n if (s.getItem() == itemToRepair) {\n if (b1)\n ... |
"public int getWeek() {\n synchronized (this) {\n return _week;\n }\n}\n"
|
"private void writeURI(BufferedWriter writer, String type, String feild, String idType, String dataColumn) throws IOException, XLWrapMapException {\n System.out.println(type + \"String_Node_Str\" + feild + \"String_Node_Str\" + idType + \"String_Node_Str\" + dataColumn);\n if (feild.toLowerCase().equals(\"String_... |
"public EnumActionResult onItemUseFirst(ItemStack stack, EntityPlayer player, World world, BlockPos pos, EnumFacing side, float hitX, float hitY, float hitZ, EnumHand hand) {\n IBlockState state = world.getBlockState(pos);\n Block block = state.getBlock();\n if (world.isAirBlock(pos)) {\n return EnumAct... |
"public String getUsername() {\n if (getServerRoot() != null)\n return getServerRoot().getUser().getUsername();\n return null;\n}\n"
|
"private void assertApplicationUndeploy(String applicationUuid) {\n long startTime = System.currentTimeMillis();\n Application application = ApplicationManager.getApplications().getApplicationByTenant(applicationId, tenantId);\n ApplicationContext applicationContext = null;\n try {\n applicationConte... |
"public Object invoke(Object theProxy, Method theMethod, Object[] theArgs) throws Throwable {\n Object directRetVal = myMethodToReturnValue.get(theMethod);\n if (directRetVal != null) {\n return directRetVal;\n }\n BaseMethodBinding<?> binding = myBindings.get(theMethod);\n if (binding != null) {\... |
"private NetworkInfo getNetworkInfo() {\n if (mContext != null) {\n ConnectivityManager connectivityManager = (ConnectivityManager) mContext.getSystemService(Context.CONNECTIVITY_SERVICE);\n return connectivityManager.getActiveNetworkInfo();\n }\n return null;\n}\n"
|
"public List<UUID> getCardList() {\n return new ArrayList<>(library);\n}\n"
|
"public ActionResult doExecute(HttpServletRequest req, RenderContext renderContext, Resource resource, JCRSessionWrapper session, Map<String, List<String>> parameters, URLResolver urlResolver) throws Exception {\n JCRSessionWrapper jcrSessionWrapper = resource.getNode().getSession();\n JCRNodeWrapper node = resou... |
"public static IPath getItemStatePath(Property property) {\n Item item = property.getItem();\n String statePathStr = null;\n if (item.getState() != null) {\n statePathStr = item.getState().getPath();\n } else {\n URI propURI = EObjectHelper.getURI(property);\n if (StringUtils.isBlank(st... |
"public void actionPerformed(java.awt.event.ActionEvent e) {\n boolean configured = ConfigurationDialogs.show(view, getDialogMode());\n boolean makeReqs = true;\n boolean completed = false;\n java.util.List<String> nodes = new ArrayList<>();\n if (configured) {\n if (BurpPropertiesManager.getBurpP... |
"public String flattenToShortString() {\n StringBuilder sb = new StringBuilder(mPackage.length() + mClass.length());\n appendShortString(sb, mPackage, mClass);\n return sb.toString();\n}\n"
|
"protected Object generateRenderObject(IDataRowExpressionEvaluator rowAdapter, BIRTExternalContext externalContext, boolean bEmpty) throws ChartException {\n prepareDeviceRenderer();\n GeneratedChartState gcs = buildChart(rowAdapter, externalContext, externalProcessor);\n renderToImageFile(gcs);\n if (rtc.g... |
"protected Operation prepareOperation() {\n SerializationService serializationService = getClientEngine().getSerializationService();\n IFunction filter = serializationService.toObject(filterData);\n return new ReadManyOperation(name, startSequence, minCount, maxCount, filter);\n}\n"
|
"private void addTransition(SAFAInputMove<P, S> transition, BooleanAlgebra<P, S> ba, boolean skipSatCheck) {\n if (skipSatCheck || transition.isSatisfiable(ba)) {\n transitionCount++;\n if (transition.from > maxStateId)\n maxStateId = transition.from;\n if (transition.maxState > maxSt... |
"public JedisCommand getCommand() {\n if (redisVersion.containsKey(String.valueOf(id))) {\n version = redisVersion.get(String.valueOf(id));\n } else {\n version = getRedisVersion();\n redisVersion.put(String.valueOf(id), version);\n }\n for (JedisCommand command : commands) {\n i... |
"public boolean setPassenger(final Entity passenger) {\n if (!getHandle().getPassenger().isPresent()) {\n getHandle().setPassenger(((PoreEntity) passenger).getHandle());\n final PoreEntity mounted = this;\n Pore.getGame().getEventManager().post(new EntityMountEvent() {\n private boole... |
"private void refreshModelPageSchema() {\n String content = null;\n try {\n content = Util.nodeToString(xsdSchema.getDocument());\n } catch (Exception e) {\n log.error(e.getMessage(), e);\n }\n XSDSchema schema = null;\n try {\n schema = Util.createXsdSchema(content, xobject);\n ... |
"public int executeCommand(String command, Scheduler scheduler) throws ProcessExecutionException, InterruptedException {\n if (scheduler == null) {\n try {\n output = this.nativeProcessExecutor.execute(command);\n } catch (IOException ioe) {\n throw new ProcessExecutionException(-... |
"public void run() {\n try {\n final boolean fullSync = !Hosts.isCoordinator() && host.isLocalHost() && BootstrapArgs.isCloudController() && !Databases.isSynchronized();\n final boolean passiveSync = !fullSync && host.hasSynced();\n DriverDatabaseClusterMBean cluster = LookupPersistenceContextDa... |
"private On parseOn(String exp) {\n constraints.validateAllCharsValid(exp);\n SpecialCharFieldValue specialChar = new SpecialCharFieldValue(SpecialChar.NONE);\n IntegerFieldValue nth = new IntegerFieldValue(-1);\n IntegerFieldValue time = new IntegerFieldValue(-1);\n String expression = exp;\n if (exp... |
"final int broadcastIntentLocked(ProcessRecord callerApp, String callerPackage, Intent intent, String resolvedType, IIntentReceiver resultTo, int resultCode, String resultData, Bundle resultExtras, String[] requiredPermissions, int appOp, Bundle bOptions, boolean ordered, boolean sticky, int callingPid, int callingUid,... |
"public void putFromLoad(Data dataKey, Object value, long ttl) {\n Record record = records.get(dataKey);\n if (record == null || record.getValue() == null) {\n value = mapService.interceptPut(name, null, value);\n record = mapService.createRecord(name, dataKey, value, ttl);\n records.put(data... |
"public void craft(IFusionCraftingInventory inventory, World world, BlockPos pos) {\n if (!matches(inventory, world, pos)) {\n return;\n }\n List<ICraftingInjector> pedestals = new ArrayList<>();\n pedestals.addAll(inventory.getInjectors());\n for (Object ingredient : ingredients) {\n for (... |
"public void testServeFile() throws Exception {\n Map<String, FileData> files = new HashMap<String, FileData>();\n files.put(\"String_Node_Str\", new FileData(\"String_Node_Str\", \"String_Node_Str\", -1));\n files.put(\"String_Node_Str\", new FileData(\"String_Node_Str\", \"String_Node_Str\", 20));\n Files... |
"protected void createFormContent(IManagedForm managedForm) {\n final ScrolledForm scrolledForm = managedForm.getForm();\n final FormToolkit formToolkit = managedForm.getToolkit();\n GridLayout layout = new GridLayout(1, true);\n layout.marginWidth = 0;\n layout.marginHeight = 0;\n scrolledForm.getBod... |
"public void run() {\n for (int index = 0; index < view.getChildCount(); ++index) {\n View child = view.getChildAt(index);\n Animation animation = new TranslateAnimation(500, 0, 0, 0);\n animation.setDuration(1000);\n animation.setStartOffset(index * 100);\n child.startAnimation(an... |
"public void testRun() {\n OCMMappingStore ocmMappingStore = extension.getOCMMappingStore();\n OCMMapping mapping = ocmMappingStore.findMapping(BasicNode.class);\n Assert.assertNotNull(mapping);\n Assert.assertEquals(3, mapping.getFieldsToProperties().size());\n String result = mapping.getFieldsToPropert... |
"public CurrentWeather getCurrentCondition(String data) throws WeatherLibException {\n CurrentWeather cWeather = new CurrentWeather();\n Weather weather = new Weather();\n try {\n XmlPullParser parser = XmlPullParserFactory.newInstance().newPullParser();\n parser.setInput(new StringReader(data));... |
"public ResponseStatus handleResponse(Player p, String r) {\n SpoutPlayer player = (SpoutPlayer) p;\n int optionOffset = 0;\n if (MenuMetaMod.debug)\n System.out.println(\"String_Node_Str\" + r);\n InGameHUD main = null;\n if (player.isSpoutCraftEnabled()) {\n main = player.getMainScreen();... |
"public static void main(String[] args) {\n ArgumentParser ap = new ArgumentParser();\n ap.setExecutableName(\"String_Node_Str\");\n ap.addOption(\"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", ArgumentParser.OPTIONAL);\n ap.addOption(\"String_Node_Str\", \"String_Node_Str\" + \"String_Node_S... |
"public static final AbstractBeanDefinition getXQueryExecutor(Element element) {\n BeanDefinitionBuilder builder = BeanDefinitionBuilder.genericBeanDefinition(XQueryExecutor.class);\n IntegrationNamespaceUtils.setReferenceIfAttributeDefined(builder, element, \"String_Node_Str\");\n IntegrationNamespaceUtils.se... |
"protected void queryArtistsInternal(final String library, final Subscriber<List<Artist>> subscriber, final Bundle args) {\n Observable.create(new Observable.OnSubscribe<Artist>() {\n public void call(Subscriber<? super Artist> subscriber) {\n queryArtists(library, subscriber, args);\n }\n ... |
"void addSendExtensions(IConfigurationElement[] configElements) {\n String[] existingSchemes = getPlatformSupportedSchemes();\n for (int i = 0; i < configElements.length; i++) {\n final String protocol = configElements[i].getAttribute(PROTOCOL_ATTR);\n if (protocol == null || \"String_Node_Str\".equ... |
"public SyncTaskTO updateSyncTask(final SyncTaskTO taskTO) {\n return restTemplate.postForObject(baseURL + \"String_Node_Str\", taskTO, SyncTaskTO.class);\n}\n"
|
"public boolean equals(Object obj) {\n if (this == obj)\n return true;\n if (obj == null)\n return false;\n if (!(obj instanceof RecCV))\n throw new STCRuntimeError(\"String_Node_Str\" + this.getClass().getName() + \"String_Node_Str\" + obj.getClass().getName());\n RecCV other = (RecCV)... |
"public Mono<ListSpacesResponse> retrieveSpaceId(String orgId, String spaceName) {\n if (\"String_Node_Str\".equals(spaceName) && orgId.equals(ORG_UUID)) {\n SpaceResource sr = SpaceResource.builder().entity(SpaceEntity.builder().name(spaceName).build()).metadata(Metadata.builder().createdAt(CREATED_AT_TIMEST... |
"public void setup() throws Exception {\n executeDataSet(\"String_Node_Str\");\n executeDataSet(\"String_Node_Str\");\n emr.getRegimenManager().clear();\n InputStream stream = getClass().getClassLoader().getResourceAsStream(\"String_Node_Str\");\n emr.getRegimenManager().loadDefinitionsFromXML(stream);\n... |
"protected void removeSSRC(long ssrc) {\n int index = -1;\n if (ssrcList == null || ssrcList.length == 0) {\n return;\n }\n for (int i = 0; i < ssrcList.length; i++) {\n if (ssrcList[i] == ssrc) {\n index = i;\n break;\n }\n }\n if (index < 0 || index >= ssrc... |
"public void handleMessage(Message msg) {\n String type;\n switch(msg.what) {\n case MessageListItem.MSG_LIST_EDIT_MMS:\n type = \"String_Node_Str\";\n break;\n case MessageListItem.MSG_LIST_EDIT_SMS:\n type = \"String_Node_Str\";\n break;\n default... |
"private void renderWithTemplateEngineOrRaw(Context context, Result result) {\n TemplateEngine templateEngine = templateEngineManager.getTemplateEngineForContentType(result.getContentType());\n if (templateEngine != null) {\n templateEngine.invoke(context, result);\n } else {\n if (result.getRend... |
"private void RemoveWrongLabels(String Label) {\n for (Component comp : comps) {\n AttributeSet attrs = comp.getAttributeSet();\n if (attrs.containsAttribute(StdAttr.LABEL)) {\n String CompLabel = attrs.getValue(StdAttr.LABEL);\n if (Label.toUpperCase().equals(CompLabel.toUpperCas... |
"public boolean equals(Object object) {\n if (object instanceof RootKeepAsElement) {\n if (t1 == null && ((RootKeepAsElement) object).getT1() == null) {\n return true;\n } else if (t1 == null && ((RootKeepAsElement) object).getT1() != null) {\n return false;\n } else {\n ... |
"public static int compare(Object obj1, Object obj2) throws DataException {\n if (obj1 == null || obj2 == null) {\n if (obj1 == null && obj2 != null)\n return -1;\n else if (obj1 != null && obj2 == null)\n return 1;\n else\n return 0;\n }\n try {\n i... |
"public Map<String, List> getPageContent() {\n return embeddedPageContent;\n}\n"
|
"public String getRelativeImageFolder() {\n return request.getContextPath() + \"String_Node_Str\" + IMAGE_FOLDER + \"String_Node_Str\" + request.getSession().getId();\n}\n"
|
"public List<String> getJavaOpts() {\n Iterable<String> sysprops = Iterables.transform(getJavaSystemProperties().entrySet(), new Function<Map.Entry, String>() {\n public String apply(Map.Entry entry) {\n Object k = entry.getKey();\n Object v = entry.getValue();\n try {\n ... |
"public boolean generate(World world, Random random, int x, int y, int z) {\n int type;\n if (this.mushroomType >= 0) {\n type = this.mushroomType;\n } else {\n type = random.nextInt(2);\n }\n int height = random.nextInt(3) + 4;\n boolean flag = true;\n if (y >= 1 && y + height + 1 < ... |
"private void dumpTopFrameInfo(int verbosity) {\n Log.write(\"String_Node_Str\");\n Log.writeln(topFrame);\n Log.write(\"String_Node_Str\");\n Log.writeln(ip);\n Log.write(\"String_Node_Str\");\n Log.writeln(fp);\n Log.write(\"String_Node_Str\");\n Log.writeln(thread.getContextRegisters().ip);\n... |
"public void resetZoom() {\n mDrawMatrixValues = new float[] { 1f, 0f, 0f, 0f, 1f, 0f, 0f, 0f, 1f };\n mDrawMatrix.setValues(mDrawMatrixValues);\n if (!mSeries.isEmpty() && _recalculate) {\n recalculateXCoordinates(mGraphWidth * mDrawMatrixValues[0]);\n if (calculateLegendBounds())\n U... |
"private EngineeringCRS parseEngineeringCRS(final int mode, final Element parent, final boolean isBaseCRS) throws ParseException {\n final Element element = parent.pullElement(mode, isBaseCRS ? new String[] { WKTKeywords.BaseEngCRS } : new String[] { WKTKeywords.EngineeringCRS, WKTKeywords.EngCRS, WKTKeywords.Local_... |
"public CpuData getCpuInfo() {\n final CpuData result = new CpuData(getTotalCpuUsage());\n if (mCpuInfoList != null) {\n for (int i = 0; i < mCpuInfoList.size(); i++) {\n final CpuInfo info = mCpuInfoList.get(i);\n result.addCpuUtil(info.getUsage());\n }\n }\n return resu... |
"public void bindView(View view, Context context, Cursor cursor) {\n String a = \"String_Node_Str\";\n super.bindView(view, context, cursor);\n ViewHolder holder = (ViewHolder) view.getTag();\n Weapon weapon = mWeaponCursor.getWeapon();\n String arc = weapon.getRecoil();\n String charge = weapon.getCh... |
"public void testOnlineOfflinePusher() throws Exception {\n URL remote = getReplicationURL();\n final CustomizableMockHttpClient mockHttpClient = new CustomizableMockHttpClient();\n mockHttpClient.addResponderFakeLocalDocumentUpdate404();\n mockHttpClient.addResponderRevDiffsSmartResponder();\n HttpClien... |
"public void removeLava(Block testBlock) {\n if (TEMP_LAVA_BLOCKS.containsKey(testBlock)) {\n TempBlock tb = TEMP_LAVA_BLOCKS.get(testBlock);\n tb.revertBlock();\n TEMP_LAVA_BLOCKS.remove(testBlock);\n affectedBlocks.remove(tb);\n return;\n }\n TempBlock tblock = new TempBloc... |
"public void validate(ParseTreeContext context) {\n super.validate(context);\n TypeHelper typeHelper = context.getTypeHelper();\n Object type = typeHelper.resolveSchema(abstractSchemaName);\n if (type == null) {\n throw JPQLException.entityTypeNotFound2(context.getQueryInfo(), getLine(), getColumn(),... |
"public void process(Pair<Integer, GenericData.Record> input, Emitter<GenericData.Record> emitter) {\n if (outputIndex == input.first()) {\n emitter.emit((GenericData.Record) input.second().get(\"String_Node_Str\"));\n }\n}\n"
|
"private int nextSelectorIndex() {\n int value = nextSelectorIndex.getAndIncrement();\n return HashUtil.hashToIndex(value, selectorThreadCount);\n}\n"
|
"public void reset() throws PermissionBackendException {\n this.clearCache();\n if (this.backend != null) {\n this.backend.reload();\n }\n this.callEvent(PermissionSystemEvent.Action.RELOADED);\n}\n"
|
"public void receiveFamilyRegistration(BlockUri familyUri, Map<String, Integer> registration) {\n BlockFamily family;\n if (isFreeformFamily(familyUri)) {\n family = blockLoader.loadWithShape(familyUri);\n } else {\n family = getAvailableBlockFamily(familyUri);\n }\n if (family != null) {\n... |
"private static Map<String, String> generateHeaders(String host) {\n Validate.notNull(host);\n Map<String, String> ret = new LinkedHashMap<>();\n ret.put(\"String_Node_Str\", host);\n ret.put(\"String_Node_Str\", \"String_Node_Str\");\n return ret;\n}\n"
|
"public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {\n if (viewType == TYPE_VIEW_LOADING) {\n final LoadingViewHolder holder = new LoadingViewHolder(LayoutInflater.from(parent.getContext()).inflate(R.layout.view_adapter_loading, parent, false));\n holder.itemView.setOnClickListener(t... |
"public void refresh() {\n for (IDb db : dbs) {\n if (db instanceof DbResource) {\n ((DbResource) db).close();\n }\n }\n dbs.clear();\n dbs.add(new IDb() {\n public IDatabasePlatform getPlatform() {\n return platform;\n }\n public String getName() {\n... |
"protected void initialize() {\n boolean isNewArea = (root == null);\n createRoot();\n if (isNewArea) {\n IStyle areaStyle = root.getStyle();\n validateBoxProperty(areaStyle, parent.getCurrentMaxContentWidth(), context.getMaxHeight());\n setOffsetX(root.getContentX());\n setOffsetY(... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.