content
stringlengths
40
137k
"public void asyncResponseBodyTooLarge() throws Throwable {\n AsyncHttpClient c = getAsyncHttpClient(null);\n Response response = c.preparePost(getTargetUrl()).setBody(\"String_Node_Str\").execute(new AsyncCompletionHandlerAdapter() {\n\n public void onThrowable(Throwable t) {\n Assert.fail(\"St...
"public static void freeRun() {\n synchronized (Main.class) {\n if (runTempFile != null) {\n runTempFile.delete();\n runTempFile = null;\n }\n runProcess = null;\n }\n if (mainFrame != null && mainFrame.getPanel() != null) {\n mainFrame.getPanel().clearDebugger...
"private void findAliases(NodeTraversal t) {\n Scope scope = t.getScope();\n for (Var v : scope.getVarIterable()) {\n Node n = v.getNode();\n Node parent = n.getParent();\n boolean isVar = parent.isVar();\n if (isVar && n.getFirstChild() != null && n.getFirstChild().isQualifiedName()) ...
"public boolean onVolumeUp() {\n if (openHABWidgetAdapter != null) {\n return openHABWidgetAdapter.onVolumeUp();\n }\n return false;\n}\n"
"private void updateFriend(int userId) throws QBResponseException {\n QBRosterEntry rosterEntry = roster.getEntry(userId);\n User user = restHelper.loadUser(userId);\n if (user == null) {\n return;\n }\n Friend friend = FriendUtils.createFriend(rosterEntry);\n fillUserOnlineStatus(user);\n F...
"public boolean perform(AbstractBuild<?, ?> build, Launcher launcher, BuildListener listener) throws InterruptedException, IOException {\n PrintStream logger = listener.getLogger();\n logger.println(\"String_Node_Str\");\n logger.println(\"String_Node_Str\" + this.testResults);\n FilePath[] reports = locate...
"private void loadCache() throws FHIRFormatError, IOException {\n File[] files = new File(cacheFolder).listFiles();\n for (File f : files) {\n if (f.getName().endsWith(\"String_Node_Str\")) {\n final FileInputStream is = new FileInputStream(f);\n try {\n Resource r = co...
"private void loadBinary(String location) throws IOException {\n boolean bigEndian = true;\n DataInputStream stream = new DataInputStream(new BufferedInputStream(new FileInputStream(location)));\n int headerLength = stream.readInt();\n bytesRead += 4;\n if (headerLength != (DARPA_LM_HEADER.length() + 1))...
"public static <T extends ImageBase> BenchmarkFeatureDistort<T> rotate(Class<T> imageType) {\n double[] thetas = UtilOrientationBenchmark.makeSample(0, 2.0 * Math.PI, 20);\n return new Rotation<T>(SEED, thetas, imageType);\n}\n"
"public void setAtoms(Atom[] atoms) {\n Structure s = new StructureImpl();\n Chain c = new ChainImpl();\n c.setChainID(\"String_Node_Str\");\n for (Atom a : atoms) {\n c.addGroup(a.getGroup());\n }\n s.addChain(c);\n setStructure(s);\n}\n"
"public SerializablePredicate<OProperty> getPredicateForListProperties() {\n return (prop) -> !(Boolean) CustomAttribute.HIDDEN.getValue(prop);\n}\n"
"protected void addCaption(String caption) {\n if (caption == null || \"String_Node_Str\".equals(caption)) {\n return;\n }\n TableRegionLayout rLayout = getTableRegionLayout();\n IContent row = generateCaptionRow(tableContent.getCaption());\n rLayout.initialize(row);\n rLayout.layout();\n Ta...
"protected static void shuffleRandomizedBlocks(List<Block> blockCollection) {\n List<Integer> indices = new ArrayList<Integer>();\n for (Block b : blockCollection) indices.add(b.index);\n Collections.shuffle(indices, Question.rng);\n for (int i = 0; i < blockCollection.size(); i++) blockCollection.get(i).in...
"private Alignments.AlignmentEntry andBack(final int index, int originalIndex, final Alignments.AlignmentEntry reduced) {\n final Alignments.AlignmentEntry.Builder result = Alignments.AlignmentEntry.newBuilder(reduced);\n final int multiplicity = multiplicities.get(index);\n final int k = multiplicity - 1;\n ...
"public void changed(RuleSelection selection, PropertyDescriptor<?> desc, Object newValue) {\n modified = true;\n for (Rule rule : selection.allRules()) {\n if (newValue != null) {\n ruleTreeViewer.getTree().redraw();\n } else {\n ruleTreeViewer.update(rule, null);\n }\n...
"public void setUp() throws Exception {\n databases = getDatabases(\"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\", \"String_Node_Str\");\n defaultDatabase = databases.getDefaultDatabase();\n dataSource = defaultDatabase.getDataSource();\n cleanupTestDatabase();\n createTestDatabase();\n ...
"private String effectiveMatchingIgnorePattern(File file) {\n String relativeFilename = FilePathUtil.relativize(baseDirectory, file);\n List<String> matchingPattern = matchingIgnorePatterns(relativeFilename);\n if (matchingPattern.isEmpty()) {\n return null;\n }\n String lastMatchingPattern = matc...
"public void testCreateStoreFile_withInvalidDirectory() {\n String directory = \"String_Node_Str\";\n nearCacheConfig.getPreloaderConfig().setStoreInitialDelaySeconds(1).setStoreIntervalSeconds(1).setDirectory(directory);\n File lockFile = new File(directory, getStoreFile().getName());\n expectedException.e...
"protected void updateRecord(Data key, R record, Object value, long expiryTime, long now, boolean disableWriteThrough, int completionId, String source, String origin) {\n Data dataOldValue = null;\n Data dataValue = null;\n Object recordValue = value;\n try {\n if (expiryTime != CacheRecord.TIME_NOT_...
"protected Object findInternal(ClassDescriptor descriptor, AbstractSession session, Object primaryKey, LockModeType lockMode, Map<String, Object> properties) {\n if (primaryKey == null) {\n throw new IllegalArgumentException(ExceptionLocalization.buildMessage(\"String_Node_Str\"));\n }\n List primaryKey...
"public DeregisterImageResponseType deregister(DeregisterImageType request) throws EucalyptusCloudException {\n DeregisterImageResponseType reply = request.getReply();\n final Context ctx = Contexts.lookup();\n final String requestAccountId = ctx.getUserFullName().getAccountNumber();\n EntityTransaction tx ...
"public boolean isCallTimedOut() {\n final NodeEngineImpl nodeEngine = (NodeEngineImpl) getNodeEngine();\n if (nodeEngine.operationService.isCallTimedOut(op)) {\n cancel(new CallTimeoutException(op.getClass().getName(), op.getInvocationTime(), op.getCallTimeout()));\n return true;\n }\n return...
"public void removeUpdates(ILocationListener listener, PendingIntent intent, String packageName) {\n checkPackageName(packageName);\n final int pid = Binder.getCallingPid();\n final int uid = Binder.getCallingUid();\n synchronized (mLock) {\n Receiver receiver = checkListenerOrIntentLocked(listener, ...
"private void deployJarToDesForArchive(final ResourcesManager manager, Set<String> extRoutines) {\n if (extRoutines.isEmpty()) {\n return;\n }\n IPath tmpDir = new Path(System.getProperty(\"String_Node_Str\") + File.separatorChar + \"String_Node_Str\");\n File dirFile = tmpDir.toFile();\n for (IPa...
"public static void testCompletedCancelledStateAttributesSet(Collection<Artifact> artifacts, SkynetTransaction transaction, HashCollection<String, String> testNameToResultsMap, CountingMap<String> testNameToTimeSpentMap) {\n Date date = new Date();\n for (Artifact artifact : artifacts) {\n try {\n ...
"public void latitudeToPixelYTest() {\n for (int tileSize : TILE_SIZES) {\n for (byte zoomLevel = ZOOM_LEVEL_MIN; zoomLevel <= ZOOM_LEVEL_MAX; ++zoomLevel) {\n double pixelY = MercatorProjection.latitudeToPixelY(MercatorProjection.LATITUDE_MAX, zoomLevel, tileSize);\n Assert.assertEquals...
"protected Element elementExistsInSequence(String elementName, String refString, Sequence seq) {\n if (seq.isEmpty()) {\n return null;\n }\n List existingElements = seq.getOrderedElements();\n if (existingElements != null) {\n Iterator elementIt = existingElements.iterator();\n while (e...
"public boolean cancel() {\n cancel = true;\n if (gephiReader != null) {\n gephiReader.cancel();\n }\n return true;\n}\n"
"void setFreqAxisMode(ScreenPhysicalMapping.Type mapType, float freq_lower_bound_for_log) {\n axisFreq.setMappingType(mapType, freq_lower_bound_for_log);\n if (mapType == ScreenPhysicalMapping.Type.LOG) {\n fqGridLabel.setGridType(GridLabel.Type.FREQ_LOG);\n } else {\n fqGridLabel.setGridType(Gri...
"protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {\n boolean isMultipart = ServletFileUpload.isMultipartContent(request);\n if (isMultipart) {\n FileItemFactory factory = new DiskFileItemFactory();\n ServletFileUpload upload = new ...
"public static ConsumesOutputStream retrieveClassificationPlan(User user, String filename) throws RequestNotValidException, NotFoundException, GenericException, AuthorizationDeniedException {\n try {\n JsonFactory factory = new JsonFactory();\n ObjectMapper mapper = new ObjectMapper(factory);\n ...
"public Item findItem(String[] tokens) {\n SelectionResult<Item> selectionResult = Utils.selectFromList(items, tokens);\n if (selectionResult.size() == 0) {\n IO.writeString(\"String_Node_Str\");\n } else if (selectionResult.size() == 1 || selectionResult.getDifferentNames() == 1) {\n return sele...
"public static StreamRuntime parseInputStream(JoinInputStream joinInputStream, ExecutionPlanContext executionPlanContext, Map<String, AbstractDefinition> streamDefinitionMap, Map<String, AbstractDefinition> tableDefinitionMap, Map<String, AbstractDefinition> windowDefinitionMap, Map<String, EventTable> eventTableMap, M...
"public void initTrackerServers(List<TrackerServer> serverList) {\n serverList.add(new TrackerServer(new ServerBootstrap(), this.getName()) {\n\n protected void addSpecificHandlers(ChannelPipeline pipeline) {\n pipeline.addLast(\"String_Node_Str\", new StringEncoder());\n pipeline.addLas...
"public boolean isInUseableZone(Game game, MageObject source, GameEvent event) {\n Permanent before = ((ZoneChangeEvent) event).getTarget();\n if (before == null) {\n return false;\n }\n if (!(before instanceof PermanentToken) && !this.hasSourceObjectAbility(game, before, event)) {\n return fa...
"public void itSetsFieldNameCaseForSyntaxErrorInFor() {\n RenderResult renderResult = new Jinjava().renderForResult(\"String_Node_Str\", ImmutableMap.of());\n assertThat(renderResult.getErrors().get(0).getFieldName()).isEqualTo(\"String_Node_Str\");\n}\n"
"protected void createPart(Composite parent, String dbLiteral, final DBConnectionParameter connectionParam) {\n if (dbLiteral.trim().equals(\"String_Node_Str\")) {\n GridLayout layout = new GridLayout();\n layout.numColumns = 3;\n parent.setLayout(layout);\n Label labelJar = new Label(par...
"protected List<X> mapProviders() {\n Builder<X> builder = ImmutableList.<X>builder();\n for (ApplicationCredentials crd : credentials) {\n C configuration = Iterables.find(configurationsList, crd.getProviderId());\n builder.add(createProvider(crd, configuration));\n }\n return builder.build()...
"protected Void doInBackground(Void... params) {\n Log.d(TAG, \"String_Node_Str\");\n AccessToken accessToken = AccessToken.getCurrentAccessToken();\n if (accessToken != null && !accessToken.isExpired()) {\n firebaseAuthWithFacebook(accessToken);\n } else {\n refreshToken();\n }\n return...
"protected File getRuntimeLocaleOutputFile(String locale, String extension) {\n String path = runtimeLocaleOutputPath.replace(\"String_Node_Str\", project.getBuild().getDirectory());\n File output = new File(MavenUtils.getRuntimeLocaleOutputPath(path, project.getArtifact(), locale, extension));\n output.getPar...
"public IResultSet executeQuery() throws OdaException {\n logger.logp(java.util.logging.Level.FINE, CallStatement.class.getName(), \"String_Node_Str\", \"String_Node_Str\");\n if (this.cachedResultSet != null) {\n IResultSet ret = this.cachedResultSet;\n this.cachedResultSet = null;\n return ...
"private void renderDetailBand(GL gl, DetailBand detailBand) {\n ArrayList<Integer> contentIDs = detailBand.getContentIDs();\n int startContentID = contentIDs.get(0);\n int endContentID = contentIDs.get(contentIDs.size() - 1);\n HeatMapWrapper leftHeatMapWrapper = heatMapWrappers.get(0);\n HeatMapWrapper...
"private synchronized void closeOpenFilesAndUnlock(boolean checkpoint) throws SQLException {\n if (log != null) {\n stopWriter();\n try {\n log.close(flush);\n } catch (Throwable e) {\n traceSystem.getTrace(Trace.DATABASE).error(\"String_Node_Str\", e);\n }\n ...
"public boolean isValidExpansion(ItemStack input, ItemStack expansion) {\n if (StackHelper.isMatchingItem(EnumRedstoneChipset.RED.getStack(), expansion, true, true)) {\n return true;\n }\n for (ItemStack s : recipes.values()) {\n if (StackHelper.isMatchingItem(s, expansion, true, true)) {\n ...
"public void pop(String prefix) {\n List<String> uris = namespaceMap.get(prefix);\n if (uris != null) {\n int size = uris.size();\n if (size > 0) {\n String uri = uris.remove(size - 1);\n if (uri != null) {\n List<String> prefixes = uriToPrefixMap.get(uri);\n ...
"public void sendIsTypingToServer(int opponentId) {\n QBPrivateChat privateChat = getPrivateChatByOpponent(opponentId);\n try {\n privateChat.sendIsTypingNotification();\n } catch (XMPPException e) {\n ErrorUtils.logError(e);\n } catch (SmackException.NotConnectedException e) {\n ErrorU...
"public FutureData<Token> updateLimit(String identity, String service, Long allowance) {\n if (identity == null || identity.isEmpty()) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n if (service == null || service.isEmpty()) {\n throw new IllegalArgumentException(\"String_Node_...
"protected boolean hasTcomp0Component(final INode iNode) {\n if (iNode == null) {\n return false;\n }\n IProcess process = iNode.getProcess();\n if (process == null) {\n return false;\n }\n List<? extends INode> graphicalNodes = process.getGraphicalNodes();\n if (graphicalNodes == nul...
"private static List<MatchedArg> matchArgs(Context context, FnOverload overload, List<Type> argTypes, Map<String, Type> kwArgTypes, boolean throwOnFail) throws TypeMismatchException {\n FunctionType fnType = overload.type;\n DefaultVals<Var> defaultVals = overload.defaultVals;\n assert (!fnType.hasVarargs() ||...
"public boolean evaluate(final GraphRewrite event, final EvaluationContext context) {\n List<WindupVertexFrame> resultLocations = new ArrayList<WindupVertexFrame>();\n GraphContext graphContext = event.getGraphContext();\n GraphService<XmlFileModel> xmlResourceService = new GraphService<XmlFileModel>(graphCont...
"public void actionPerformed(ActionEvent e) {\n String cmd = e.getActionCommand();\n if (cmd.equals(MenuCreator.TEXT_ONLY)) {\n if (multAln == null) {\n System.err.println(\"String_Node_Str\");\n return;\n }\n System.out.println(\"String_Node_Str\");\n } else if (cmd....
"protected void verticalAlign() {\n Iterator iter = getChildren();\n while (iter.hasNext()) {\n AbstractArea child = (AbstractArea) iter.next();\n CSSValue vAlign = child.getVerticalAlign();\n if (IStyle.TOP_VALUE.equals(vAlign)) {\n continue;\n }\n int spacing = getC...
"private RelaxedSolution solveRelaxation(ProblemNode curNode, double incumbentScore) {\n try {\n numSolves++;\n double upperBound = -incumbentScore;\n Triple<RelaxStatus, Double, WarmStart> triple = runSimplexAlgo(cplex, upperBound, curNode.getDepth());\n RelaxStatus status = triple.get1(...
"protected Entry computeNext() {\n if (closed || (!scanner.hasNext())) {\n return endOfData();\n }\n RawPayloadTableEntry entry = scanner.next();\n if (skipFirstRow) {\n skipFirstRow = false;\n if (!scanner.hasNext()) {\n return endOfData();\n }\n entry = scanne...
"public SSAInstruction copyForSSA(int[] defs, int[] uses) {\n if (defs != null && defs.length == 0) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n if (uses != null && uses.length == 0) {\n throw new IllegalArgumentException(\"String_Node_Str\");\n }\n return new SSAPiIns...
"public boolean merge(String repoId, boolean skipConflicts) throws Exception {\n String stagingId = repoId + STAGE;\n ManagedRepositoryConfiguration repoConfig;\n ManagedRepositoryConfiguration stagingConfig;\n Configuration config = archivaConfiguration.getConfiguration();\n repoConfig = config.findMana...
"public List<SelectionDetail> getSelectionDetailsAtIndex(int xIndex) {\n List<SelectionDetail> vals = new ArrayList<SelectionDetail>();\n for (int i = 0; i < mData.getDataSetCount(); i++) {\n IDataSet<?> dataSet = mData.getDataSetByIndex(i);\n final float yVal = dataSet.getYValForXIndex(xIndex);\n ...
"public void process(T gray, GrayU8 binary) {\n refined.reset();\n ellipseDetector.process(binary);\n if (ellipseRefiner != null)\n ellipseRefiner.setImage(gray);\n intensityCheck.setImage(gray);\n List<BinaryEllipseDetectorPixel.Found> found = ellipseDetector.getFound();\n for (BinaryEllipseDe...
"protected org.eclipse.birt.data.engine.odi.IResultIterator executeOdiQuery(IEventHandler eventHandler) throws DataException {\n if (doesLoadFromCache() == true) {\n DataSourceQuery dsQuery = new DataSourceQuery(dataEngine.getSession());\n JointDataSetQuery jointQuery = (JointDataSetQuery) odiQuery;\n ...
"private boolean doProcess(ApplicationInstanceTerminatedEvent event, Applications applications) {\n if (event.getAppId() == null) {\n String errorMsg = \"String_Node_Str\";\n log.error(errorMsg);\n throw new RuntimeException(errorMsg);\n }\n String appId = event.getAppId();\n if (applic...
"public Schema schema(String table) throws BlurException, TException {\n checkTable(_cluster, table);\n resetSearchers();\n return super.schema(table);\n}\n"
"protected void logPreciseContraintViolation(ConstraintViolationException e) {\n for (ConstraintViolation constraintViolation : e.getConstraintViolations()) {\n String[] violationDescriptor = { constraintViolation.getRootBeanClass().toString(), constraintViolation.getPropertyPath().toString(), constraintViola...
"public void installComponents() {\n jLayeredPane.setOpaque(false);\n jLayeredPane.add(abilityPicker, JLayeredPane.MODAL_LAYER);\n jLayeredPane.add(DialogManager.getManager(gameId), JLayeredPane.MODAL_LAYER, 0);\n abilityPicker.setVisible(false);\n}\n"
"protected static void addRegexMatchOperation(DgEnvironmentFactory envFactory) {\n DgOperationInstance doi = new DgOperationInstance();\n doi.setName(\"String_Node_Str\");\n doi.setAnnotationName(\"String_Node_Str\");\n EParameter parm = EcoreFactory.eINSTANCE.createEParameter();\n parm.setName(\"String_...
"public void runMain(String[] args, List resultList) {\n LangUtil.throwIaxIfFalse(!LangUtil.isEmpty(args), \"String_Node_Str\");\n final ArrayList globals = new ArrayList();\n final ArrayList files = new ArrayList();\n final LinkedList argList = new LinkedList();\n argList.addAll(Arrays.asList(args));\n ...
"private boolean ifDefaultGuardValue(List<GuardValue> guards) {\n for (GuardValue guardValue : guards) {\n switch(guardValue) {\n case USE:\n case USE_IF_DEFAULT:\n break;\n case DO_NOT_USE:\n case USE_IF_NOT_DEFAULT:\n return false;\n ...
"public void insertTSLine(ActionRequest request, ActionResponse response) {\n User user = AuthUtils.getUser();\n Project project = Beans.get(ProjectRepository.class).find(new Long(request.getData().get(\"String_Node_Str\").toString()));\n Product product = Beans.get(ProductRepository.class).find(new Long(reque...
"public void onCreate() {\n super.onCreate();\n navigationItem.setTitle(R.string.settings_screen_pass);\n view = inflateRes(R.layout.controller_pass);\n container = (LinearLayout) view.findViewById(R.id.container);\n crossfadeView = (CrossfadeView) view.findViewById(R.id.crossfade);\n errors = (TextVi...
"public void printSQL(ExpressionSQLPrinter printer, SQLSelectStatement statement) {\n if (getLockMode() == ObjectBuildingQuery.LOCK) {\n if (waitTimeout == null) {\n printer.printString(printer.getSession().getPlatform().getSelectForUpdateString());\n } else {\n printer.printStrin...
"private void checkTypeVarsInferred(MarkerList markers, ICodePosition position, ITypeContext typeContext) {\n for (int i = 0; i < this.genericCount; i++) {\n ITypeVariable typeVar = this.generics[i];\n IType type = typeContext.resolveType(typeVar);\n if (type == null || type.typeTag() == IType.T...
"protected RemoteSession getSession() throws TransportException {\n if (sock != null)\n return sock;\n final int tms = getTimeout() > 0 ? getTimeout() * 1000 : 0;\n final FS fs = local == null ? FS.detect() : local.getFS();\n sock = sch.getSession(uri, getCredentialsProvider(), fs, tms);\n return ...
"public void onSessionCreateEvent(CrawlerSession crawlerSession) {\n if (!crawlerSession.isValid()) {\n return;\n }\n User user;\n while (true) {\n if ((user = userManager.allocateUser()) != null) {\n break;\n }\n CommonUtil.sleep(5000);\n }\n boolean loginSucces...
"public void map(Chunk[] chks, NewChunk[] ncs) {\n int chunkSize = chks[0].len();\n long start = chks[0].start();\n for (int c = 0; c < chks.length; c++) {\n for (int r = 0; r < chunkSize; r++) {\n ncs[c].addNum(opfn(op, chks[c].atd(r), s));\n }\n }\n}\n"
"public static byte[] getCover(String based64Value) {\n try {\n if (base64 != null) {\n return base64.decode(based64Value.getBytes(StandardCharsets.US_ASCII));\n }\n } catch (Exception e) {\n LOGGER.error(\"String_Node_Str\", e);\n }\n return null;\n}\n"
"public void handleEvent(PerformanceEvaluatorEvent event) {\n boolean previousAntialiasAllowed = antialiasAllowed;\n antialiasAllowed = event.getIndicePerformance() < PerformanceEvaluator.GOOD_PERFORMANCE_INDICE;\n if (previousAntialiasAllowed != antialiasAllowed && !drawableComposite.getBgDrawableComposite()....
"public void fundedByHasNameFunder() {\n List<Fund> funds = Collections.singletonList(FundMother.fndFundFunderKnown().build());\n when(fundRepository.findByRequestId(1L)).thenReturn(funds);\n mockTokenInfo();\n UserProfile davy = UserProfileMother.davy();\n when(profileService.getUserProfile(funds.get(0)...
"public static String getMeasumerementDataTypeOfSensorTypeInArea(String lsmMetaGraph, double longitude, double latitude, float radius, String sensorType, String measurement, String unit) {\n StringBuilder update = new StringBuilder();\n String str = (\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\"...
"public Collection<TlvDataObject> getSecInfos(SecInfoPublicity publicity, MasterFile mf) {\n OidIdentifier caOidIdentifier = new OidIdentifier(OID_id_CA);\n Collection<CardObject> caKeyCardObjects = mf.findChildren(new KeyIdentifier(), caOidIdentifier);\n ArrayList<TlvDataObject> secInfos = new ArrayList<>();\...
"public boolean isImageExists() {\n if (user == null) {\n return false;\n }\n}\n"
"IResultMetaData refreshMetaData(DataSetHandle dataSetHandle, boolean holdEvent) throws BirtException {\n IResultMetaData rsMeta = null;\n try {\n rsMeta = this.getDataSetMetaData(dataSetHandle, false);\n } catch (BirtException e1) {\n if (holdEvent || !dataSetHandle.canEdit()) {\n Com...
"public void testSimpleBatch() throws Exception {\n List<BatchPart> batch = new ArrayList<BatchPart>();\n BatchPart request = BatchQueryPart.method(GET).uri(\"String_Node_Str\").build();\n batch.add(request);\n InputStream body = EntityProvider.writeBatchRequest(batch, BOUNDARY);\n String batchRequestBod...
"protected void setup(Context context) throws IOException, InterruptedException {\n loadConfigFiles(context);\n loadTagWeightNum();\n this.dataPurifier = new DataPurifier(this.modelConfig);\n this.outputKey = new IntWritable();\n this.outputValue = new Text();\n this.tags = new HashSet<String>(modelCo...
"public void onEntityDamage(EntityDamageEvent e) {\n if (e instanceof EntityDamageByEntityEvent) {\n EntityDamageByEntityEvent event = (EntityDamageByEntityEvent) e;\n if (event.getDamager() instanceof Player && event.getEntity() instanceof Player) {\n if (((CraftPlayer) event.getDamager())....
"public void removeContentProvider(IApplicationThread caller, String name) {\n synchronized (this) {\n ContentProviderRecord cpr = (ContentProviderRecord) mProvidersByName.get(name);\n if (cpr == null) {\n if (DEBUG_PROVIDER)\n Log.v(TAG, name + \"String_Node_Str\");\n ...
"public void parseParameters() {\n clearParameters();\n returnValueDeclared = false;\n try {\n final BufferedReader in;\n if (script == null) {\n in = new BufferedReader(new FileReader(getPath()));\n } else {\n in = reader;\n in.mark(PARAM_CHAR_MAX);\n ...
"protected Integer doTaskBackground(Void... params) {\n SqlStorage<FormRecord> storage = CommCareApplication._().getUserStorage(FormRecord.class);\n Vector<Integer> recordsToRemove = storage.getIDsForValues(new String[] { FormRecord.META_STATUS }, new String[] { FormRecord.STATUS_SAVED });\n int oldrecords = r...
"private void createBundleProjectDescription(IProject project, OSGiBundleFacetInstallConfig config, IProgressMonitor monitor) throws CoreException {\n IBundleProjectService bundleProjectService = Activator.getDefault().getBundleProjectService();\n IBundleProjectDescription bundleProjectDescription = bundleProject...
"public int drRoll() {\n int dr = 0;\n Barkskin bark = buff(Barkskin.class);\n if (belongings.armor != null) {\n dr += Random.NormalIntRange(belongings.armor.DRMin(), belongings.armor.DRMax());\n if (STR() < belongings.armor.STRReq()) {\n dr -= 2 * (belongings.armor.STRReq() - STR());\...
"public void takeScreenshot(String filename, int w) {\n int h = (int) (w * getSceneCamera().viewportHeight / getSceneCamera().viewportWidth);\n FrameBuffer fbo = FrameBuffer.createFrameBuffer(Format.RGB565, w, h, false);\n fbo.begin();\n Gdx.gl.glClearColor(0, 0, 0, 1);\n Gdx.gl.glClear(GL20.GL_COLOR_BUF...
"public static void changeArtifactType(Collection<? extends Artifact> artifacts, IArtifactType artifactTypeToken) throws OseeCoreException {\n if (artifacts.isEmpty()) {\n throw new OseeArgumentException(\"String_Node_Str\");\n }\n if (newArtifactTypeToken == null) {\n throw new OseeArgumentExcep...
"private PDFRenderContext createPDFrenderContext() {\n PDFRenderContext renderContext = new PDFRenderContext();\n if (servletPath != null && servletPath.length() > 0) {\n renderContext.setBaseURL(this.contextPath + servletPath);\n } else {\n renderContext.setBaseURL(this.contextPath + IBirtConsta...
"protected void setUp() throws Exception {\n super.setUp();\n testObject = new Object[] { new Integer(1), new Integer(0), BigDecimal.valueOf(Integer.MAX_VALUE), BigDecimal.valueOf(Integer.MAX_VALUE + 1), BigDecimal.valueOf(Integer.MIN_VALUE), BigDecimal.valueOf(Integer.MIN_VALUE - 1), BigDecimal.valueOf(0l), Bool...
"public SubscriptionInfo createSubscriptionInfo(Subscriber subscriber, Locale locale, Date compareDate) {\n SubscriptionInfo si = null;\n Publisher p = subscriber.getPublisher();\n try {\n final Translator translator = Util.createPackageTranslator(PFRunController.class, locale);\n PFNotifications...
"public void remove(Object e) {\n try {\n EntityMetadata metadata = getMetadata(e.getClass());\n getEventDispatcher().fireEventListeners(metadata, e, PreRemove.class);\n EntityInterceptor interceptor = new EntityInterceptor();\n List<EntitySaveGraph> objectGraphs = interceptor.handleRelat...
"protected List<Document> loadDocuments(File file) throws GerbilException {\n String documentUriPrefix = \"String_Node_Str\" + getName() + \"String_Node_Str\";\n BufferedReader bReader = null;\n CSVReader reader = null;\n List<Document> documents = new ArrayList<Document>();\n try {\n bReader = ne...
"public LinkedBlockingQueue<String> getXmlLogs() {\n LinkedBlockingQueue<String> XmlLogs = xmlLogs;\n XmlLogs.add(\"String_Node_Str\");\n XmlLogs.add(\"String_Node_Str\");\n return XmlLogs;\n}\n"
"public void startData(IDataContent data) {\n super.startData(data);\n HyperlinkDef url = parseHyperLink(data);\n engine.addData(data, data.getComputedStyle(), url);\n}\n"
"public void onPartialResults(final Bundle partialResults) {\n if (recognitionActive) {\n final ArrayList<String> partialRecognitionResults = partialResults.getStringArrayList(SpeechRecognizer.RESULTS_RECOGNITION);\n if (partialRecognitionResults != null && !partialRecognitionResults.isEmpty()) {\n ...
"private void fillParametersFromURL(DatabaseConnection dbconn, String[] s) {\n String selection = s[0];\n int index = 1;\n if (s[index] != \"String_Node_Str\") {\n if (selection.equals(EDatabaseConnTemplate.GODBC.getDBDisplayName()) || selection.equals(EDatabaseConnTemplate.MSODBC.getDBDisplayName())) {...
"public void delete(Context context, DSpaceObject dso, String identifier) throws IdentifierException {\n String doi = DOI.formatIdentifier(identifier);\n TableRow doiRow = null;\n String oldStatus = null;\n try {\n doiRow = DatabaseManager.findByUnique(context, \"String_Node_Str\", \"String_Node_Str\...