content stringlengths 40 137k |
|---|
"public static ArrayList<Arena> loadArenas(JavaPlugin plugin, ArenasConfig cf) {\n ArrayList<Arena> ret = new ArrayList<Arena>();\n FileConfiguration config = cf.getConfig();\n if (!config.isSet(\"String_Node_Str\")) {\n return ret;\n }\n for (String arena : config.getConfigurationSection(\"String... |
"private InetAddress pickInetAddress(final Collection<String> interfaces) throws SocketException {\n final Enumeration<NetworkInterface> networkInterfaces = NetworkInterface.getNetworkInterfaces();\n final boolean preferIPv4Stack = preferIPv4Stack();\n while (networkInterfaces.hasMoreElements()) {\n fin... |
"protected void setupTricklePipeline(ServerBootstrap serverBootstrap, ClientBootstrap clientBootstrap, Handler serverHandler, Handler clientHandler) {\n serverBootstrap.getPipeline().addLast(\"String_Node_Str\", new IcapRequestDecoder());\n serverBootstrap.getPipeline().addLast(\"String_Node_Str\", new IcapRespon... |
"public void setScheduler(Scheduler scheduler) throws IllegalActionException {\n if (scheduler != null && workspace() != scheduler.workspace()) {\n throw new IllegalActionException(this, scheduler, \"String_Node_Str\");\n }\n try {\n workspace().getWriteAccess();\n if (_scheduler != null) ... |
"public void invokeAllSetValueShouldCallGetExpiry() {\n CountingExpiryPolicy expiryPolicy = new CountingExpiryPolicy();\n expiryPolicyServer.setExpiryPolicy(expiryPolicy);\n MutableConfiguration<Integer, Integer> config = new MutableConfiguration<>();\n config.setExpiryPolicyFactory(FactoryBuilder.factoryOf... |
"public boolean isVisible() {\n if (mZoomDirty) {\n return mNextZoom > 0.001f;\n } else {\n if (mMessageProc == null) {\n return false;\n } else {\n return mRollo.mMessageProc.mZoom > 0.001f;\n }\n }\n}\n"
|
"public synchronized boolean disable(Orchestrator orchestrator, boolean force) {\n if (!force) {\n QueryHelper.SearchQueryHelperBuilder searchQueryHelperBuilder = queryHelper.buildSearchQuery(alienDAO.getIndexForType(Deployment.class)).types(Deployment.class).filters(MapUtil.newHashMap(new String[] { \"String... |
"public void discoverUnregisteredNewObjects(Map clones, Map newObjects, Map unregisteredExistingObjects, Map visitedObjects) {\n if (this.discoverUnregisteredNewObjectsWithoutPersist) {\n super.discoverUnregisteredNewObjects(clones, newObjects, unregisteredExistingObjects, visitedObjects);\n } else {\n ... |
"private void v2Tov3(SQLiteDatabase db) {\n Cursor c = db.rawQuery(\"String_Node_Str\", null);\n int cnt = 0;\n if (c.moveToNext()) {\n cnt = c.getInt(0);\n }\n c.close();\n db.execSQL(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\" + ... |
"public void onAbsolutePathExtFileReceived(String absolutePath) {\n chatUIHelperListener.onScreenResetPossibilityPerformLogout(false);\n imageUtils.showFullImage((android.app.Activity) context, absolutePath);\n}\n"
|
"private void createPreviewCharts(final ScrolledForm form, final Composite composite, final boolean isCreate) {\n for (ModelElement modelElement : analysisHandler.getAnalyzedColumns()) {\n final TdColumn column = SwitchHelpers.COLUMN_SWITCH.doSwitch(modelElement);\n final Collection<Indicator> indicato... |
"protected SearchCacheEntry getSearchCacheEntry(SearchRequest searchRequest) {\n SearchCacheEntry searchCacheEntry;\n Iterator<Map.Entry<Integer, SearchCacheEntry>> iterator = searchRequestCache.entrySet().iterator();\n while (iterator.hasNext()) {\n Map.Entry<Integer, SearchCacheEntry> next = iterator.... |
"private void deleteItems(Object view) {\n if (view != null && view == stepsList) {\n int[] index = stepsList.getSelectionIndices();\n boolean firstPos = false;\n for (int i = index.length - 1; i >= 0; i--) {\n if (index[i] == 0) {\n firstPos = true;\n }\n ... |
"public boolean isMobileAvailable() {\n try {\n android.net.NetworkInfo mobile = connectivity.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);\n return mobile.isAvailable();\n } catch (Exception e) {\n return false;\n }\n}\n"
|
"public int getRenderType() {\n return RENDER_ID;\n}\n"
|
"public static double getTax(Property tax, double price) {\n return roundDown((Config.getFloat(tax) / 100F) * price);\n}\n"
|
"public void testHandlerHookCall() throws Exception {\n HttpResponse response = doGet(\"String_Node_Str\");\n Assert.assertEquals(HttpResponseStatus.OK.getCode(), response.getStatusLine().getStatusCode());\n awaitPostHook();\n Assert.assertEquals(1, handlerHook1.getNumPreCalls());\n Assert.assertEquals(1... |
"public void execute(Tuple tuple) {\n LOG.trace(\"String_Node_Str\");\n JSONObject original_message = null;\n try {\n key = tuple.getStringByField(\"String_Node_Str\");\n original_message = (JSONObject) tuple.getValueByField(\"String_Node_Str\");\n if (original_message == null || original_... |
"public ItemStack getStack() {\n Item item = (Item) Item.itemRegistry.getObject(\"String_Node_Str\");\n if (item == null) {\n throw new Error(\"String_Node_Str\");\n }\n ItemStack stack = new ItemStack(item, 1, 1);\n NBTTagCompound nbt = NBTUtils.getItemData(stack);\n id.write(nbt);\n nbt.se... |
"public V remove(Object key) {\n beforeWrite();\n try {\n V result = get(key);\n if (result == null) {\n return null;\n }\n long v = writeVersion;\n synchronized (this) {\n Page p = copyOnWrite(root, v, true);\n result = (V) remove(p, v, key);\n ... |
"public void refresh(IElementParameter param, boolean check) {\n String paramName = param.getName();\n CCombo combo = (CCombo) hashCurControls.get(paramName);\n if (combo == null || combo.isDisposed()) {\n return;\n }\n Object value = param.getValue();\n if (value instanceof String) {\n ... |
"public void setComponentLocation(String componentName, String srs, List<String> pos) {\n Element parent = getComponent(componentName);\n if (parent == null)\n return;\n parent = (Element) parent.getElementsByTagName(\"String_Node_Str\").item(0);\n parent = addNewNode(parent, \"String_Node_Str\", \"S... |
"public static void loadCommands() {\n File commandsFolder = new File(\"String_Node_Str\");\n if (!commandsFolder.exists()) {\n commandsFolder.mkdirs();\n }\n for (File file : commandsFolder.listFiles()) {\n int extIndex = file.getName().lastIndexOf(\"String_Node_Str\");\n String extens... |
"private int compareEncodingPreferences(MediaFormat enc1, MediaFormat enc2) {\n Integer pref1 = encodingPreferences.get(enc1);\n int pref1IntValue = (pref1 == null) ? 0 : pref1;\n Integer pref2 = encodingPreferences.get(enc2);\n int pref2IntValue = (pref2 == null) ? 0 : pref2;\n int res = pref2IntValue -... |
"public int compareTo(OpenFileTableEntry e) {\n int res = 0;\n if (this.expTime < e.expTime) {\n res = -1;\n } else if (this.expTime == e.expTime) {\n res = e.fileId == null ? -1 : this.fileId.compareTo(e.fileId);\n } else {\n res = 1;\n }\n return res;\n}\n"
|
"public void writeGet(MethodWriter writer, IValue instance) throws BytecodeException {\n if (isConstant(this.value)) {\n this.value.writeExpression(writer);\n return;\n }\n if (this.className == null) {\n this.type.writeDefaultValue(writer);\n return;\n }\n String extended = t... |
"protected Attribute[] getAttributesOfVariable(String varName) {\n VariableSimpleIF var;\n if (featureDataset != null) {\n var = (Variable) featureDataset.getDataVariable(varName);\n } else {\n var = netCDFDataset.findVariable(varName);\n }\n if (var != null) {\n return var.getAttrib... |
"private void computeProperty(ResourcesManager manager, ItemRecord itemRecord) {\n InputStream stream = null;\n try {\n stream = manager.getStream(itemRecord.getPath());\n final Resource resource = createResource(itemRecord, itemRecord.getPath(), false);\n resource.getResourceSet().setURIConv... |
"public final void renderPick(GLGraphics g) {\n if (dirtyLayout)\n layout();\n if (!needToRender()) {\n pickCache.invalidate(context);\n return;\n }\n float x = x_layout;\n float y = y_layout;\n float w = w_layout;\n float h = h_layout;\n g.move(x, y);\n if (!pickCache.re... |
"public File getRoot(final SuccessHandler<?> callback) {\n try {\n return getFilesystemRoot();\n } catch (final IOException e) {\n X_Log.error(ModelServiceJre.class, \"String_Node_Str\", e);\n if (callback instanceof ErrorHandler) {\n ((ErrorHandler) callback).onError(e);\n ... |
"public final void renderSeries(IPrimitiveRenderer ipr, Plot p, ISeriesRenderingHints isrh) throws ChartException {\n try {\n validateDataSetCount(isrh);\n } catch (ChartException vex) {\n throw new ChartException(ChartEngineExtensionPlugin.ID, ChartException.RENDERING, vex);\n }\n boolean bRe... |
"public void detach() {\n if (target.invisible > 0)\n target.invisible--;\n stealthed = false;\n cooldown = 10 - (level / 4);\n QuickSlot.refresh();\n super.detach();\n}\n"
|
"public void postConstruct(Composite parent) {\n final Shell shell = parent.getShell();\n parent.setLayout(new GridLayout(7, false));\n Group grpInputSettings = new Group(parent, SWT.NONE);\n grpInputSettings.setText(\"String_Node_Str\");\n GridData gd_grpInputSettings = new GridData(SWT.LEFT, SWT.CENTER... |
"public void remove() {\n removeLive.set(true);\n}\n"
|
"private Listitem getVisibleRow(Listitem item) {\n if (item instanceof Listgroup) {\n final Listgroup g = (Listgroup) item;\n if (!g.isOpen()) {\n for (int j = 0, len = g.getItemCount(); j < len && _it.hasNext(); j++) _it.next();\n }\n }\n while (!item.isVisible() && _it.hasNext... |
"public void run() {\n while (true) {\n for (int k = 0; k < 50; k++) {\n for (int i = 0; i < money.length; i++) {\n int j = (int) (Math.random() * money.length);\n money[i] -= 1;\n money[j] += 1;\n }\n }\n Arrays.sort(money);\n ... |
"Optional<char[]> getNewPassword() {\n if (!mSetPass.isSelected())\n return Optional.of(new char[0]);\n char[] newPass = mNewPassField.getPassword();\n if (!Arrays.equals(newPass, mConfirmPassField.getPassword()))\n return Optional.empty();\n return Optional.of(newPass);\n}\n"
|
"public void handle(Message inputMessage, IMessageTarget messageTarget) {\n getComponentStatistics().incrementInboundMessages();\n IResourceRuntime resourceRuntime = getResourceRuntime();\n String path = resourceRuntime.getAgentOverrides().get(LocalFile.LOCALFILE_PATH);\n if (useTriggerFile) {\n File... |
"public <R> R apply(LatticeMorphism<BooleanExpression, R> f) throws TimeoutException {\n if (bdd.isOne()) {\n return f.True();\n } else if (bdd.isZero()) {\n return f.False();\n } else {\n return f.MkOr(f.MkAnd(f.apply(bdd.var()), f.apply(new BDDExpression(bdd.high()))), f.apply(new BDDExp... |
"Boolean sendPlayerState() {\n return playerBoard.getBrainySnakePlayer().handlePlayerStatusUpdate(this.lastPlayerState);\n}\n"
|
"public Polygon obtainPologygon() {\n Polygon result = new Polygon();\n if (this.synapse.isSelfConnected()) {\n int x = (int) this.synapse.getFromLayer().getX() + DrawLayer.LAYER_WIDTH;\n int y = (int) this.synapse.getFromLayer().getY();\n result.addPoint(x - 10, y - 10);\n result.addP... |
"public void onClick(View v) {\n int position = getAdapterPosition();\n if (Utils.isWeekOfYearEnabled()) {\n if (position % 8 == 0) {\n return;\n }\n position = fixForWeekOfYearNumber(position);\n }\n if (totalDays < position - 6 - startingDayOfWeek || position - 7 - starting... |
"public static boolean generate() {\n devices = new LinkedList<GPUDevice>();\n OS os = OS.getOS();\n String path = os.getCUDALib();\n if (path == null) {\n System.out.println(\"String_Node_Str\");\n return false;\n }\n CUDA cudalib = null;\n try {\n cudalib = (CUDA) Native.load... |
"private static void createComponentsDrawer(final IComponentsFactory compFac, boolean needHiddenComponent, boolean isFavorite, int a) {\n clearGroup();\n LinkedList<CreationToolEntry> nodeList = new LinkedList<CreationToolEntry>();\n PaletteDrawer componentsDrawer;\n String name, longName;\n String famil... |
"protected boolean versionFound(String version) {\n if (!version.startsWith(\"String_Node_Str\")) {\n return false;\n }\n String nineFiveVersionString = \"String_Node_Str\";\n if (version.equals(nineFiveVersionString)) {\n try {\n long fileSize = getFileChannel().size();\n ... |
"protected void mouseClicked(int i, int j, int k) {\n if (gate == null) {\n return;\n }\n super.mouseClicked(i, j, k);\n AdvancedSlot slot = getSlotAtLocation(i, j);\n if (slot instanceof TriggerSlot && container.hasTriggers()) {\n TriggerSlot triggerSlot = (TriggerSlot) slot;\n ISta... |
"public Void call() throws Exception {\n int priorValue = lastValue.getAndSet(index);\n if (priorValue != index) {\n inner.call();\n }\n return null;\n}\n"
|
"public static HTTPResponseResult postForm(String address, String usernamePropertyName, String passwordPropertyName, String[] formParamNames, String[] formParamValues, int usernameParamIx, int passwordParamIx) {\n DefaultHttpClient httpClient = null;\n try {\n HttpPost postMethod = new HttpPost(address);\n... |
"public void handle(RoutingContext context) {\n DataBase database = DataBase.getInstance();\n String uid = context.request().getParam(\"String_Node_Str\");\n String id = context.request().getParam(\"String_Node_Str\");\n String password = context.request().getParam(\"String_Node_Str\");\n int number = In... |
"public void testXmlAttributeOverrideInvalid() {\n if (shouldGenerateSchema) {\n outputResolver = generateSchema(CONTEXT_PATH, PATH, 1);\n String controlSchema = PATH + \"String_Node_Str\";\n compareSchemas(outputResolver.schemaFiles.get(EMPTY_NAMESPACE), new File(controlSchema));\n shoul... |
"private long insertEnvironmentLocation(Uri uri, SQLiteDatabase db, ContentValues values) {\n long environmentId = Long.parseLong(uri.getPathSegments().get(1));\n String geofenceSelection = GeoFenceEntry.COLUMN_LOCATION_NAME + \"String_Node_Str\";\n String[] geofenceSelectionArgs = new String[] { values.getAsS... |
"public List<DomainVO> searchForDomains(ListDomainsCmd cmd) throws PermissionDeniedException {\n Long domainId = cmd.getId();\n Account account = UserContext.current().getAccount();\n if (account != null) {\n if (domainId != null) {\n if (!_domainDao.isChildDomain(account.getDomainId(), domai... |
"public static void main(String[] args) {\n ApproxSet set = new ApproxSet(10, 1024);\n for (int i = -5000; i < 5000; i++) {\n set.add(i);\n }\n int cnt = 0;\n for (int i = 5001; i < 105000; i++) {\n if (set.contains(i))\n cnt++;\n }\n System.out.println(\"String_Node_Str\" ... |
"protected void setPreferences(String[] programIdParts, PrintStream printStream, Map<String, String> args) throws Exception {\n switch(type) {\n case INSTANCE:\n if (programIdParts.length != 0) {\n throw new CommandInputError(this);\n }\n client.setInstancePrefe... |
"public IRoomInfo[] getChatRoomsInfo() {\n ID[] chatRooms = getChatRooms();\n if (chatRooms == null)\n return null;\n IRoomInfo[] res = new IRoomInfo[chatRooms.length];\n for (int i = 0; i < chatRooms.length; i++) {\n IRoomInfo infoResult = getChatRoomInfo(chatRooms[i]);\n if (infoResul... |
"public void createSchema() {\n if (mongoClientDB == null)\n throw new IllegalStateException(\"String_Node_Str\");\n if (schemaExists()) {\n return;\n }\n mongoClientColl = mongoClientDB.createCollection(mapping.getCollectionName(), new BasicDBObject());\n mongoClientColl.setDBEncoderFactor... |
"public E take(final long waitMillis) {\n try {\n lock.lockInterruptibly();\n E elem = take();\n if (elem == null) {\n empty.signalAll();\n if (waitMillis < 0)\n added.await();\n else\n added.await(waitMillis, TimeUnit.MILLISECONDS);... |
"protected RawPacket createRawPacket(DatagramPacket datagramPacket) {\n if (pkt == null) {\n pkt = new RawPacket(datagramPacket.getData(), datagramPacket.getOffset(), datagramPacket.getLength());\n } else {\n pkt.setBuffer(datagramPacket.getData());\n pkt.setLength(datagramPacket.getLength())... |
"public void handleEvent(Event event) {\n IAxisSet axisSet = chart.getAxisSet();\n if (axisSet != null) {\n IAxis xAxis = axisSet.getXAxis(0);\n if (xAxis != null) {\n String[] series = xAxis.getCategorySeries();\n ISeries[] data = chart.getSeriesSet().getSeries();\n ... |
"private void createDefaultMotionObjects() {\n if (getExperimenalMarkerGeometryJson() == null) {\n experimenalMarkerGeometryJson = new JSONObject();\n UUID uuidForMarkerGeometry = UUID.randomUUID();\n getExperimenalMarkerGeometryJson().put(\"String_Node_Str\", uuidForMarkerGeometry.toString());\... |
"public void savePreferences(ChartPreferences preferences, OutputStream os) throws IOException {\n ResourceSet rsChart = new ResourceSetImpl();\n rsChart.getResourceFactoryRegistry().getExtensionToFactoryMap().put(\"String_Node_Str\", new ModelResourceFactoryImpl());\n Resource rChart = rsChart.createResource(... |
"public boolean cleanupAccount(AccountVO account, long callerUserId, Account caller) throws ConcurrentOperationException, ResourceUnavailableException {\n long accountId = account.getId();\n boolean accountCleanupNeeded = false;\n try {\n List<InstanceGroupVO> groups = _vmGroupDao.listByAccountId(accoun... |
"public void testStandardGPSNode() {\n GpsNode gpsNode1 = new GpsNode(NodeChannel.GPS, \"String_Node_Str\");\n String input = \"String_Node_Str\";\n byte[] bytes = Charset.forName(\"String_Node_Str\").encode(input).array();\n gpsNode1.peel(bytes, 0, bytes.length);\n try {\n Thread.sleep(3000);\n ... |
"public boolean clearApplicationUserData(final String packageName, final IPackageDataObserver observer, int userId) {\n enforceNotIsolatedCaller(\"String_Node_Str\");\n int uid = Binder.getCallingUid();\n int pid = Binder.getCallingPid();\n userId = handleIncomingUser(pid, uid, userId, false, ALLOW_FULL_ONL... |
"public void afterTransactionBegin(final Transaction tx) {\n try {\n LOG.debug(String.format(\"String_Node_Str\", Threads.currentStackFrame().getMethodName(), this.operations = 0, tx.toString()));\n } catch (Exception ex) {\n LOG.error(ex, ex);\n }\n super.afterTransactionBegin(tx);\n}\n"
|
"private void placeComponents() {\n if (cmpHeaders == null) {\n GridLayout glTable = new GridLayout();\n glTable.numColumns = 1;\n glTable.marginWidth = 1;\n glTable.marginHeight = 1;\n glTable.horizontalSpacing = 0;\n glTable.verticalSpacing = 0;\n setLayout(glTable)... |
"public String getValue(R object) {\n ProxyImpl proxyImpl = (ProxyImpl) object;\n return renderer.render(proxyImpl.<T>get(property, clazz));\n}\n"
|
"public Scanner scan(byte[] startRow, byte[] stopRow, FuzzyRowFilter filter, byte[][] columns, Transaction tx) throws IOException {\n DBIterator iterator = getDB().iterator();\n try {\n if (startRow != null) {\n iterator.seek(createStartKey(startRow));\n } else {\n iterator.see... |
"private int[] createSparseOffsets(int offset, int[] toremove) {\n int underlyingRank = (int) sparseOffsets.length();\n int[] newOffsets = new int[rank()];\n List<Integer> shapeList = Ints.asList(shape());\n int penultimate = rank() - 1;\n for (int i = 0; i < penultimate; i++) {\n int prod = Array... |
"public void setupJSRSubroutineMap(Address frameAddress, int mapid, WordArray registerLocations, VM_CompiledMethod compiledMethod) {\n int j = extraUnusualMap.getReferenceMapIndex();\n int k = extraUnusualMap.getNonReferenceMapIndex();\n int l = extraUnusualMap.getReturnAddressMapIndex();\n for (int i = 0; ... |
"public void buildContent() {\n tiles.getChildren().clear();\n itemSupply.get().sorted(byNC(textConverter::toS)).forEach(item -> {\n Node cell = cellFactory.apply(item);\n cell.setOnMouseClicked(e -> {\n if (e.getButton() == PRIMARY) {\n onSelect.accept(item);\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 ... |
"void computePotentialSplitScore(List<Point2D_I32> contour, LinkedList.Element<Corner> e0) {\n LinkedList.Element<Corner> e1 = next(e0);\n e0.object.splitable = canBeSplit(contour.size(), e0);\n if (e0.object.splitable) {\n splitter.selectSplitPoint(contour, e0.object.index, e1.object.index, resultsA);\... |
"public void execute(AdminCommandContext context) {\n ActionReport report = context.getActionReport();\n if (name == null)\n name = nodehost;\n if (nodes.getNode(name) != null) {\n return;\n }\n CommandInvocation ci = cr.getCommandInvocation(\"String_Node_Str\", report);\n ParameterMap m... |
"private static boolean isLetter(char c) {\n if (Arrays.binarySearch(Alphabet.getGreekNumbering(), c) != -1)\n return true;\n if (Arrays.binarySearch(Alphabet.CYRILLIC_NUMBERING, c) != -1)\n return true;\n return Character.isLetter(c);\n}\n"
|
"public Integer getSelectedKeyAtSelectedTableItem(Map<Integer, ITableEntry> searchMaps) {\n Integer selectKey = 0;\n TableViewerCreator tableViewerCreator = null;\n if (uiManager.getCurrentSelectedInputTableView() != null) {\n tableViewerCreator = uiManager.getCurrentSelectedInputTableView().getTableVie... |
"public Coord2D getMiddle() {\n return (new Coord2D((ne_1quadrant.getLat() + sw_3quadrant.getLat()) / 2, (ne_1quadrant.getLng() + sw_3quadrant.getLng()) / 2));\n}\n"
|
"protected void setEnv(Map parameters, String autServerClasspath) {\n String env = (String) parameters.get(AutConfigConstants.ENVIRONMENT);\n if (env == null) {\n env = StringConstants.EMPTY;\n } else {\n env += ENV_SEPARATOR;\n }\n env += setJavaOptions(parameters);\n if (isRunningFromE... |
"private void _parseExpression(String expression, int rowIndex, boolean inmode) {\n if (expression != \"String_Node_Str\") {\n String condition = \"String_Node_Str\";\n String value = \"String_Node_Str\";\n for (int i = 1; i < getColumnCount(); i++) {\n expression = expression.substri... |
"public static List<Field> getPrimaryColumnFields(List<Field> outFields, Class<?> inClass) {\n for (Field field : inClass.getDeclaredFields()) {\n if (StructureUtils.isPrimaryKey(field)) {\n outFields.add(field);\n }\n }\n if (inClass.getSuperclass() != null && !inClass.getSuperclass()... |
"protected void deliverEvent(Event evt) {\n final SOWrapper wrap = getSharedObjectWrapper(presenceHelperID);\n if (wrap != null)\n wrap.deliverEvent(evt);\n}\n"
|
"private Collection<Address> getPossibleAddresses() {\n final Collection<String> possibleMembers = getMembers();\n final Set<Address> possibleAddresses = new HashSet<Address>();\n final NetworkConfig networkConfig = config.getNetworkConfig();\n for (String possibleMember : possibleMembers) {\n try {\... |
"public boolean checkTrigger(GameEvent event, Game game) {\n if (event == null) {\n return false;\n }\n Permanent permanent = game.getPermanentOrLKIBattlefield(event.getTargetId());\n if (permanent == null) {\n return false;\n }\n if (permanent.getControllerId().equals(this.getController... |
"public Boolean razePlot(User user) {\n String locKey = user.getLocationKey();\n Plot plot = getPlotAtUser(user);\n if (!exists(locKey)) {\n user.message(\"String_Node_Str\");\n return false;\n }\n if (plugin.userManager.isLeader(user) && plot.getOwner().equals(user.getNation())) {\n ... |
"private Object handleChild(Object child, int maxDepth) throws Exception {\n if (child instanceof OTID && (maxDepth == -1 || maxDepth > 0)) {\n CopyEntry itemCopyEntry = getCopyEntry((OTID) child);\n if (itemCopyEntry == null) {\n OTDataObject itemObj = sourceDb.getOTDataObject(root, (OTID) ... |
"IMap newMapProxy(String name) {\n IMap imap = Hazelcast.getMap(name);\n ClassLoader classLoader = Thread.currentThread().getContextClassLoader();\n Class[] interfaces = new Class[] { IMap.class };\n IMap proxy = (IMap) Proxy.newProxyInstance(classLoader, interfaces, new ThreadBoundInvocationHandler(imap));... |
"private void createOtrContactMenus(MetaContact metaContact) {\n for (int itemIndex = 0, itemCount = menu.getItemCount(); itemIndex < itemCount; ) {\n JMenuItem menuItem = menu.getItem(itemIndex);\n if (menuItem instanceof OtrContactMenu) {\n menu.remove(itemIndex);\n itemCount--;... |
"private String computeLanguageName() {\n if (WikiTextPlugin.getDefault() == null) {\n return TextileLanguage.class.getName();\n }\n return \"String_Node_Str\";\n}\n"
|
"public void resumeActor(NamedObj actor) throws IllegalActionException {\n List<DEEvent> events = _actorsInExecution.get(actor);\n ActorExecutionAspect aspect = getExecutionAspect(actor);\n if (aspect == null) {\n throw new IllegalActionException(this, \"String_Node_Str\" + actor.getName() + \"String_No... |
"public void onBindViewHolder(AbstractViewHolder holder, int position) {\n if (artistList.isEmpty()) {\n return;\n }\n Artist artist = artistList.get(position);\n holder.getTitle().setText(artist.getName().toLowerCase());\n if (artist.getListeners() != null) {\n holder.getCount().setText(Co... |
"public void testReplaceBranchInfo() throws Exception {\n project.setProperty(\"String_Node_Str\", \"String_Node_Str\");\n IvyResolve res = new IvyResolve();\n res.setProject(project);\n res.execute();\n deliver.setPubrevision(\"String_Node_Str\");\n deliver.setPubbranch(\"String_Node_Str\");\n del... |
"private Migrator createMigrator(String changeLogFile, FileOpener fileOpener) throws JDBCException {\n return new Migrator(changeLogFile, fileOpener, database);\n}\n"
|
"public void put(Request req) {\n long now = System.currentTimeMillis();\n if (mapRecords.size() >= maxSize) {\n }\n if (req.value == null) {\n req.value = new Data();\n }\n Record record = getRecord(req.key);\n if (record != null && !record.isValid(now)) {\n }\n if (req.operation == C... |
"protected boolean isUserDisabled(SearchResult result) throws NamingException {\n boolean isDisabledUser = false;\n String userAccountControl = LdapUtils.getAttributeValue(result.getAttributes(), _ldapConfiguration.getUserAccountControlAttribute());\n if (userAccountControl != null) {\n int control = In... |
"public void build() throws BirtException {\n IReportExecutor executor = executionContext.getExecutor();\n engine = LayoutEngineFactory.createLayoutEngine(ExtensionManager.PAGE_BREAK_PAGINATION);\n engine.setOption(EngineTask.TASK_TYPE, new Integer(IEngineTask.TASK_RUN));\n IReportContent report = executor.... |
"public List<Variable> getVariables() {\n List<Variable> variables = new ArrayList<Variable>();\n for (IDataMapTable table : this.tables) {\n List<IColumnEntry> dataMapTableEntries = table.getColumnEntries();\n for (IColumnEntry entrySource : dataMapTableEntries) {\n String variable = nul... |
"protected boolean _transferInputs(IOPort port) throws IllegalActionException {\n if (!port.isInput() || !port.isOpaque()) {\n throw new IllegalActionException(this, port, \"String_Node_Str\" + \"String_Node_Str\");\n }\n if (port instanceof RefinementPort) {\n return super._transferInputs(port);... |
"private long hash(byte[] digest, int number) {\n return (((long) (digest[3 + number * 4] & 0xFF) << 24) | ((long) (digest[2 + number * 4] & 0xFF) << 16) | ((long) (digest[1 + number * 4] & 0xFF) << 8) | (digest[number * 4] & 0xFF)) & 0xFFFFFFFFL;\n}\n"
|
"private void parseCurrentLine() {\n Arrays.fill(columnStarts, 0);\n Arrays.fill(columnEnds, 0);\n Arrays.fill(fieldStarts, 0);\n Arrays.fill(fieldEnds, 0);\n columnStarts[0] = 0;\n int columnIndex = 0;\n int fieldIndex = 0;\n lineLength = line.length();\n int[] lineFieldIndexToColumnIndex = ... |
"public void whenInvalidInstanceNameAsUri_thenFails() throws URISyntaxException {\n cachingProvider.getCacheManager(new URI(\"String_Node_Str\"), null);\n}\n"
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.