content stringlengths 40 137k |
|---|
"public void onUpdate(ItemStack stack, World world, Entity entity, int slot, boolean isCurrentItem) {\n if (slot > 8 || !isActive(stack) || isCurrentItem) {\n return;\n }\n InventoryPlayer playerInv = ((EntityPlayer) entity).inventory;\n IEnergyContainerItem containerItem;\n int toSend = Math.min(... |
"public void testOutputChangeLog() throws Exception {\n if (database == null) {\n return;\n }\n StringWriter output = new StringWriter();\n Migrator migrator = createMigrator(completeChangeLog);\n migrator.dropAll(getSchemasToDrop());\n migrator = createMigrator(completeChangeLog);\n migrato... |
"public boolean isBurning() {\n if (worldObj.getBlockMetadata(xCoord, yCoord, zCoord) == 1) {\n return this.furnaceBurnTime > 0;\n } else if (worldObj.getBlockMetadata(xCoord, yCoord, zCoord) > 0) {\n if (getPrimaryTileEntity() != null) {\n return getPrimaryTileEntity().isBurning();\n ... |
"public void attributeChanged(Attribute attribute) throws IllegalActionException {\n if (attribute == _mappingFileName) {\n StringToken str_token = (StringToken) _mappingFileName.getToken();\n if (str_token == null) {\n _mapping_file_name = null;\n } else {\n readMapping(st... |
"public double[] getLocation() {\n double[] offset = super.getLocation();\n NamedObj relativeToObject = getRelativeToNamedObj();\n if (relativeToObject == null || offset == null) {\n return offset;\n }\n double[] relativeToLocation = _getRelativeToLocation(relativeToValue);\n if (relativeToLoca... |
"public static void main(String[] args) throws Exception {\n Config.ACCESS_KEY = \"String_Node_Str\";\n Config.SECRET_KEY = \"String_Node_Str\";\n String bucketName = \"String_Node_Str\";\n String key = \"String_Node_Str\";\n String path = System.getProperty(\"String_Node_Str\");\n System.out.println(... |
"private void processSubQuery() {\n IBaseQueryDefinition queryDefn2 = null;\n if (queryDefn != null)\n queryDefn2 = queryDefn;\n else\n queryDefn2 = subQueryDefn;\n subQueryMap = new HashMap();\n registerSubQuery(queryDefn2);\n}\n"
|
"public boolean onMenuItemActionCollapse(MenuItem item) {\n cancelSearch();\n baseActivity.getSupportFragmentManager().popBackStack();\n return true;\n}\n"
|
"public void persistJoinTable(JoinTableData joinTableData) {\n String joinTableName = joinTableData.getJoinTableName();\n String invJoinColumnName = joinTableData.getInverseJoinColumnName();\n Map<Object, Set<Object>> joinTableRecords = joinTableData.getJoinTableRecords();\n for (Object key : joinTableRecor... |
"public void onLivingUpdate() {\n super.onLivingUpdate();\n if (this instanceof IPredatorDiet && world.getDifficulty().equals(EnumDifficulty.PEACEFUL)) {\n boolean hasPlayer = false;\n Class[] prey = ((IPredatorDiet) this).getPreyClasses();\n for (Class c : prey) {\n if (c.getName(... |
"public final int getValue(long timestamp) {\n compute(timestamp, timestamp);\n Score s = getComputedByTimestamp(timestamp);\n if (s == null)\n throw new IllegalStateException();\n return s.getValue();\n}\n"
|
"public void testBuildPutFiles() {\n String testFileName = \"String_Node_Str\";\n Boolean testPFile = true, testSystemFile = true;\n Integer testCorrelationID = 0, testOffset = 1, testLength = 2;\n FileType testFileType = FileType.BINARY;\n byte[] testFileData = { (byte) 0x00, (byte) 0x01, (byte) 0x02 };... |
"public Showable createNotify(final Activity activity) {\n int resultType = getResult();\n String str;\n int duration;\n Style style;\n if ((resultType & OperationResult.RESULT_ERROR) == 0) {\n String untilCancelled;\n duration = Notify.LENGTH_LONG;\n style = Style.OK;\n until... |
"public int compare(IConnection o1, IConnection o2) {\n if (o1.getLineStyle() == o2.getLineStyle()) {\n if (o1.getOutputId() > o2.getOutputId()) {\n return 1;\n } else {\n return -1;\n }\n }\n if (EConnectionType.ROUTE_WHEN == o1.getLineStyle()) {\n if (EConnec... |
"public boolean isOrificeTypeAvailable() {\n if (sexAreaAccessRequiredForTargeted == null || sexAreaAccessRequiredForTargeted.isEmpty()) {\n return true;\n }\n if (getSexActionType() != null) {\n switch(getSexActionType()) {\n case REQUIRES_NO_PENETRATION:\n for (SexArea... |
"protected void onEvent(Event event) {\n if (!topologyInitialized) {\n log.info(\"String_Node_Str\" + event.getClass());\n ApplicationHolder.acquireReadLock();\n try {\n Applications applications = ApplicationHolder.getApplications();\n if (applications != null) {\n ... |
"protected void onCreate(Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\n setContentView(R.layout.hosts);\n registerForContextMenu(getListView());\n if (savedInstanceState == null || !savedInstanceState.getBoolean(INITIALIZED_KEY)) {\n startActivityForResult(new Intent(this, Splas... |
"public static double get(String text, char indicator) {\n String[] split = text.replace(\"String_Node_Str\", \"String_Node_Str\").toLowerCase().split(\"String_Node_Str\");\n String character = String.valueOf(indicator).toLowerCase();\n for (String part : split) {\n if (!part.contains(character)) {\n ... |
"private void ensureKeyPairForInstanceAlias() throws IOException, NoSuchAlgorithmException, CertificateException, KeyStoreException, UnrecoverableKeyException, ProcessManagerException {\n final KeyStore ks = sslUtils().getKeyStore();\n if (ks.containsAlias(SecureAdmin.Duck.DEFAULT_INSTANCE_ALIAS)) {\n retu... |
"public void testTodoListHeaderInsert() {\n TodoListHeader header = createHeader();\n boolean success = repository.insert(header);\n assertTrue(success);\n TodoListHeaderDAO dao = realm.where(TodoListHeaderDAO.class).equalTo(\"String_Node_Str\", header.getUuid()).findFirst();\n assertNotNull(dao);\n}\n"
|
"public double logDensity(RealVector x) {\n RealVector diff = x.subtract(mean);\n int dim = mean.getDimension();\n return -0.5 * dim * Math.log(2 * Math.PI) - 0.5 * logDeterminant - 0.5 * (inverseCovariance.preMultiply(diff).dotProduct(diff));\n}\n"
|
"protected Thumbnail getPreview(String entityId, String mediaId, Integer maxHeight, Integer maxWidth, String mediaDirectory) throws MetadataSourceException, IOException, InvalidPreviewFormatException, MediaNotFoundException {\n File media = new File(mediaDirectory + File.separator + mediaId);\n if (!media.exists(... |
"public static <T extends dObject> T getObjectFrom(Class<T> dClass, String value, dPlayer player, dNPC npc) {\n try {\n List<String> matches = SeparateProperties(value);\n boolean matched = matches != null && Adjustable.class.isAssignableFrom(dClass);\n T gotten = (T) ((dClass.equals(dItem.class... |
"public JSType getRestrictedTypeGivenToBooleanOutcome(boolean outcome) {\n if (outcome && areIdentical(this, getNativeType(JSTypeNative.UNKNOWN_TYPE))) {\n return getNativeType(JSTypeNative.CHECKED_UNKNOWN_TYPE);\n }\n BooleanLiteralSet literals = getPossibleToBooleanOutcomes();\n if (literals.contai... |
"public V put(K key, V value) {\n V result = value;\n synchronized (this) {\n if (!Objects.equals(value, _cache.getWithoutExpunge(key))) {\n result = syncToWriteCache().put(key, value);\n _moreInWriteCache = true;\n if (_cache.containsKey(key))\n syncToReadCa... |
"public boolean isMsgField(String msgType, int field) {\n Set fields = (Set) messageFields.get(msgType);\n return fields != null && fields.contains(new Integer(field));\n}\n"
|
"public boolean is4KEnabled() {\n if (mProfile.quality == CamcorderProfile.QUALITY_2160P || mProfile.quality == CamcorderProfile.QUALITY_TIME_LAPSE_2160P || mProfile.quality == CamcorderProfile.QUALITY_4KDCI) {\n return true;\n } else {\n return false;\n }\n}\n"
|
"protected void paintFigure(Graphics graphics) {\n if (isOpaque()) {\n if (getBorder() instanceof BaseBorder) {\n graphics.fillRectangle(getBounds().getCopy().crop(((BaseBorder) getBorder()).getBorderInsets()));\n } else {\n graphics.fillRectangle(getBounds());\n }\n }\n... |
"public static MumblerFunction createBuiltinFunction(NodeFactory<? extends BuiltinNode> factory) {\n int argumentCount = factory.getExecutionSignature().size();\n MumblerNode[] argumentNodes = new MumblerNode[argumentCount];\n for (int i = 0; i < argumentCount; i++) {\n argumentNodes[i] = new ReadArgume... |
"public void instanceExecuted(int instanceId) {\n startingSeqNo.add(new Pair<Integer, Integer>(instanceId + 1, nextSeqNo));\n}\n"
|
"public void widgetSelected(SelectionEvent e) {\n JoinElement newJoinElement = RulesFactory.eINSTANCE.createJoinElement();\n newJoinElement.setOperator(DEFAULT_OPERATOR);\n creatNewJoinElementLine(newJoinElement);\n tempJoinElements.add(newJoinElement);\n joinConditionSection.setExpanded(true);\n setD... |
"private static void processChunk(Metadata metadata, PngChunk chunk) throws PngProcessingException, IOException {\n PngChunkType chunkType = chunk.getType();\n byte[] bytes = chunk.getBytes();\n if (chunkType.equals(PngChunkType.IHDR)) {\n PngHeader header = new PngHeader(bytes);\n PngDirectory d... |
"private PDFRenderContext createPDFrenderContext() {\n PDFRenderContext renderContext = new PDFRenderContext();\n renderContext.setBaseURL(this.contextPath + IBirtConstants.SERVLET_PATH_RUN);\n renderContext.setSupportedImageFormats(\"String_Node_Str\");\n return renderContext;\n}\n"
|
"public boolean apply(Game game, Ability source) {\n Player controller = game.getPlayer(source.getControllerId());\n Card cardOne = game.getCard(source.getTargets().get(0).getFirstTarget());\n Card cardTwo = game.getCard(source.getTargets().get(1).getFirstTarget());\n if (controller != null) {\n if (... |
"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 static Uri createUri(String accountName, String sessionId, String subredditName, int filter, String more, String query, boolean sync) {\n Uri.Builder b = ThingProvider.CONTENT_URI.buildUpon().appendQueryParameter(ThingProvider.PARAM_SYNC, Boolean.toString(sync)).appendQueryParameter(ThingProvider.PARAM_ACCOU... |
"public void before(Object target, Object[] args) {\n if (isDebug) {\n logger.beforeInterceptor(target, args);\n }\n Trace trace = traceContext.currentRawTraceObject();\n if (trace == null) {\n return;\n }\n HttpURLConnection request = (HttpURLConnection) target;\n boolean connected =... |
"public ConfidenceResult score(Result result) {\n Lattice lattice = new Lattice(result);\n LatticeOptimizer lop = new LatticeOptimizer(lattice);\n lop.optimize();\n lattice.computeNodePosteriors(languageWeightAdjustment);\n SausageMaker sm = new SausageMaker(lattice);\n Sausage s = sm.makeSausage();\n... |
"public Role[] getRoles(String filter) throws InvalidSyntaxException {\n return (Role[]) roles.values().toArray();\n}\n"
|
"public void register(ProteusTypeAdapterFactory factory) {\n factory.register(AttributeResource.class, ATTRIBUTE_RESOURCE);\n factory.register(Binding.class, BINDING);\n factory.register(Color.Int.class, COLOR_INT);\n factory.register(Color.StateList.class, COLOR_STATE_LIST);\n factory.register(Dimension... |
"public Object resolveInjectionPoint(java.lang.reflect.Member member, Application app) throws javax.naming.NamingException {\n Object result = null;\n Field field = null;\n Method method = null;\n Annotation[] annotations;\n if (member instanceof Field) {\n field = (Field) member;\n annotat... |
"protected Set<? extends X509CRLEntry> removeExpiredSerials(Set<? extends X509CRLEntry> revokedEntries) {\n if (revokedEntries == null || revokedEntries.size() == 0) {\n return Util.newSet();\n }\n Map<BigInteger, X509CRLEntry> map = newMap();\n for (X509CRLEntry entry : revokedEntries) {\n ma... |
"public boolean isPageBreakInsideAvoid() {\n if (getTableArea().isGridDesign()) {\n return super.isPageBreakInsideAvoid();\n } else {\n return true;\n }\n}\n"
|
"public String NewTag(UCMEntity entity, String cgi) {\n logger.trace_function();\n logger.debug(entity.GetFQName());\n String cmd = \"String_Node_Str\" + cgi + \"String_Node_Str\" + __TAG_NAME + \"String_Node_Str\" + entity.GetFQName();\n CmdResult res = null;\n try {\n res = Cleartool.run(cmd);\n... |
"public void update(long id, long runId, State state, Date lastUpdate) {\n TransactionLegacy txn = TransactionLegacy.currentTxn();\n PreparedStatement pstmt = null;\n try {\n pstmt = txn.prepareAutoCloseStatement(\"String_Node_Str\");\n pstmt.setString(1, state.toString());\n pstmt.setStri... |
"public void run() {\n player_list++;\n ban_system++;\n validity_system++;\n if (validity_system >= 10) {\n validitySystem();\n }\n if (ban_system >= 7) {\n banSystem();\n }\n if (Settings.getConfig().playerlistEnable) {\n for (Player player : Bukkit.getOnlinePlayers()) {\n ... |
"public void addWarp(String name, Player player) {\n if (numPublicWarpsPlayer(player) < WarpPermissions.maxPublicWarps(player)) {\n if (warpList.containsKey(name)) {\n player.sendMessage(ChatColor.RED + \"String_Node_Str\" + name + \"String_Node_Str\");\n } else {\n Warp warp = ne... |
"public Blog instantiateBlogByLocalId(int localId) {\n String[] fields = new String[] { \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\"... |
"public void setPassword(String password) {\n if (\"String_Node_Str\".equals(password)) {\n this.password = \"String_Node_Str\";\n return;\n }\n try {\n this.password = EncryptionGuard.encode(password);\n } catch (UnsupportedEncodingException e) {\n logger.warn(\"String_Node_Str\... |
"protected Composite getComponent(Composite parent) {\n ChartUIUtil.bindHelp(parent, ChartHelpContextIds.POPUP_LEGEND_BLOCK);\n cmpContent = new Composite(parent, SWT.NONE);\n {\n GridLayout glMain = new GridLayout();\n glMain.horizontalSpacing = 5;\n glMain.verticalSpacing = 5;\n g... |
"private Set<JobInfo> getClonedJobInfos() {\n if (this.clonedJobInfos.isEmpty()) {\n Set<JobInfo> buildChildrenJobs = getJobProcessor().getBuildChildrenJobs();\n for (JobInfo jobInfo : buildChildrenJobs) {\n if (!clonedJobInfos.contains(jobInfo)) {\n JobInfo newJobInfo = newJo... |
"public void setComponent(Component component) {\n if (this.component == component) {\n return;\n }\n this.component = component;\n if (embeddedPeer != null) {\n embeddedPeer.dispose();\n embeddedPeer = null;\n }\n if (component != null) {\n checkContainer();\n }\n ad... |
"private void setPresence(final Presence presence, final RosterItem item) {\n final Presence.Type type = presence.getType();\n if (type == Presence.Type.unavailable) {\n item.setAvailable(false, resource);\n } else {\n item.setAvailable(true);\n }\n final Show showReceived = presence.getSho... |
"public void onCreate(Bundle savedInstanceState) {\n super.onCreate(savedInstanceState);\n EntitySelectActivity oldActivity = (EntitySelectActivity) this.getDestroyedActivityState();\n if (savedInstanceState != null) {\n mResultIsMap = savedInstanceState.getBoolean(EXTRA_IS_MAP, false);\n }\n try ... |
"public void testSupportedWithHdfs2() {\n ClusterCreate cluster = new ClusterCreate();\n cluster.setDistroVendor(Constants.DEFAULT_VENDOR);\n cluster.setDistroVersion(\"String_Node_Str\");\n assertEquals(false, cluster.supportedWithHdfs2());\n cluster.setDistroVendor(Constants.CDH_VENDOR);\n cluster.s... |
"private void deleteTestCases(IProxyRepositoryFactory factory, DeleteActionCache deleteActionCache, final IRepositoryNode currentJobNode, Boolean confirm) throws PersistenceException, BusinessException {\n if (currentJobNode.getType() != ENodeType.REPOSITORY_ELEMENT) {\n return;\n }\n if (!(currentJobNo... |
"protected void setUp() throws Exception {\n super.setUp();\n environment = new CompilerEnvirons();\n}\n"
|
"protected ListWriter serializeList(final String type) {\n throw new MediaTypeNotSupportedException(Response.Status.NOT_ACCEPTABLE, supported, requested);\n}\n"
|
"void delete() {\n if (statusFile != null && !statusFile.delete()) {\n statusFile.deleteOnExit();\n }\n}\n"
|
"protected void loadSettingsBlocking(boolean notifyOnClear) {\n File[] tempDirVar;\n synchronized (this) {\n _size = 0;\n _numFiles = 0;\n _files = new ArrayList();\n _index = new Trie(true);\n _extensions = new TreeSet(new StringComparator());\n _sharedDirectories = new ... |
"public void testComplexConditionCaseInCriteriaUpdate() {\n if ((JUnitTestCase.getServerSession()).getPlatform().isSymfoware()) {\n getServerSession().logMessage(\"String_Node_Str\" + \"String_Node_Str\");\n return;\n }\n EntityManager em = createEntityManager();\n List<Employee> results = nul... |
"void destroyDeferredSurfaceLocked() {\n try {\n if (mPendingDestroySurface != null) {\n if (SHOW_TRANSACTIONS || SHOW_SURFACE_ALLOC) {\n WindowManagerService.logSurface(mWin, \"String_Node_Str\", true);\n }\n mPendingDestroySurface.destroyInTransaction();\n ... |
"private ImageCRS parseImageCRS(final int mode, final Element parent) throws ParseException {\n final Element element = parent.pullElement(mode, WKTKeywords.ImageCRS);\n if (element == null) {\n return null;\n }\n final String name = element.pullString(\"String_Node_Str\");\n final ImageDatum datu... |
"public void handleSelectionChanged(ISelection selection) {\n if (editorUIEnabled == true) {\n saveModel();\n }\n if (selection != null) {\n Object[] sel = ((IStructuredSelection) selection).toArray();\n IElementPropertyDefn targetMethod = null;\n if (sel.length == 1) {\n ... |
"public void updateSoundBar(int soundLevel) {\n if (soundIndicator != null)\n soundIndicator.updateSoundLevel(soundLevel);\n}\n"
|
"public void run() {\n while (true) {\n try {\n WatchKey key = watcher.take();\n Path dir = keys.get(key);\n for (WatchEvent<?> event : key.pollEvents()) {\n WatchEvent<Path> ev = cast(event);\n Path child = dir.resolve(ev.context());\n ... |
"private void loadComponent0(Component comp, boolean loadinit) {\n loadComponentProperties0(comp, loadinit);\n final Map<String, List<Binding>> compBindings = _bindings.get(comp);\n if (_activating || compBindings == null || !compBindings.keySet().contains(CHILDREN_ATTR)) {\n for (Component kid = comp.g... |
"private static SymbolType valueOfClass(Class<?> type, SymbolType arg, Map<String, SymbolType> updatedTypeMapping, Map<String, SymbolType> typeMapping) throws InvalidTypeException {\n SymbolType returnType;\n Class<?> aux = type;\n returnType = new SymbolType();\n int arrayCount = 0;\n while (aux.isArray... |
"public void _testBug793616() {\n if (props.TestExpDependencies.get() > 0) {\n return;\n }\n final long start = System.currentTimeMillis();\n Connection connection = getTestContext().getFoodMartConnection();\n final String queryString = \"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str... |
"private void doUpdateStructure(SparseBlockMatrix M, SparseBlockMatrix GT) {\n int nactive = mySys.numActiveComponents();\n myNumActiveBodies = 0;\n for (int ci = 0; ci < nactive; ci++) {\n if (componentIsRigidBody(ci, M)) {\n myNumActiveBodies++;\n }\n }\n if (myNumActiveBodies ... |
"public void writeStartElement(String prefix, String localName, String namespaceURI) throws XMLStreamException {\n String effectiveName = getEffectiveName(namespaceURI, localName);\n processingStack.get(depth).isNotEmpty = true;\n processingStack.get(depth).currentName = effectiveName;\n try {\n bool... |
"public void run() {\n while (!isInterrupted()) {\n try {\n Runnable task = tasks.take();\n task.run();\n int cycles = 0;\n while (tasks.peek() == null) {\n Thread.yield();\n if (cycles++ == 1024) {\n interrupt();\n ... |
"private void doNotify(Jedis jedis, String key) {\n for (Map.Entry<Node, Set<NotifyListener>> entry : new HashMap<Node, Set<NotifyListener>>(getSubscribed()).entrySet()) {\n doNotify(jedis, Collections.singletonList(key), new HashSet<NotifyListener>(entry.getValue()), false);\n }\n}\n"
|
"public Boolean call() throws Exception {\n LOG.log(Level.INFO, \"String_Node_Str\");\n FileObject fileObject = dataObject.getPrimaryFile();\n final String content;\n try {\n content = fileObject.asText();\n if (content.endsWith(\"String_Node_Str\") || content.endsWith(\"String_Node_Str\")) {\... |
"public void addLineToTicket(String ticketId, String productId) {\n ticket = new TicketDAO();\n product = new ProductDAO();\n category = new CategoryDAO();\n tax = new TaxDAO();\n taxesLogic = new TaxesLogic(tax.getTaxList());\n TicketInfo obj = ticket.getTicket(ticketId);\n ProductInfo productObj ... |
"public void onSuccess(Boolean result) {\n Set<String> indirectRoles = new HashSet<>(allRoles);\n indirectRoles.removeAll(directRoles);\n permissionsPanel.checkPermissions(directRoles, RodaConstants.ADMINISTRATORS.equals(name));\n permissionsPanel.checkPermissions(indirectRoles, true);\n WCAGUtilities.ge... |
"private String readChecksum(File outputFile, String arcfileName) throws IOFailure, IllegalState {\n List<String> lines = FileUtils.readListFromFile(outputFile);\n List<String> checksumList = new ArrayList<String>();\n for (String line : lines) {\n String readFileName = \"String_Node_Str\";\n Str... |
"public void run() {\n logger.debug(\"String_Node_Str\", ip, port);\n sendCommand(new EiscpMessage.MessageBuilder().command(EiscpCommand.POWER_QUERY.getCommand()).value(EiscpCommand.POWER_QUERY.getValue()).build());\n}\n"
|
"public void onClick(View v) {\n if (lensListSize > 0)\n DialogHelper.lensDialog(getContext(), loadedLensesTextView, inflater, container);\n else\n Toast.makeText(v.getContext(), \"String_Node_Str\", Toast.LENGTH_SHORT).show();\n}\n"
|
"public boolean preProcess(HttpServletRequest request, HttpServletResponse response) throws Exception {\n decodeServletPathForSpringUrlMapping(request);\n String path = request.getRequestURI();\n if (StringUtils.isBlank(path)) {\n writeError400Response(response);\n return false;\n }\n Strin... |
"public void addSpecialAction(Ability source, Game game, ManaCost unpaid) {\n Player controller = game.getPlayer(source.getControllerId());\n if (controller != null && game.getBattlefield().contains(filterUntapped, controller.getId(), 1, game)) {\n if (unpaid.getMana().getColorless() > 0 && source.getAbili... |
"private MibType initializeReference(MibSymbol symbol, MibLoaderLog log, MibTypeSymbol ref) throws MibException {\n MibType type = ref.getType();\n if (type != null) {\n type = type.initialize(symbol, log);\n }\n if (type == null) {\n return null;\n }\n try {\n if (constraint != n... |
"public static Collection<IRelationType> getIRelationTypes(Collection<String> rels) throws OseeCoreException {\n Collection<IRelationType> types = new LinkedHashSet<IRelationType>();\n for (String value : rels) {\n long longUuid = parseUuid(value);\n if (longUuid != -1L) {\n types.add(Tok... |
"public DataBag exec(Tuple input) throws IOException {\n DataBag bag = BagFactory.getInstance().newDefaultBag();\n TupleFactory tupleFactory = TupleFactory.getInstance();\n if (input == null) {\n return null;\n }\n int size = input.size();\n if (size == 0 || input.size() != this.columnConfigLis... |
"protected void initCubeCursor() throws OLAPException, BirtException {\n if (cubeCursor == null) {\n cubeCursor = getCubeCursor();\n List<EdgeCursor> edges = cubeCursor.getOrdinateEdge();\n if (edges.size() == 0) {\n throw new ChartException(ChartReportItemPlugin.ID, ChartException.DA... |
"public String[] getCommandLine() throws ProcessorException {\n String command;\n try {\n command = getInterpreter();\n } catch (ProcessorException e1) {\n command = \"String_Node_Str\";\n }\n boolean win32 = false;\n String classPathSeparator;\n if (targetPlatform == null) {\n ... |
"private static boolean isEqualGroup(IGroupDefinition groupDefn1, IGroupDefinition groupDefn2) {\n if (groupDefn1 == groupDefn2)\n return true;\n if (groupDefn1 == null || groupDefn2 == null)\n return false;\n return isEqualStr(groupDefn1.getName(), groupDefn2.getName()) && isEqualStr(groupDefn1.... |
"public void run() {\n ImmutableTriple<List<TurboIssue>, String, Date> changes = repo.getUpdatedIssues(model.getRepoId().generateId(), model.getUpdateSignature().issuesETag, model.getUpdateSignature().lastCheckTime);\n List<TurboIssue> existing = model.getIssues();\n List<TurboIssue> changed = changes.left;\n ... |
"protected static List<ContentValues> getValuesForPostalAddresses(VCard vCard) {\n List<ContentValues> valuesList = new LinkedList<ContentValues>();\n for (ezvcard.property.Address address : vCard.getAddresses()) {\n ContentValues values = new ContentValues();\n values.put(ContactsContract.Data.MIME... |
"private static <T> T lookupByPattern(Map<String, T> map, String name) {\n T t = map.get(name);\n if (t == null) {\n int lastMatchingPoint = -1;\n for (Map.Entry<String, T> entry : map.entrySet()) {\n String pattern = entry.getKey();\n T value = entry.getValue();\n f... |
"public void performGibbsSampling() {\n for (int iterationNumber = 0; iterationNumber < burnInIterations; iterationNumber++) {\n samplePriorsAndBurn(0);\n sampleLabelsAndBurnWithCollapsedErrorRates(0);\n sampleZAndBurnWithCollapsedErrorRates(0);\n sampleInternalTableTopicsAndBurnWithColla... |
"public void buildDeletedItemsTree(RepositoryNode rootNode) {\n List<String> folders = RecycleBinManager.getInstance().getDeletedFolders(ProjectManager.getInstance().getCurrentProject());\n Collections.sort(folders);\n for (String fullPath : folders) {\n String path = null;\n ERepositoryObjectTyp... |
"public List<NATTraversalTechnique> getAllFallbackTechniques() {\n List<NATTraversalTechnique> result = new ArrayList<NATTraversalTechnique>();\n List<NATTraversalTechnique> all = this.getAllSupportedNATTraversalTechniques();\n for (NATTraversalTechnique natTraversalTechnique : all) {\n if (natTraversal... |
"private void generateCommandResourceClass(String parentBeanName, CommandResourceMetaData metaData) {\n String commandResourceClassName = getClassName(parentBeanName + getBeanName(metaData.resourcePath));\n String commandName = metaData.command;\n String commandDisplayName = metaData.resourcePath;\n String ... |
"public static void blotMobilePiece(TetrisState ts) {\n Vector<TetrisPiece> possibleBlocks = TetrisState.POSSIBLE_BLOCKS;\n int[][] mobilePiece = possibleBlocks.get(ts.currentBlockId).getShape(ts.currentRotation);\n for (int x = 0; x < mobilePiece.length; x++) {\n for (int y = 0; y < mobilePiece[x].leng... |
"public Set<Dependency> deserializeDependenciesForward(byte[] serialized) throws IOException {\n final StructRowKey singleEntryRowKey = entrySerializationRowKey();\n final Set<DependencyEntry> result = new HashSet<DependencyEntry>();\n final ImmutableBytesWritable bw = new ImmutableBytesWritable(serialized);\n... |
"public void retire(BigInteger id, Integer retire) {\n Project project = getNotNullById(id);\n Config config = configService.getConfigByTokenName(project.getTokenName());\n Boolean canRetire = project.getStatus().equals(2) && project.getRetire().equals(0) && config.getWithdrawStatus().equals(0);\n Assert.is... |
"public boolean isAccessible(Var var) {\n Arg varArg = var.asArg();\n if (!isUnpassable(varArg)) {\n return true;\n }\n CongruentSets curr = this;\n boolean allPassed = true;\n while (curr != null) {\n if (curr.canonicalInv.containsKey(varArg)) {\n return allPassed;\n }... |
"void joinReset() {\n joinInProgress = false;\n setJoins.clear();\n timeToStartJoin = System.currentTimeMillis() + WAIT_MILLIS_BEFORE_JOIN;\n}\n"
|
"public double getAccuracyOrTooWeakExact(Description description, double noise) {\n nanoStartTime = System.nanoTime();\n if (heuristic.equals(HeuristicType.JACCARD)) {\n TreeSet<Individual> coveredInstancesSet = new TreeSet<Individual>();\n for (Individual ind : classInstances) {\n if (re... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.