content
stringlengths
40
137k
"public Collection<ServiceCheckRecord> lookupDetails() {\n try {\n return this.lookupService().getDetails();\n } catch (NoSuchServiceException ex) {\n LOG.error(ex, ex);\n return Lists.newArrayList();\n }\n}\n"
"Data getItem(DataList datalist, int index){\n\tif (datalist == null)\n\t\treturn null;\n\tint limitIndex = datalist.size() - emptylist.size();\n\tif (index < limitIndex)\n\t\treturn null;\n\treturn datalist.getItem(index);\n}\n"
"protected void loadSplitFiles(Result result, String... filenames) {\n result.addText(\"String_Node_Str\");\n for (String filename : filenames) {\n File file = new File(filename);\n if (!file.isFile()) {\n result.addText(String.format(\"String_Node_Str\", filename));\n continue...
"private Object getHadoopClusterRepositoryValue(HadoopClusterConnection hcConnection, String value, IMetadataTable table) {\n if (EHDFSRepositoryToComponent.DISTRIBUTION.getRepositoryValue().equals(value)) {\n return hcConnection.getDistribution();\n } else if (EHDFSRepositoryToComponent.DB_VERSION.getRepo...
"public void run() {\n IWorkbench workbench = PlatformUI.getWorkbench();\n IWorkbenchWindow window = workbench.getActiveWorkbenchWindow();\n IWorkbenchPage page = window.getActivePage();\n try {\n if (page == null) {\n throw new IllegalArgumentException();\n }\n page.openEdit...
"public Collection<Object[]> getTestScenario() {\n Collection<Object[]> tests = new ArrayList<>();\n for (Map<String, BrowserInstance> browser : executions) {\n TestScenario test = new TestScenario();\n for (String key : browser.keySet()) {\n BrowserClient browserClient = null;\n ...
"public static void performCreateFile() throws IOException {\n CreateFileDialog dialog = new CreateFileDialog(EncogWorkBench.getInstance().getMainWindow());\n dialog.setTheType(CreateFileType.MachineLearningMethod);\n if (dialog.process()) {\n String name = dialog.getFilename();\n if (name == nul...
"public void close() {\n ds.forEach(Subscription::unsubscribe);\n seeker.unbindTime();\n volume.valueProperty().unbind();\n}\n"
"public boolean hasWordAboveAutoCorrectionScoreThreshold() {\n return mHasAutoCorrectionCandidate && ((size() > 1 && !mTypedWordValid) || mTypedWordValid);\n}\n"
"public void load(Element element) throws NCLParsingException, XMLException {\n String att_name, att_var;\n att_name = NCLElementAttributes.VALUE.toString();\n if (!(att_var = element.getAttribute(att_name)).isEmpty())\n setValue(new AssValueParamType(att_var, this));\n else\n throw new NCLPar...
"public void close() throws IOException {\n try {\n SolrServer solrServer = getSolrServer();\n if (solrServer != null) {\n solrServer.shutdown();\n }\n } catch (Exception e) {\n }\n try {\n getIndexingSolrServer().shutdown();\n } catch (Exception e) {\n }\n tr...
"private Method getGetter() {\n return this.get;\n}\n"
"public YearMonthDay withField(DateTimeFieldType fieldType, int value) {\n int index = indexOfSupported(fieldType);\n if (value == getValue(index)) {\n return this;\n }\n int[] newValues = getValues();\n newValues = getField(index).set(this, index, newValues, value);\n return new YearMonthDay(t...
"private static Annotation uniqueAnnotation() {\n final int value = nextUniqueValue.getAndIncrement();\n return new Internal() {\n public int value() {\n return value;\n }\n\n public Class<? extends Annotation> annotationType() {\n return Internal.class;\n }\n ...
"public Object pullObject(final String key) throws ParseException {\n final Iterator<Object> iterator = list.iterator();\n while (iterator.hasNext()) {\n final Object object = iterator.next();\n if (object != null && !(object instanceof Element)) {\n iterator.remove();\n return...
"public static UpdateRowResponse addRow(SQLiteDatabase db, String tableName, List<RowDataRequest> rowDataRequests) {\n UpdateRowResponse updateRowResponse = new UpdateRowResponse();\n if (rowDataRequests == null || tableName == null) {\n updateRowResponse.isSuccessful = false;\n return updateRowResp...
"public Date getOrder() {\n GregorianCalendar gc = new GregorianCalendar(2013, 8, 30, 12, 0, 0);\n return gc.getTime();\n}\n"
"protected ID getConnectedID() {\n ISharedObjectContext context = getContext();\n return (context == null) ? null : context.getConnectedID();\n}\n"
"public void onEnable() {\n name = this.getDescription().getName();\n version = this.getDescription().getVersion();\n config = new Config(this);\n permissions = new Permission(this);\n Util.log.info(\"String_Node_Str\" + version + \"String_Node_Str\");\n}\n"
"public static UserFullName getInstance(final User user, final String... relativePath) {\n try {\n if ((user != null) && !Principals.isFakeIdentify(user.getUserId())) {\n if (!userIdMap.asMap().containsKey(user.getUserId())) {\n userIdMap.put(user.getUserId(), new UserFullName(user))...
"public void commandLineTest() throws Exception {\n IDLE.main(new String[] { \"String_Node_Str\", \"String_Node_Str\", TestConstants.AFNetworking_PROJECT_PATH, \"String_Node_Str\", TestConstants.TEST_RESOURCES_PATH + \"String_Node_Str\" });\n}\n"
"private boolean getMessage() {\n if (!acquireReadBuffer()) {\n return false;\n }\n try {\n buffer.limit(17);\n int read = connection.read();\n if (read == 17) {\n buffer.flip();\n byte request = buffer.get();\n if (request != HeaderConstants.OFFER_L...
"public void end() throws SAXException {\n if (element instanceof TableRow)\n if (element.getContainer() instanceof GroupElement)\n element = element.getContainer();\n String value = text.toString();\n if (value.equalsIgnoreCase(\"String_Node_Str\") || value.equalsIgnoreCase(\"String_Node_Str...
"private void pullChatMessages(int lookIntoFuture) {\n Map<String, Integer> fieldMap = new HashMap<>();\n fieldMap.put(\"String_Node_Str\", lookIntoFuture);\n fieldMap.put(\"String_Node_Str\", 25);\n int lastKnown;\n if (lookIntoFuture == 1) {\n lastKnown = globalLastKnownFutureMessageId;\n } e...
"public static Object invokeMPIMethod(String mpiRunner, String mpiBinary, Object[] values, Stream[] streams, String[] prefixes, File taskSandboxWorkingDir) throws InvokeExecutionException {\n System.out.println(\"String_Node_Str\");\n System.out.println(\"String_Node_Str\" + mpiBinary);\n System.out.println(\"...
"public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment roundEnv) {\n final ErrorReceiverImpl errorListener = new ErrorReceiverImpl(processingEnv);\n List<Reference> classes = new ArrayList<Reference>();\n filterClass(classes, roundEnv.getRootElements());\n J2SJAXBModel model = XJC....
"public Set<Database> getAvailableDatabases() throws Exception {\n if (availableDatabases.size() == 0) {\n for (DatabaseConnection conn : getAvailableConnections()) {\n availableDatabases.add(DatabaseFactory.getInstance().findCorrectDatabaseImplementation(conn));\n }\n }\n return avail...
"protected HandshakeResponse respondToIncoming(HandshakeResponse hr) {\n if (hr.isCrawler()) {\n HandshakingStat.INCOMING_CRAWLER.incrementStat();\n return HandshakeResponse.createCrawlerResponse();\n }\n if (!hr.isUltrapeer()) {\n HandshakingStat.LEAF_INCOMING_REJECT.incrementStat();\n ...
"public void beforeRun() throws Exception {\n container = getOrCreateContainer();\n shouldBackup = container.size() > 0;\n}\n"
"public void createActions(IComparisonScope scope, Comparison comparison) {\n if (menuManager.isEmpty()) {\n final IAction defaultAction = new GroupAction(defaultGroupProvider.getLabel(), structureMergeViewerGrouper, defaultGroupProvider);\n defaultAction.setChecked(true);\n menuManager.add(defa...
"private Trace createTrace(Object target, Object[] args) {\n final HttpChannel<?> channel = (HttpChannel<?>) args[0];\n final Request request = channel.getRequest();\n final String requestURI = request.getRequestURI();\n if (excludeUrlFilter.filter(requestURI)) {\n if (isTrace) {\n logger....
"public Response<Void> agentCheckFail(String checkId, String note) {\n UrlParameters noteParams = note != null ? new SingleUrlParameters(\"String_Node_Str\", note) : null;\n RawResponse rawResponse = rawClient.makePutRequest(\"String_Node_Str\" + checkId, noteParams);\n if (rawResponse.getStatusCode() == 200) ...
"protected Set doProcessXsds(final IProgressMonitor monitor, final List problems) {\n final Set results = new HashSet();\n final Collection xsdDestinations = this.builder.getXsdDestinations();\n final Iterator iter = xsdDestinations.iterator();\n Set newXsdFiles = new HashSet();\n Set destProjectRelative...
"public void WriteCommonRecord(net.minecraft.nbt.NBTTagCompound TagCompound) {\n for (int Index = 0; Index < SideClosed.length; Index++) {\n TagCompound.setBoolean(\"String_Node_Str\" + Index, SideClosed[Index]);\n }\n TagCompound.setInteger(\"String_Node_Str\", Block.blockRegistry.getIDForObject(decora...
"public void setPadding(int left, int top, int right, int bottom) {\n super.setPadding(left, top, right, bottom);\n setBasePadding(isCheckMarkAtStart());\n updatePadding();\n}\n"
"public static Credentials obtainToken(YarnConfiguration configuration, Credentials credentials) {\n if (!UserGroupInformation.isSecurityEnabled()) {\n return credentials;\n }\n try {\n YarnClient yarnClient = YarnClient.createYarnClient();\n yarnClient.init(configuration);\n yarnCl...
"private void initFilters() {\n listFilter = new GenListModuleReader();\n listFilter.setLogger(logger);\n listFilter.setInputFile(rootFile);\n listFilter.setInputDir(rootFile.resolve(\"String_Node_Str\"));\n listFilter.setPrimaryDitamap(rootFile);\n listFilter.setJob(job);\n if (profilingEnabled) {...
"public void apiStreamingTest() throws ConnectorException, StratioEngineConnectionException {\n StratioStreamingAPI stratioStreamingAPI = (StratioStreamingAPI) StratioStreamingAPIFactory.create().withServerConfig(\"String_Node_Str\", 9092, \"String_Node_Str\", 2181).init();\n waitSeconds(5);\n stratioStreaming...
"public Node cloneNode(Node node, IProcess process, Map<String, List<? extends IElementParameter>> paraMap, boolean lockByOther) {\n NodePart nodePart = new NodePart();\n IJobletProviderService service = (IJobletProviderService) GlobalServiceRegister.getDefault().getService(IJobletProviderService.class);\n boo...
"public void exec() {\n if (cc < 0)\n return;\n int i, a, b, c, o, n, cb;\n LValue rkb, rkc, nvarargs, key, val;\n LValue i0, step, idx, limit, init, table;\n boolean back, body;\n LPrototype proto;\n LClosure newClosure;\n CallInfo ci = calls[cc];\n LClosure cl = ci.closure;\n LPro...
"public String findInstanceURLVar(final String templateId, final boolean isNode) {\n final String instanceURLVarName = (isNode ? \"String_Node_Str\" : \"String_Node_Str\") + \"String_Node_Str\" + ModelUtils.makeValidNCName(templateId) + \"String_Node_Str\";\n for (final String varName : getMainVariableNames()) {\...
"protected void _writeFile(File file) throws IOException {\n try {\n Component component = _getRightComponent().getParent();\n Component parent = component.getParent();\n while ((parent != null) && !(parent instanceof Frame)) {\n component = parent;\n parent = component.get...
"private void updateReady(List<TouchEvent> touchEvents) {\n if (touchEvents.size() > 0) {\n state = GameState.Running;\n}\n"
"public void onItemClick(AdapterView<?> adapterView, View view, int position, long id) {\n ListView lv = (ListView) findViewById(R.id.activity_news_list_view);\n Cursor cursor = (Cursor) lv.getAdapter().getItem(position);\n startManagingCursor(cursor);\n String url = cursor.getString(cursor.getColumnIndex(C...
"public void createNamespace(String name) {\n ParameterNamespace root = scenarioDefinition.getMeasurementEnvironmentDefinition().getRoot();\n ParameterNamespace namespace = EnvironmentFactory.eINSTANCE.createParameterNamespace();\n namespace.setName(name);\n if (currentNamespace == null)\n root.getCh...
"public boolean apply(Game game, Ability source) {\n Player player = game.getPlayer(targetPointer.getFirst(game, source));\n if (player != null) {\n boolean paid = false;\n Cost cost = new DiscardTargetCost(new TargetCardInHand());\n if (cost.canPay(source, source.getSourceId(), player.getId(...
"public void event(UserRequest ureq, Controller source, Event event) {\n if (source == editorCtr) {\n if (event == Event.DONE_EVENT) {\n fireEvent(ureq, new FolderEvent(FolderEvent.NEW_FILE_EVENT, fileName));\n fireEvent(ureq, FolderCommand.FOLDERCOMMAND_FINISHED);\n } else if (ev...
"public void setRaw(String key, Object val) throws PropertyException {\n throw new RuntimeException(\"String_Node_Str\");\n}\n"
"public void onPlayerTick(TickEvent.ClientTickEvent event) {\n Minecraft mc = Minecraft.getMinecraft();\n if (event.side == Side.CLIENT && mc.player != null) {\n if (event.phase == TickEvent.Phase.START) {\n return;\n }\n for (EntityEquipmentSlot slot : ItemStackUtility.ARMOR_SLOTS...
"public void makeView() {\n learner.remove(detail);\n run.setEnabled(false);\n detail.unsetPanel();\n learnerPanel.setPreferredSize(new Dimension(WIDTH, HEIGHT));\n detail.setVisible(false);\n hint.setText(\"String_Node_Str\");\n isInconsistent = false;\n readThread = new ReadingOntologyThread(e...
"public int open(final ExtendedItemHandle eih) {\n if (iInstanceCount > 0) {\n return Window.CANCEL;\n }\n iInstanceCount++;\n if (ChartXTabUtil.isAxisChart(eih)) {\n DesignElementHandle hostChart = eih.getElementProperty(ChartReportItemUtil.PROPERTY_HOST_CHART);\n this.extendedHandle =...
"public int generateNextValue(final int reference) throws NoSuchValueException {\n List<Integer> candidates = computeCandidates(new Function<FieldValueGenerator, Integer>() {\n\n public Integer apply(FieldValueGenerator fieldValueGenerator) {\n try {\n return fieldValueGenerator.gene...
"public double[][] compute(RDFDataSet dataset, List<Resource> instances, List<Statement> blackList) {\n SparseVector[] featureVectors = computeFeatureVectors(dataset, instances, blackList);\n double[][] kernel = initMatrix(instances.size(), instances.size());\n computeKernelMatrix(instances, featureVectors, ke...
"public static void init() {\n GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(Items.crops, ConfigurationHandler.cropsPerCraft), \"String_Node_Str\", \"String_Node_Str\", 's', \"String_Node_Str\"));\n if (ConfigurationHandler.cropsPerCraft == 3) {\n GameRegistry.addShapelessRecipe(new ItemStack(ne...
"public void testConfigAndTruncate() throws Exception {\n StreamAdmin streamAdmin = getStreamAdmin();\n grantAndAssertSuccess(new NamespaceId(FOO_NAMESPACE), USER, ImmutableSet.of(Action.WRITE));\n Id.Stream stream = Id.Stream.from(FOO_NAMESPACE, \"String_Node_Str\");\n streamAdmin.create(stream);\n Asse...
"protected String parseIdent() {\n switch((NCLElementAttributes) getTargetAtt()) {\n case ID:\n return getTarget().getId();\n case FOCUSINDEX:\n return ((NCLDescriptorPrototype) getTarget()).getFocusIndex().parse();\n }\n return null;\n}\n"
"public static PreparedStatementCreator generatePStatCreator(QueryParam queryParam, String ipTableName) {\n NetworkQueryParam ipQueryParam = (NetworkQueryParam) queryParam;\n final NetworkInBytes network = ipQueryParam.getNetworkInBytes();\n final int hexCharSize = IpUtil.getHexCharSize(network.getIpVersion())...
"public List<KBHandle> listProperties(KnowledgeBase kb, boolean aIncludeInferred, boolean aAll) throws QueryEvaluationException {\n List<KBHandle> resultList = read(kb, (conn) -> {\n String QUERY = getPropertyListQuery(kb);\n TupleQuery tupleQuery = conn.prepareTupleQuery(QueryLanguage.SPARQL, QUERY);\...
"public CheckedListenableFuture<R> call() throws Exception {\n try {\n Request<Q, R> execute = AsyncRequest.this.execute(serviceConfig);\n return execute.getResponse();\n } catch (Exception ex) {\n AsyncRequest.this.result.setException(ex);\n LOG.error(ex);\n Logs.extreme().erro...
"private void updateNodeConfiguration(final Node node) throws Exception {\n needUpdate.put(node, true);\n if (updating.containsKey(node) && updating.get(node)) {\n return;\n }\n while (needUpdate.get(node)) {\n needUpdate.put(node, false);\n updating.put(node, true);\n ssh.runCom...
"public ItemStack computeItemStack() {\n if (Math.random() * 100.0D < percentage) {\n int dropAmount = isFixedDrops ? maxAmount : minAmount + random.nextInt(Math.abs(maxAmount - minAmount + 1));\n if (dropAmount > 0) {\n ItemStack itemStack;\n if (data == 0) {\n ite...
"public void create(IProgressMonitor monitor) throws Exception {\n super.create(monitor);\n MavenPomSynchronizer pomSync = new MavenPomSynchronizer(this.getJobProcessor().getTalendJavaProject());\n pomSync.syncRoutinesPom(true);\n getPomFile().getParent().refreshLocal(IResource.DEPTH_ONE, monitor);\n}\n"
"static QDateTime stringToQDateTime(final String dateTimeString) {\n return QDateTime.fromString(dateTimeString.replace(\"String_Node_Str\", \"String_Node_Str\"), \"String_Node_Str\");\n}\n"
"public CharSequence getFlyweightStrB() {\n throw new UnsupportedOperationException();\n}\n"
"private long sendInProcess(long lastCompletedId) throws InterruptedException {\n Set<Long> inProcessSet = inProcess.getSet();\n logger.trace(\"String_Node_Str\", inProcessSet, group.getName());\n for (Long toSend : inProcessSet) {\n if (toSend < lastCompletedId) {\n send(toSend);\n } ...
"public boolean equals(Object o) {\n if (o instanceof MultiMap) {\n return getName().equals(((MultiMap) o).getName());\n } else {\n return false;\n }\n}\n"
"public IIncomingFileTransfer receive(File localFileToSave) throws IOException {\n setOutputStream(new BufferedOutputStream(new FileOutputStream(localFileToSave)));\n setupAndScheduleJob(fileTransferJob);\n return RetrieveFileTransfer.this;\n}\n"
"public static void tearDownClass() {\n testStackIndex--;\n if (singleNodeMain != null && testStackIndex == 0) {\n singleNodeMain.shutDown();\n singleNodeMain = null;\n }\n}\n"
"private void swt_initialize(Composite parent) {\n if (cMainComposite == null || cMainComposite.isDisposed()) {\n if (parent == null || parent.isDisposed()) {\n return;\n }\n sc = new ScrolledComposite(parent, SWT.V_SCROLL);\n sc.setExpandHorizontal(true);\n sc.setExpand...
"private void startImg(SpannableStringBuilder text, Attributes attributes, WPHtml.ImageGetter img) {\n if (mContext == null)\n return;\n String src = attributes.getValue(\"String_Node_Str\");\n Bitmap resizedBitmap = null;\n try {\n resizedBitmap = ImageUtils.getWPImageSpanThumbnailFromFilePat...
"public void genericsTest() {\n String cacheName = \"String_Node_Str\";\n CacheManager cacheManager = getCacheManager();\n Cache<Identifier, Beagle> cacheGeneric = cacheManager.getCache(cacheName);\n cacheGeneric = cacheManager.<Identifier, Beagle>createCacheBuilder(cacheName).build();\n Beagle pistachio...
"public String formatValue(Object value) throws BirtException {\n if (directFormatter == null) {\n if (value instanceof java.util.Date) {\n directFormatter = new DateFormatter(pattern, this.locale, this.timeZone);\n } else if (value instanceof Number) {\n directFormatter = new Num...
"private String lookupHash(String hash) {\n String out = versionMap.get(hash);\n if (out == null) {\n out = \"String_Node_Str\";\n }\n return out;\n}\n"
"protected void applyResults(Void result, Exception backgroundException) {\n RecyclerView.Adapter adapter = createAdapterForWords(mWordsList);\n if (adapter != null) {\n mWordsRecyclerView.setAdapter(adapter);\n }\n}\n"
"public void createRecursiveCopy(SBOLDocument document, TopLevel topLevel) throws SBOLValidationException {\n if (document.getTopLevelLocalOnly(topLevel.getIdentity()) != null)\n return;\n for (URI wasDerivedFromURI : topLevel.getWasDerivedFroms()) {\n TopLevel wasDerivedFrom = getTopLevelLocalOnly(...
"public UserTO verifyToken(UserTO userTO) throws WorkflowException, NotFoundException {\n return userDataBinder.getUserTO(doExecuteAction(Constants.ACTION_VERIFY_TOKEN, userTO, Collections.singletonMap(Constants.TOKEN, (Object) userTO.getToken())), userWorkflow);\n}\n"
"public synchronized void internalShutdown() {\n msgLog.logMessage(\"String_Node_Str\" + machineId + \"String_Node_Str\" + this + \"String_Node_Str\" + masterServer, true);\n if (this.updatePuller != null) {\n msgLog.logMessage(\"String_Node_Str\", true);\n this.updatePuller.shutdown();\n msg...
"protected boolean contains(BitmapContainer bitmapContainer) {\n final int cardinality = getCardinality();\n if (bitmapContainer.getCardinality() != -1 && bitmapContainer.getCardinality() > cardinality) {\n return false;\n }\n final int runCount = numberOfRuns();\n short ib = 0, ir = 0;\n while...
"public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {\n if (((position + 1) == mTemplate.getScene(0).getClips().size()) && positionOffset == 0 & positionOffsetPixels == 0) {\n mDragAtEnd++;\n if (mDragAtEnd > 5) {\n AlertDialog.Builder builder = new Aler...
"public void activateFor(Node node) {\n if (!replicas.contains(node)) {\n active = true;\n else\n replicas.add(node);\n}\n"
"public boolean equals(Object o) {\n if (o instanceof ChannelInfo) {\n ChannelInfo other = (ChannelInfo) o;\n if (this.channelId != null) {\n if (this.channelId.equals(other.channelId))\n return true;\n } else if (this.channelName != null && this.channelNumber != null) ...
"public void put(final String key, final Object value) {\n p.put(safeKey(key), value == null ? null : value.toString());\n}\n"
"public BinaryRatingDao<CommentRatingEntity> getCommentRatingDao() {\n if (commentRatingDao == null) {\n commentRatingDao = new SqlCommentRatingDao();\n }\n return commentRatingDao;\n}\n"
"public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) {\n renderer.getTableCellRendererComponent(table, value, isSelected, hasFocus, row, column);\n setForeground(renderer.getForeground());\n setBackground(renderer.getBackground()...
"public void testExample() throws ParsingException {\n Debugger debugger = new MockDebugger();\n RewardProvider provider = new RewardProvider();\n provider.register(new RewardExperience());\n Configuration test = ConfigurationTest.createConfig(\"String_Node_Str\" + \"String_Node_Str\" + \"String_Node_Str\",...
"private String checkFileType(File f) {\n if (f.getPath().endsWith(\"String_Node_Str\"))\n return \"String_Node_Str\";\n if (f.getPath().endsWith(\"String_Node_Str\") || (f.getPath().endsWith(\"String_Node_Str\"))) {\n try {\n FileReader in = new FileReader(f);\n BufferedReader...
"public org.hl7.fhir.dstu2.model.OperationDefinition convertOperationDefinition(org.hl7.fhir.dstu3.model.OperationDefinition src) throws FHIRException {\n if (src == null || src.isEmpty())\n return null;\n org.hl7.fhir.dstu2.model.OperationDefinition tgt = new org.hl7.fhir.dstu2.model.OperationDefinition()...
"public void setDescriptorProvider(IDescriptorProvider provider) {\n super.setDescriptorProvider(provider);\n if (provider instanceof MapDescriptorProvider)\n this.mapProvider = (MapDescriptorProvider) provider;\n}\n"
"public boolean containsObject(String tableName, String columnName, String[] selectionArgs, String sortOrder, String[] projection) {\n Logger.log(\"String_Node_Str\", LogType.DATABASE);\n String selection = columnName + \"String_Node_Str\";\n Cursor cursor = getDatabase().query(tableName, projection, selection...
"protected ExecuteResult doWork(ExecutableContext context) throws ExecuteException {\n final CubeInstance cube = cubeManager.getCube(getCubeName());\n final CubeSegment segment = cube.getSegmentById(getSegmentId());\n String sourceRecordsSize = jobService.getJobInfo(getCreateFlatTableStepId()).get(ExecutableCo...
"protected APIResponse.CODE doInBackground(String... params) {\n if (params.length != 2)\n throw new IllegalArgumentException(\"String_Node_Str\");\n teamKey = params[0];\n eventKey = params[1];\n APIResponse<ArrayList<Match>> matchResponse;\n Match nextMatch = null, lastMatch = null;\n try {\n...
"public void setWorkingDir(String workingDir) {\n this.workingDir = Util.fixEmpty(workingDir);\n}\n"
"public void customizeDocumentCommand(IDocument doc, DocumentCommand docCommand) {\n try {\n if (docCommand.text.length() > 1 && docCommand.text.compareTo(\"String_Node_Str\") != 0) {\n return;\n }\n char beforeLastChar = ' ';\n char firstCommandChar = (docCommand.text.length()...
"public void contactClicked(ContactListEvent evt) {\n if (evt.getSourceContact().equals(this)) {\n List<SourceContact> contacts = new ArrayList<SourceContact>(queryResults);\n int newCount = shownResultsCount + maxResultCount;\n int resultSize = contacts.size();\n int maxCount = (resultSi...
"protected void saveReloadResult() {\n RepositoryNode recursiveFind = RepositoryNodeHelper.recursiveFind(oldDataProvider);\n Item item = recursiveFind.getObject().getProperty().getItem();\n Project currentProject = ProjectManager.getInstance().getCurrentProject();\n try {\n ProxyRepositoryFactory.get...
"private ModelElement findMatchedModelElement(EObject parent, EObject similarElement) {\n if (parent instanceof TdDataProvider) {\n if (similarElement instanceof TdSchema) {\n if (selectedOjbect instanceof TdCatalog) {\n List<TdSchema> schemas = CatalogHelper.getSchemas((TdCatalog) s...
"private static Object getDatabaseValue(DatabaseConnection connection, String value) {\n String databaseType = connection.getDatabaseType();\n if (value.equals(\"String_Node_Str\")) {\n String typeByProduct = getStandardDbTypeFromConnection(databaseType);\n if (databaseType.equals(EDatabaseTypeName....
"public boolean apply(TreeNode input) {\n return input != null && JFaceUtil.isFiltered(getViewer(), input, input.getParent());\n}\n"
"private boolean doUpdateHostPassword(final long hostId) {\n if (!_agentMgr.isAgentAttached(hostId)) {\n return false;\n }\n DetailVO nv = _hostDetailsDao.findDetail(hostId, ApiConstants.USERNAME);\n final String username = nv.getValue();\n nv = _hostDetailsDao.findDetail(hostId, ApiConstants.PASS...
"public void subscribe(ObservableEmitter e) throws Exception {\n for (Object parentClass : ACTIONS_CACHE.keySet()) {\n for (Method method : ACTIONS_CACHE.get(parentClass)) {\n if (action.getType().equals(method.getAnnotation(Action.class).actionType())) {\n HashMap<String, Object> ma...