content
stringlengths
40
137k
"protected void action() {\n switch(state) {\n case AGGRESSIVE:\n break;\n case HITTING:\n hitEnemy(enemy);\n if (state != ESoldierState.HITTING) {\n break;\n }\n if (enemy.getHealth() <= 0) {\n enemy = null;\n ...
"public String getPropertyBinding(String propName) {\n if (propName == null)\n return null;\n return propBinding.getValue();\n}\n"
"public String toString(String path, boolean pcode, boolean isStatic, int scriptIndex, int classIndex, ABC abc, ConstantPool constants, MethodInfo[] method_info, Stack<GraphTargetItem> scopeStack, boolean isStaticInitializer, boolean hilight, List<String> fullyQualifiedNames, Traits initTraits) {\n if (debugMode) {\...
"public void dispose() {\n if (partListener != null) {\n editor.getEditorSite().getPage().removePartListener(partListener);\n mcl.uninstall();\n super.dispose();\n}\n"
"private SendQueue<MethodCall<Object>> handleByAddressCall(MethodCall<Object> methodCall) {\n SendQueue<MethodCall<Object>> sendQueue;\n final String callAddress = methodCall.address();\n sendQueue = serviceMapping.get(callAddress);\n if (sendQueue == null) {\n String addr;\n addr = seenAddres...
"public void testSecStrucPred() throws StructureException, IOException {\n List<String> names = Arrays.asList(\"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\");\n SecStrucCalc sec = new SecStrucCalc();\n for (Strin...
"public byte[] doInTransform(Instrumentor instrumentor, ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer) throws InstrumentException {\n final InstrumentClass target = instrumentor.getInstrumentClass(loader, className, classfileBuffer);\n ...
"public void put(Request req) {\n long now = System.currentTimeMillis();\n boolean sendEvictEvent = false;\n Record evictedRecord = null;\n if (req.value == null) {\n req.value = new Data();\n }\n Record record = getRecord(req);\n if (record != null && !record.isValid(now)) {\n if (re...
"public void run() {\n displayURL(url, considerInternal);\n}\n"
"protected String getLibsClasspath() throws ProcessorException {\n final boolean exportingJob = ProcessorUtilities.isExportConfig();\n final String classPathSeparator = extractClassPathSeparator();\n final String basePathClasspath = getBasePathClasspath();\n final String neededModulesJarStr = getNeededModul...
"public void setStatusMessage(String status) {\n this.status = status;\n hablarEventBus.fireEvent(new UserMessageEvent(status, this));\n if (visibility != Visibility.focused) {\n view.getHeader().requestFocus();\n }\n}\n"
"protected IReportItemExecutor prepareChildExecutor() throws Exception {\n if (prepareFirstChild) {\n if (fragment == null && nextOffset == -1) {\n DocumentExtension docExt = (DocumentExtension) content.getExtension(IContent.DOCUMENT_EXTENSION);\n if (docExt != null) {\n n...
"public Object visitIfExprNode(IfExprNode node, LinkedList args) {\n LinkedList e1StringList = (LinkedList) node.childReturnValueAt(node.CHILD_INDEX_EXPR1);\n LinkedList e2StringList = (LinkedList) node.childReturnValueAt(node.CHILD_INDEX_EXPR2);\n LinkedList e3StringList = (LinkedList) node.childReturnValueAt...
"public void onManagementStarted() {\n Map<?, ?> flags = MutableMap.builder().put(\"String_Node_Str\", \"String_Node_Str\").put(\"String_Node_Str\", ImmutableSet.of(getConfig(HOSTNAME_SENSOR))).build();\n policy = new AbstractMembershipTrackingPolicy(flags) {\n protected void onEntityChange(Entity member) ...
"private void newAggregationResultRow(Row4Aggregation row) throws DataException, IOException {\n currentResultObj = new AggregationResultRow();\n if (levelCount > 0) {\n currentResultObj.setLevelMembers(new Member[levelCount]);\n System.arraycopy(row.getLevelMembers(), 0, currentResultObj.getLevelMe...
"public void destroy() {\n this.soundSystem.removeSource(sourceName);\n}\n"
"public int size() {\n int size = 0;\n size += Utils.sizeOfLong(deposit.getValue());\n size += Utils.sizeOfString(this.agentAddress);\n size += Utils.sizeOfDouble(this.commissionRate);\n size += Utils.sizeOfString(this.introduction);\n size += Utils.sizeOfBoolean(seed);\n size += Utils.sizeOfString...
"public boolean compoundsEquivalent(C compoundOne, C compoundTwo) {\n assertCompound(compoundOne);\n assertCompound(compoundTwo);\n return compoundOne.equals(compoundTwo) || equivalentsMap.get(compoundOne).contains(compoundTwo);\n}\n"
"private void checkNotClosed() throws IOException {\n if (closed) {\n throw new IOException(\"String_Node_Str\");\n }\n}\n"
"public LineMarkerInfo getLineMarkerInfo(final PsiElement element) {\n if (element instanceof PsiMethod) {\n PsiMethod psiMethod = (PsiMethod) element;\n PsiAnnotation subscriberAnnotation = PsiConsultantImpl.findAnnotationOnMethod(psiMethod, OttoProjectHandler.SUBSCRIBE_CLASS_NAME);\n if (subsc...
"private List<MediaFormat> getAdvancedFormatParameters(List<MediaFormat> remoteFormats, List<MediaFormat> localFormats) {\n List<MediaFormat> ret = new ArrayList<MediaFormat>();\n for (MediaFormat remoteFormat : remoteFormats) {\n MediaFormat localFormat = findMediaFormat(localFormats, remoteFormat);\n ...
"public long addTemplateToZone(VMTemplateVO tmplt, long zoneId) {\n Transaction txn = Transaction.currentTxn();\n txn.start();\n VMTemplateVO tmplt2 = findById(tmplt.getId());\n if (tmplt2 == null) {\n if (persist(tmplt) == null) {\n throw new CloudRuntimeException(\"String_Node_Str\" + tm...
"private boolean isInputFilename(String[] inputFilenames, String sampleId) {\n for (final String input : inputFilenames) {\n String commandLineBasename = FilenameUtils.getName(AlignmentReaderImpl.getBasename(input));\n if (commandLineBasename.equals(FilenameUtils.getName(AlignmentReaderImpl.getBasename...
"public void create(Table table) {\n spriteBatch = new SpriteBatch();\n world = createWorld();\n character = createSteeringEntity(world, container.greenFish);\n character.setMaxLinearSpeed(5);\n character.setMaxLinearAcceleration(10);\n target = createSteeringEntity(world, container.target);\n mark...
"public void migrate(Module jcrModule, AssetItem jcrAssetItem) {\n Path path = migrationPathManager.generatePathForAsset(jcrModule, jcrAssetItem);\n final org.kie.commons.java.nio.file.Path nioPath = paths.convert(path);\n Map<String, Object> attrs;\n try {\n attrs = ioService.readAttributes(nioPath)...
"private void onCommandSubmittedImpl(final msg_set_mode command, ICommandListener listener) {\n final int commandId = command.msgid;\n final CallbackKey<msg_command_ack> key = new CallbackKey<msg_command_ack>(commandId) {\n\n public int checkAckResult(ApmModes result) {\n return result.getNumber...
"protected short getMaxSearchDistance(boolean isInTower) {\n return isInTower ? Constants.TOWER_ATTACKABLE_SEARCH_RADIUS : Constants.SOLDIER_SEARCH_RADIUS;\n}\n"
"public Object getBackPageIdentifier() {\n return null;\n}\n"
"public void processResource(Query query) {\n CrawlerConsole.print(\"String_Node_Str\" + query.getOriginalURL().toString());\n byte[] bytes = query.getResource().getBytes();\n String html = new String(bytes);\n String host = query.getHost();\n if (url.split(\"String_Node_Str\").length < 4) {\n url...
"public List<Camera> getCameras() throws CameraException {\n try {\n cameraService.setAllCamerasInactive();\n } catch (ServiceException e) {\n LOGGER.debug(\"String_Node_Str\");\n }\n int count = 0;\n final CameraList cl = new CameraList();\n try {\n LOGGER.debug(\"String_Node_Str...
"public static boolean hasFactions() {\n return factionsPlugin != null && factionsPlugin.isEnabled();\n}\n"
"private Map<? super Object, ? super Object> resolveMapValueWhenMapIsPojoAttribute(Object pojo, ManufacturingContext manufacturingCtx, AttributeMetadata attributeMetadata, Map<String, Type> typeArgsMap) {\n String attributeName = attributeMetadata.getAttributeName();\n Map<Object, Object> defaultValue = null;\n ...
"public void writeInt(int value) throws IOException {\n input[inputSize] = value;\n ++inputSize;\n if (inputSize == VALUES_WRITTEN_AT_A_TIME) {\n pack();\n if (packedPosition == slabSize) {\n slabs.add(BytesInput.from(packed));\n initPackedSlab();\n }\n }\n}\n"
"List<IFile> findProjectPvdbs(IProject project, boolean onlyThoseNeedingToBeDeployed) {\n List<IFile> pvdbsToDeploy = new ArrayList<IFile>();\n Collection<PreviewVdbStatus> statuses = null;\n try {\n this.statusLock.readLock().lock();\n statuses = this.deploymentStatusMap.get(project.getFullPath(...
"public void run() {\n OutputTreeNode model = (OutputTreeNode) nodePart.getModel();\n OutputTreeNode outputDocumentRoot = (OutputTreeNode) XmlMapUtil.getTreeNodeRoot(model);\n if (outputDocumentRoot != null) {\n XmlMapUtil.cleanSubGroup(outputDocumentRoot);\n }\n if (!isRemove) {\n model.se...
"public void run() {\n for (int count = 0; ; count++) {\n VM_GreenScheduler.collectorMutex.lock(\"String_Node_Str\");\n if (verbose >= 1)\n VM.sysWriteln(\"String_Node_Str\");\n if (count > 0) {\n VM_GreenProcessor.getCurrentProcessor().enableThreadSwitching();\n }\n...
"public void uninstall(String code) {\n String[] columns = { InstalledAppDb.COLUMN_PKG_NAME, InstalledAppDb.COLUMN_DOWNLOAD_URI };\n String where = InstalledAppDb.COLUMN_CODE + \"String_Node_Str\";\n String[] whereArgs = { code };\n Cursor c = this.getContentResolver().query(BehooProvider.INSTALLED_APP_CONT...
"public void parse(ModelCriterion criterion, boolean _default) {\n if (!(criterion instanceof ModelRiskBasedCriterion)) {\n return;\n }\n ModelRiskBasedCriterion other = (ModelRiskBasedCriterion) criterion;\n this.threshold = other.threshold;\n this.variant = other.variant;\n if (!_default) {\n...
"public int[] readTile(int x, int y, int width, int height, int band) {\n Rectangle rect = new Rectangle(x, y, width, height);\n rect = rect.intersection(bounds);\n int[] tile = new int[height * width];\n if (rect.isEmpty()) {\n return tile;\n }\n if (rect.y != preloadedInterval[0] | rect.y + r...
"public void writeToParcel(Parcel dest, int flags) {\n dest.writeParcelable(this.app, flags);\n dest.writeString(this.description);\n dest.writeParcelable(this.pictures, flags);\n dest.writeParcelable(this.infoICO, flags);\n}\n"
"void activate() {\n if (isTerminated()) {\n return;\n }\n if (!isAlive()) {\n setPriority(priority);\n start();\n } else {\n mother.traceLocks(\"String_Node_Str\" + getName());\n try {\n goLock.lockInterruptibly();\n if (status == StatusValues.DORMAN...
"public void reverse() {\n SPARQL_Term newVariable = new SPARQL_Term(this.value.getName());\n newVariable.setIsVariable(this.value.isVariable());\n if (value instanceof SPARQL_Term) {\n newVariable.setIsURI(((SPARQL_Term) value).isURI);\n }\n SPARQL_Term newValue = new SPARQL_Term(this.variable.ge...
"public static void openTheme(final URL url, final ThemeOpenDelegate delegate) {\n if (url == null) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n boolean file = \"String_Node_Str\".equalsIgnoreCase(url.getProtocol());\n final ProgressMonitor progress = new IndeterminateProgressMo...
"private Expression divide(Expression first, double red1, double green1, double blue1, double red2, double green2, double blue2, HiddenTokenAwareTree parentToken) {\n if (first.getType() == ASTCssNodeType.NUMBER) {\n problemsHandler.subtractOrDiveColorFromNumber(first);\n return new FaultyExpression(fi...
"public void onResponseReceived(Request request, Response response) {\n final String activeTheme = response.getText();\n RequestBuilder getThemesRequestBuilder = new RequestBuilder(RequestBuilder.GET, GWT.getHostPageBaseURL() + \"String_Node_Str\");\n getThemesRequestBuilder.setHeader(\"String_Node_Str\", \"St...
"public static BeansWrapper getInstance(Version incompatibleImprovements, SettingAssignments settings) {\n DefaultObjectWrapper res;\n if (!settings.equals(SettingAssignments.DEFAULT)) {\n return new DefaultObjectWrapper(incompatibleImprovements, settings);\n }\n incompatibleImprovements = normalizeI...
"private void extractFiles() throws IOException {\n Const.RecoveryCollectionFile = new File(mContext.getFilesDir(), \"String_Node_Str\");\n Common.pushFileFromRAW(mContext, Const.RecoveryCollectionFile, R.raw.recovery_sums, mVersionChanged);\n Const.KernelCollectionFile = new File(mContext.getFilesDir(), \"Str...
"public void purge() {\n if (purger != null) {\n this.purger.purge(logIDs);\n }\n}\n"
"public static Class<?> getGenericClass(Field collectionField) {\n Class<?> genericClass = null;\n if (collectionField == null) {\n return genericClass;\n }\n if (isCollection(collectionField.getType())) {\n Type[] parameters = ReflectUtils.getTypeArguments(collectionField);\n if (param...
"public void testExistingProductContentAdded() throws Exception {\n Owner owner = new Owner(\"String_Node_Str\");\n Product oldProduct = TestUtil.createProduct(\"String_Node_Str\", \"String_Node_Str\", owner);\n Product newProduct = TestUtil.createProduct(\"String_Node_Str\", \"String_Node_Str\", owner);\n ...
"public boolean onBlockActivated(World worldIn, BlockPos pos, IBlockState state, EntityPlayer playerIn, EnumHand hand, ItemStack heldItem, EnumFacing side, float hitX, float hitY, float hitZ) {\n state = getActualState(state, worldIn, pos);\n if (state.getValue(POWERED))\n return true;\n TileEntityKeyBu...
"private static void addStationResult(Collection<StationResult> results, JSONObject point) throws JSONException {\n String name = point.getString(\"String_Node_Str\");\n String id = point.getJSONObject(\"String_Node_Str\").getString(\"String_Node_Str\");\n int quality = (point.has(\"String_Node_Str\")) ? point...
"protected File getLibJavaFolderFile(BundleContext theContext) throws URISyntaxException {\n String libFolderSysProp = System.getProperty(ORG_TALEND_EXTERNAL_LIB_FOLDER_SYS_PROP);\n if (libFolderSysProp != null) {\n return new File(libFolderSysProp);\n } else {\n Location installLocation = getCon...
"public void guiTestDispose() {\n TextComponentMatcherEditor<String> textMatcherEditor = null;\n eventCounter.assertNoEvents(0);\n boolean[] liveOptions = { true, false };\n for (int b = 0; b < liveOptions.length; b++) {\n JTextField textField = new JTextField();\n textMatcherEditor = new Text...
"void moveActivityToStackLocked(ActivityRecord r, int stackId, String reason, Rect bounds) {\n final TaskRecord task = r.task;\n if (task.mActivities.size() == 1) {\n moveTaskToStackLocked(task.taskId, stackId, ON_TOP, FORCE_FOCUS, reason, true);\n } else {\n final ActivityStack stack = getStack(...
"public static ItemStack findFirstChargableArmor(EntityLivingBase elb) {\n for (EntityEquipmentSlot slot : ItemStackUtility.ARMOR_SLOTS) {\n ItemStack equipment = elb.getItemStackFromSlot(slot);\n Item item = equipment.getItem();\n if (item instanceof SteamChargable && ((SteamChargable) item).ca...
"public void writeBefore(final MatcherContext<?> context) throws IOException {\n final Matcher matcher = context.getMatcher();\n final String name = matcher.getClass().getSimpleName();\n sb.setLength(0);\n sb.append(BEFORE_MATCH).append(';').append(context.getCurrentIndex()).append(';').append(context.getLe...
"private void cleanupAppWidgetIds() {\n if (!KeyguardUpdateMonitor.getInstance(mContext).hasBootCompleted()) {\n mCleanupAppWidgetsOnBootCompleted = true;\n return;\n }\n if (!mSafeModeEnabled && !widgetsDisabledByDpm()) {\n int[] appWidgetIdsInKeyguardSettings = mLockPatternUtils.getAppWi...
"public Object get(String name, Scriptable start) {\n if (\"String_Node_Str\".equalsIgnoreCase(name)) {\n if (this.helper.getParent() != null)\n return helper.getParent().getJSRowObject();\n else\n return null;\n }\n int rowIndex = -1;\n try {\n rowIndex = odiResul...
"public boolean apply(Game game, Ability source) {\n Player opponent = game.getPlayer(this.getTargetPointer().getFirst(game, source));\n if (opponent != null) {\n FilterCreaturePermanent filter = new FilterCreaturePermanent();\n filter.add(new TappedPredicate());\n filter.add(new ControllerId...
"private PatternMatchingIndicator createPatternMatchingIndicator() {\n PatternMatchingIndicator patternMatchingIndicator = IndicatorsFactory.eINSTANCE.createPatternMatchingIndicator();\n IndicatorParameters indicParams = IndicatorsFactory.eINSTANCE.createIndicatorParameters();\n Domain validData = DomainFactor...
"public static final void playSound(int _index, float _speed) {\n if (Options.sounds) {\n float streamVolume = audioManager.getStreamVolume(AudioManager.STREAM_MUSIC);\n streamVolume = streamVolume / audioManager.getStreamMaxVolume(AudioManager.STREAM_MUSIC);\n soundPool.play((Integer) soundPool...
"public static <A> Aggregates<A> carveN(final Aggregates<? extends A> aggregates, final int[][] dropList) {\n Aggregates<A> result = AggregateUtils.make(aggregates.lowX(), aggregates.lowY(), aggregates.highX() - dropList[0].length, aggregates.highY(), (A) aggregates.defaultValue());\n for (int y = aggregates.lowY...
"public CompoundVector getPlateauNaturalParameterPrior() {\n List<Vector> naturalPlateauParametersPriors = ef_learningmodel.getDistributionList().stream().map(dist -> dist.getVariable()).filter(var -> isNonReplicatedVar(var)).map(var -> {\n NaturalParameters parameter = this.ef_learningmodel.getDistribution(v...
"protected JFreeChart createGraph() {\n Map<Axis, CategoryDataset> dataSets = new LinkedHashMap<>();\n Map<Axis, DataSetBuilder<String, NumberOnlyBuildLabel>> dataSetBuilders = createDataSetBuilder(obj);\n for (Entry<Axis, DataSetBuilder<String, NumberOnlyBuildLabel>> e : dataSetBuilders.entrySet()) {\n ...
"protected static List<HiveConnVersionInfo> getObjectsByLevel(int level) {\n HiveConnVersionInfo[] beans = HiveConnVersionInfo.values();\n if (beans != null && beans.length > 0) {\n List<HiveConnVersionInfo> list = new ArrayList<HiveConnVersionInfo>();\n for (HiveConnVersionInfo bean : beans) {\n ...
"public void messageReceived(ChannelHandlerContext ctx, MessageEvent e) throws Exception {\n Object o = e.getMessage();\n if (o instanceof HttpResponse) {\n this.dashBoundary = null;\n this.closeBoundary = null;\n HttpResponse response = (HttpResponse) o;\n if (response.isChunked()) {\...
"static public IBaseQueryResults executeQuery(IBaseQueryResults parent, IDataQueryDefinition query, String rset, ExecutionContext executionContext) throws EngineException {\n try {\n DataRequestSession dataSession = executionContext.getDataEngine().getDTESession();\n if (dataSession == null)\n ...
"protected void onDraw(Canvas canvas) {\n super.onDraw(canvas);\n String text = (isMarkValid(mMark) ? String.valueOf(mMark) : \"String_Node_Str\") + \"String_Node_Str\";\n if (!TextUtils.isEmpty(text)) {\n float textHeight = mTextPaint.descent() + mTextPaint.ascent();\n float yPositionOfText = (g...
"protected String getExpressionStorePath() {\n IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot();\n RepositoryContext repositoryContext = (RepositoryContext) CorePlugin.getContext().getProperty(Context.REPOSITORY_CONTEXT_KEY);\n Project project = repositoryContext.getProject();\n IProject p = r...
"private void populateList() {\n if (serverDestinationList == null) {\n return;\n }\n if (serverDestinationList.equals(destinationList)) {\n return;\n }\n destinationList = new ArrayList<TeleportDestinationClientInfo>(serverDestinationList);\n list.removeChildren();\n for (TeleportDes...
"static Set<Class<?>> getFromJARFile(String jar, String packageName) throws IOException, ClassNotFoundException {\n Set<Class<?>> classes = new HashSet<Class<?>>();\n JarInputStream jarFile = new JarInputStream(new FileInputStream(jar));\n JarEntry jarEntry;\n do {\n jarEntry = jarFile.getNextJarEntr...
"public void testPropertiesOfDynamicParameter() throws Exception {\n SlotHandle params = designHandle.getParameters();\n ScalarParameterHandle handle = (ScalarParameterHandle) params.get(0);\n SlotHandle dataset = designHandle.getDataSets();\n DataSetHandle ds = (DataSetHandle) dataset.get(0);\n assertEq...
"private void testDimensionCreate5(IDocumentManager documentManager) throws IOException, BirtException, DataException {\n ILevelDefn[] levelDefs = new ILevelDefn[4];\n levelDefs[0] = new LevelDefinition(\"String_Node_Str\", new String[] { \"String_Node_Str\" }, null);\n levelDefs[1] = new LevelDefinition(\"Str...
"public void initialize() throws IOException {\n String port = networkListener.getPort();\n portNumber = 8080;\n if (port == null) {\n logger.severe(KernelLoggerInfo.noPort);\n throw new RuntimeException(\"String_Node_Str\");\n }\n try {\n portNumber = Integer.parseInt(port);\n } ...
"public void onCreate() {\n super.onCreate();\n mHandler = new Handler();\n mToneGenerator = new ToneGenerator(AudioManager.STREAM_VOICE_CALL, SipConstants.RINGING_VOLUME);\n mBroadcastManager = LocalBroadcastManager.getInstance(this);\n PhoneAccount phoneAccount = new JsonStorage<PhoneAccount>(this).get...
"public int guessFullNameStyle(String name) {\n if (name == null) {\n return FullNameStyle.UNDEFINED;\n }\n int nameStyle = FullNameStyle.UNDEFINED;\n int length = name.length();\n int offset = 0;\n while (offset < length) {\n int codePoint = Character.codePointAt(name, offset);\n ...
"public void map(Chunk[] chks) {\n int chunkSize = chks[0].len();\n Vec[] vins = frin.vecs();\n long start = chks[0].start();\n for (int r = 0; r < chunkSize; r++) {\n for (int c = 0; c < chks.length; c++) {\n chks[c].set(r, vins[c].at(start + r));\n }\n }\n}\n"
"public void init() {\n openBtn = (XulToolbarbutton) document.getElementById(\"String_Node_Str\");\n saveBtn = (XulToolbarbutton) document.getElementById(\"String_Node_Str\");\n saveAsBtn = (XulToolbarbutton) document.getElementById(\"String_Node_Str\");\n newAnalysisBtn = (XulToolbarbutton) document.getEle...
"public QName addCustomPropertyDefinition(QName propId, QName aspectName, String label, QName dataType, String title, String description, String defaultValue, boolean multiValued, boolean mandatory, boolean isProtected, QName lovConstraint) throws CustomMetadataException {\n if (!isCustomisable(aspectName)) {\n ...
"public void requestClose() throws IOException, InterruptedException {\n if (!this.closeRequested) {\n this.closeRequested = true;\n if (!isBroadcastChannel() || getChannelIndex() == 0) {\n transferEvent(new ByteBufferedChannelCloseEvent());\n }\n }\n}\n"
"protected IAnswerData getWidgetValue() {\n return new ImmunizationAnswerData(d);\n}\n"
"public Node visitProgram(MxParser.ProgramContext ctx) {\n List<Node> declarators = new ArrayList<>();\n Location programPos = new Location(ctx);\n buildClassSymbol(ctx);\n for (ParseTree child : ctx.declarator()) {\n Node childNode = visit(child);\n if (childNode instanceof DeclarationNode) {...
"public synchronized long ensureThreadId() {\n if (DEBUG) {\n LogTag.debug(\"String_Node_Str\" + mThreadId);\n }\n if (mThreadId <= 0) {\n mThreadId = getOrCreateThreadId(mContext, mRecipients);\n }\n if (DEBUG) {\n Log.v(\"String_Node_Str\", \"String_Node_Str\" + mThreadId);\n }\...
"default void unregisterSubscriber(RequestContext requestContext, Subscriber<Object> subscriber) {\n final Class<? extends SubscriptionCollection> subscriptionType = requestContext.getSubscriptionType();\n final SubscriptionCollection subscription = getView(subscriptionType);\n if (subscription == null)\n ...
"public static IRenderer getBestRenderer(PresentationType presentationType, Artifact artifact, Object... options) throws OseeCoreException {\n IRenderer bestRenderer = getBestRendererPrototype(presentationType, artifact, options).newInstance();\n bestRenderer.setOptions(options);\n return bestRenderer;\n}\n"
"private boolean videoEncodeStep(boolean isEnd) {\n if (isEnd) {\n mVideoEncoder.signalEndOfInputStream();\n }\n while (true) {\n int outputIndex = mVideoEncoder.dequeueOutputBuffer(mVideoEncodeBufferInfo, TIME_OUT);\n if (outputIndex >= 0) {\n if (isMuxStarted && mVideoEncodeBu...
"public static void modelBakeEvent(ModelBakeEvent event) {\n boolean replaceVanillaModels = ConfigCoroAI.foliageShaders && EventHandler.queryUseOfShaders();\n boolean textureFix = false;\n if (replaceVanillaModels) {\n Map<ModelResourceLocation, IModel> stateModels = ReflectionHelper.getPrivateValue(Mod...
"public void testClinitSideEffectInlining() {\n sideEffectChecker = 0;\n SideEffectCauser.causeClinitSideEffect();\n assertEquals(1, sideEffectChecker);\n SideEffectCauser2.causeClinitSideEffect();\n assertEquals(2, sideEffectChecker);\n SideEffectCauser3.causeClinitSideEffect();\n assertEquals(3, ...
"public boolean postfire() throws IllegalActionException {\n if (_noMoreActorsToFire && _exceedStopTime) {\n return false;\n } else if (_isEmbedded() && !_eventQueue.isEmpty()) {\n _requestFiring();\n }\n return true;\n}\n"
"public boolean startElement(XPathFragment xPathFragment, UnmarshalRecord unmarshalRecord, Attributes atts) {\n try {\n Descriptor workingDescriptor = findReferenceDescriptor(xPathFragment, unmarshalRecord, atts, xmlAnyObjectMapping, xmlAnyObjectMapping.getKeepAsElementPolicy());\n UnmarshalKeepAsEleme...
"public void onBlockPistonRetract(BlockPistonRetractEvent event) {\n BukkitLocation location = new BukkitLocation(event.getBlock().getLocation());\n if (manager.isPlotWorld(location)) {\n List<Block> blocks = event.getBlocks();\n for (Block moved : blocks) {\n PlotId id = manager.getPlotI...
"public void setCompressedDataBuffer(Buffer buffer) {\n if (buffer == null) {\n this.compressedBuffer = null;\n this.compressedDataBuffer = null;\n this.compressedDataBufferLength = 0;\n } else {\n this.compressedDataBuffer = buffer.getByteBuffer();\n this.compressedBuffer = buf...
"public com.stratio.meta.common.result.QueryResult execute(LogicalWorkflow workflow) throws UnsupportedException, ExecutionException {\n LogicalStep logicalStep = workflow.getInitialSteps().get(0);\n while (logicalStep != null) {\n if (logicalStep instanceof TransformationStep) {\n getTransforma...
"public AuthenticatedUser authenticateUser(Credentials credentials) throws GuacamoleException {\n logger.debug(\"String_Node_Str\", credentials.getUsername());\n String username = credentials.getUsername();\n if (username == null || username.isEmpty())\n throw new GuacamoleInvalidCredentialsException(\"...
"protected String getMessageText(Game game) {\n StringBuilder sb = new StringBuilder();\n MageObject object = game.getObject(this.sourceId);\n if (object != null) {\n if (object instanceof StackAbility) {\n Card card = game.getCard(((StackAbility) object).getSourceId());\n if (card...
"public void init() {\n ClientRegistry.bindTileEntitySpecialRenderer(TileEntityXenPortal.class, new RenderXenPortal());\n ClientRegistry.bindTileEntitySpecialRenderer(TileEntityXenLight.class, new RenderTileEntityModel(new ModelXenLight(), ClientProps.XENLIGHT_PATH).setReverse(true));\n ClientRegistry.bindTile...
"private void onError() {\n if (null != getActivity()) {\n Toast.makeText(getActivity(), getActivity().getString(R.string.could_not_redact), Toast.LENGTH_SHORT).show();\n }\n}\n"
"public Mod parse(byte[] data) {\n ByteReader reader = new ByteReader(data);\n reader.seek(1080);\n if (reader.available() < 4)\n return null;\n String id = reader.string(4);\n ModFormat format = checkType(id);\n if (format == null)\n format = testLegacy(reader);\n if (format == null)...
"public void onBindViewHolder(RecyclerView.ViewHolder vholder, final int p1) {\n final Recycleradapter.ViewHolder holder = ((Recycleradapter.ViewHolder) vholder);\n int i = 0;\n if (main.islist) {\n i = 1;\n if (p1 == 0) {\n holder.rl.setMinimumHeight(main.paddingTop);\n ret...