idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,652,370 | private void updateItemData(TableItem item, DataTransferPipe pipe) {<NEW_LINE>if (isInvalidDataTransferNode(pipe.getProducer())) {<NEW_LINE><MASK><NEW_LINE>item.setText(0, DTUIMessages.stream_consumer_page_settings_item_text_none);<NEW_LINE>} else {<NEW_LINE>item.setImage(0, DBeaverIcons.getImage(getProducerProcessor()... | item.setImage(0, null); |
456,558 | private PlaylistContainerResource enumeratePlaylists(String userId) throws IOException, SpotifyWebApiException {<NEW_LINE>List<MusicPlaylist> <MASK><NEW_LINE>int offset = 0;<NEW_LINE>Paging<PlaylistSimplified> playlists;<NEW_LINE>do {<NEW_LINE>int finalOffset = offset;<NEW_LINE>monitor.debug(() -> format("Fetching play... | results = new ArrayList<>(); |
882,379 | public static String formatLogMessage(final int indent, final String message, final Object... arguments) {<NEW_LINE>final StringBuilder logMessage = new StringBuilder();<NEW_LINE>final StringBuilder[] formattedArguments = indentAndToString(indent + 1, arguments);<NEW_LINE>final String[] messageParts = message.split("\\... | .append(formattedArguments[messagePartIndex]); |
1,718,293 | private BAttachedFunction createResourceFunction(BLangFunction funcNode, BInvokableSymbol funcSymbol, BInvokableType funcType) {<NEW_LINE>BLangResourceFunction resourceFunction = (BLangResourceFunction) funcNode;<NEW_LINE>Name accessor = names.fromIdNode(resourceFunction.methodName);<NEW_LINE>List<Name> resourcePath = ... | pathParamSymbols, restPathParamSym, funcNode.pos); |
723,573 | public synchronized byte[] exportCollection() {<NEW_LINE>// returns null if the collection is empty<NEW_LINE>// experimental; supervise CPU load<NEW_LINE>sort();<NEW_LINE>// uniq();<NEW_LINE>// trim();<NEW_LINE>// on case the collection is sorted<NEW_LINE>assert this.sortBound == this.chunkcount;<NEW_LINE>assert size()... | (System.currentTimeMillis())); |
649,592 | public ObjectTypeKey unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ObjectTypeKey objectTypeKey = new ObjectTypeKey();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = context.getCurrentToken();<NEW_... | String currentParentElement = context.getCurrentParentElement(); |
591,549 | public static Figure create(String title, String xTitle, double[] xData, String yTitle, double[] yData) {<NEW_LINE>Preconditions.checkArgument(xData.length != 0, "x Data array is empty");<NEW_LINE>Preconditions.checkArgument(yData.length != 0, "x Data array is empty");<NEW_LINE>if (xData.length != yData.length) {<NEW_L... | name("y = x").build(); |
1,549,224 | public RestartRequirement onApply(UserPrefs rPrefs) {<NEW_LINE>RestartRequirement restartRequirement = super.onApply(rPrefs);<NEW_LINE>if (relaunchRequired_)<NEW_LINE>restartRequirement.setUiReloadRequired(true);<NEW_LINE>String themeName = flatTheme_.getValue();<NEW_LINE>if (!StringUtil.equals(themeName, userPrefs_.gl... | (theme_.getValue())); |
220,950 | private Answer executeRequest(UpdateBcfRouterCommand cmd, int numRetries) {<NEW_LINE>RouterData routerData = new RouterData(cmd.getTenantId());<NEW_LINE>List<AclData> acls = new ArrayList<AclData>();<NEW_LINE>acls.addAll(cmd.getAcls());<NEW_LINE>routerData.getRouter().getAcls().addAll(acls);<NEW_LINE>routerData.getRout... | cmd.getTenantId() + " router updated but topology sync required."); |
889,478 | public void saveAction(final WorkflowAction action) throws DotDataException, AlreadyExistException {<NEW_LINE>boolean isNew = true;<NEW_LINE>if (UtilMethods.isSet(action.getId())) {<NEW_LINE>isNew = !this.existsAction(action.getId());<NEW_LINE>} else {<NEW_LINE>action.setId(UUIDGenerator.generateUuid());<NEW_LINE>}<NEW... | (action.getShowOn())); |
42,388 | private static void quatToEuler(Quat4d quat, Tuple3d euler) {<NEW_LINE>double heading;<NEW_LINE>double attitude;<NEW_LINE>double bank;<NEW_LINE>double test = quat.x * quat.y + quat.z * quat.w;<NEW_LINE>if (test > 0.499) {<NEW_LINE>// singularity at north pole<NEW_LINE>heading = 2 * Math.atan2(quat.x, quat.w);<NEW_LINE>... | = quat.x * quat.x; |
1,541,891 | private void readKeyFromFile(Uri uri) {<NEW_LINE>PubkeyBean pubkey = new PubkeyBean();<NEW_LINE>// find the exact file selected<NEW_LINE>pubkey.setNickname(uri.getLastPathSegment());<NEW_LINE>byte[] keyData;<NEW_LINE>try {<NEW_LINE>ContentResolver resolver = getContentResolver();<NEW_LINE>keyData = getBytesFromInputStr... | getPublic().getEncoded()); |
1,691,263 | private void tokenizeComment() {<NEW_LINE>// all we need to do is find the end of the comment.<NEW_LINE>Matcher matcher = this.syntax.getRegexCommentClose().matcher(this.source);<NEW_LINE>boolean <MASK><NEW_LINE>if (!match) {<NEW_LINE>throw new ParserException(null, "Unclosed comment.", this.source.getLineNumber(), thi... | match = matcher.find(0); |
1,144,209 | private void go() {<NEW_LINE>try {<NEW_LINE>System.out.println("----------Map Source and Sink ----------------");<NEW_LINE>// insert sequence 0..9 into map as (0,0) , (1,1) .... ( 9,9)<NEW_LINE>prepareSampleInput(jet, MAP_SOURCE);<NEW_LINE>// execute the pipeline<NEW_LINE>jet.newJob(mapSourceAndSink(MAP_SOURCE, MAP_SIN... | System.out.println("----------------------------------------------"); |
1,624,833 | public final BeanDefinition parse(Element element, ParserContext parserContext) {<NEW_LINE>AbstractBeanDefinition definition = parseInternal(element, parserContext);<NEW_LINE>if (definition != null && !parserContext.isNested()) {<NEW_LINE>try {<NEW_LINE>String id = resolveId(element, definition, parserContext);<NEW_LIN... | .toString()), element); |
349,783 | public FlowInfo analyseCode(BlockScope currentScope, FlowContext flowContext, FlowInfo flowInfo) {<NEW_LINE>// here requires to generate a sequence of finally blocks invocations depending corresponding<NEW_LINE>// to each of the traversed try statements, so that execution will terminate properly.<NEW_LINE>// lookup the... | 2]), 0, subCount); |
840,251 | protected void terminatePlanItemInstance(PlanItemInstanceEntity planItemInstance, CommandContext commandContext) {<NEW_LINE>String currentPlanItemInstanceState = planItemInstance.getState();<NEW_LINE>Date currentTime = cmmnEngineConfiguration.getClock().getCurrentTime();<NEW_LINE>planItemInstance.setEndedTime(currentTi... | getId(), ScopeTypes.CMMN); |
104,924 | public byte[] synthesizeSpeech(String text, GoogleTTSVoice voice, String codec) {<NEW_LINE>String[] format = getFormatForCodec(codec);<NEW_LINE>String fileNameInCache = getUniqueFilenameForText(text, voice.getTechnicalName());<NEW_LINE>File audioFileInCache = new File(cacheFolder, fileNameInCache + "." + format[1]);<NE... | audio, voice.getTechnicalName()); |
1,717,712 | public void endVisit(Block node) {<NEW_LINE>ASTNode parent = node.getParent();<NEW_LINE>List<Statement> statements = node.statements();<NEW_LINE>if (parent.getLength() == 0)<NEW_LINE>// this is a fake block created by parsing in statements mode<NEW_LINE>return;<NEW_LINE>String oneLineOption;<NEW_LINE>if (parent instanc... | tm.firstTokenAfter(node, TokenNamewhile); |
1,161,150 | public static void assertPropsPerRow(EventBean[] actual, String[] propertyNames, Object[][] expected, String streamName) {<NEW_LINE>if (compareArraySize(expected, actual)) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>for (int i = 0; i < expected.length; i++) {<NEW_LINE>Object[] propertiesThisRow = expected[i];<NEW_LINE>Scope... | toString(), value, eventProp); |
544,098 | private static void install() {<NEW_LINE>// don't install directory chooser if standard chooser is desired<NEW_LINE>if (isStandardChooserForced()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>final UIDefaults uid = UIManager.getDefaults();<NEW_LINE>originalImpl = (Class<?>) uid.getUIClass(KEY);<NEW_LINE>Class<MASK><NEW_LINE>... | <?> impl = DelegatingChooserUI.class; |
1,462,249 | public GetDevicePositionResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>GetDevicePositionResult getDevicePositionResult = new GetDevicePositionResult();<NEW_LINE>AwsJsonReader reader = context.getReader();<NEW_LINE>reader.beginObject();<NEW_LINE>while (reader.hasNext()) {<NEW_LINE>String ... | )).unmarshall(context)); |
1,105,089 | public void doTest() {<NEW_LINE>checkState(!<MASK><NEW_LINE>checkState(!run, "doTest should only be called once");<NEW_LINE>this.run = true;<NEW_LINE>Result result = compile();<NEW_LINE>for (Diagnostic<? extends JavaFileObject> diagnostic : diagnosticHelper.getDiagnostics()) {<NEW_LINE>if (diagnostic.getCode().contains... | sources.isEmpty(), "No source files to compile"); |
42,661 | private void loadNode1194() {<NEW_LINE>PropertyTypeNode node = new PropertyTypeNode(this.context, Identifiers.CubeItemType_YAxisDefinition, new QualifiedName(0, "YAxisDefinition"), new LocalizedText("en", "YAxisDefinition"), LocalizedText.NULL_VALUE, UInteger.valueOf(0), UInteger.valueOf(0), new DataValue(Variant.NULL_... | .expanded(), true)); |
283,845 | private void generate15Client(boolean isJsr109Platform, ProgressHandle handle) throws IOException {<NEW_LINE>// !PW Get client support from project (from first page of wizard)<NEW_LINE>JAXWSClientSupport jaxWsClientSupport = null;<NEW_LINE>if (project != null) {<NEW_LINE>jaxWsClientSupport = JAXWSClientSupport.getJaxWs... | wiz.getProperty(ClientWizardProperties.WSDL_PACKAGE_NAME); |
1,363,404 | public static void main(String[] args) {<NEW_LINE>final VcrServer vcrServer;<NEW_LINE>int exitCode = 0;<NEW_LINE>try {<NEW_LINE>InvocationOptions options = new InvocationOptions(args);<NEW_LINE>Properties properties = Utils.loadProps(options.serverPropsFilePath);<NEW_LINE><MASK><NEW_LINE>ClusterMapConfig clusterMapConf... | VerifiableProperties verifiableProperties = new VerifiableProperties(properties); |
1,850,668 | protected void processElement(IJavaElement element) throws JavaModelException {<NEW_LINE>ICompilationUnit cu = (ICompilationUnit) element;<NEW_LINE>// keep track of the import statements - if all are removed, delete<NEW_LINE>// the import container (and report it in the delta)<NEW_LINE>int numberOfImports = cu.getImpor... | (cu)).getElements(); |
776,614 | private static void addGstreamerPathsToEnv() {<NEW_LINE>if (System.getProperty("jna.nosys") == null) {<NEW_LINE>System.setProperty("jna.nosys", "true");<NEW_LINE>}<NEW_LINE>Path gstreamerPath = InstalledFileLocator.getDefault().locate("gstreamer", Installer.class.getPackage().getName(), false).toPath();<NEW_LINE>if (gs... | toString(), "lib", "gstreamer-1.0"); |
1,245,092 | public void importCity(ActionRequest request, ActionResponse response) {<NEW_LINE>try {<NEW_LINE>List<ImportHistory> importHistoryList = null;<NEW_LINE>Map<String, Object> importCityMap = null;<NEW_LINE>MetaFile errorFile = null;<NEW_LINE>String typeSelect = (String) request.getContext().get("typeSelect");<NEW_LINE>if ... | TraceBackService.trace(response, e); |
130,369 | private Object jpql(Business business, Statement statement, Runtime runtime) throws Exception {<NEW_LINE>Object data = null;<NEW_LINE>Class<? extends JpaObject> cls = this.clazz(business, statement);<NEW_LINE>EntityManager em;<NEW_LINE>if (StringUtils.equalsIgnoreCase(statement.getEntityCategory(), Statement.ENTITYCATE... | createQuery(statement.getData()); |
373,999 | private void callClassModuleBuilder(String name, boolean is_singleton) {<NEW_LINE><MASK><NEW_LINE>int i = mg.newLocal(Types.RUBY_VALUE_TYPE);<NEW_LINE>mg.storeLocal(i);<NEW_LINE>String uniqueName = NameFactory.createClassnameForClassModuleBuilder(extra_, script_name_, name);<NEW_LINE>Type builder = Type.getType("L" + u... | MethodGenerator mg = cg_.getMethodGenerator(); |
42,341 | public Pair<Boolean, String> updateSource(SourceRequest sourceRequest) {<NEW_LINE>final String path = HTTP_PATH + "/source/update";<NEW_LINE>final String url = formatUrl(path);<NEW_LINE>final String storage = GsonUtil.toJson(sourceRequest);<NEW_LINE>final RequestBody storageBody = RequestBody.create(MediaType.parse("ap... | responseBody = InlongParser.parseResponse(body); |
1,791,293 | public void batchSizeLimited() {<NEW_LINE>ServiceBusMessage firstMessage = new ServiceBusMessage(BinaryData.fromBytes("message-1".getBytes(UTF_8)));<NEW_LINE>firstMessage.getApplicationProperties().put("telemetry", "latency");<NEW_LINE>ServiceBusMessage secondMessage = new ServiceBusMessage(BinaryData.fromBytes("messag... | ).put("telemetry", "cpu-temperature"); |
1,144,321 | private void create(Properties ctx, TransformerHandler document, PO entity, boolean includeParents, List<String> excludedParentList, boolean isFromParent) throws SAXException {<NEW_LINE>int tableId = 0;<NEW_LINE>String tableName = null;<NEW_LINE>int recordId = 0;<NEW_LINE>if (entity != null) {<NEW_LINE>tableId = entity... | ctx, tableName, recordId, null); |
200,700 | public void config(final OServerNetworkListener iListener, final OServer iServer, final Socket iSocket, final OContextConfiguration iConfiguration) throws IOException {<NEW_LINE>configuration = iConfiguration;<NEW_LINE>final boolean installDefaultCommands = iConfiguration.getValueAsBoolean(OGlobalConfiguration.NETWORK_... | iConfiguration.getValueAsBoolean(OGlobalConfiguration.NETWORK_HTTP_JSON_RESPONSE_ERROR); |
796,813 | final GetProvisionedConcurrencyConfigResult executeGetProvisionedConcurrencyConfig(GetProvisionedConcurrencyConfigRequest getProvisionedConcurrencyConfigRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getProvisionedConcurrencyConfigRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = ... | addHandlerContext(HandlerContextKey.CLIENT_ENDPOINT, endpoint); |
676,641 | private final char[] optimizedCurrentTokenSource4(char[] source, int startPosition) {<NEW_LINE>char[] src = source;<NEW_LINE>int start = startPosition;<NEW_LINE>char c0, c1 = src[start + 1], c2, c3 = src[start + 3];<NEW_LINE>int hash = (((c0 = src[start]) << 6) + (c2 = src[start + 2])) % TABLE_SIZE;<NEW_LINE>char[][] t... | [] charArray = table[i]; |
809,683 | public void run(Collection<ITestRunListener> listeners) throws TimeoutException, AdbCommandRejectedException, ShellCommandUnresponsiveException, IOException {<NEW_LINE>final String runCaseCommandStr = String.format("uiautomator runtest %1$s %2$s", jarFile, buildArgsCommand());<NEW_LINE>Log.i(LOG_TAG, String.format("Run... | = new InstrumentationResultParser(mRunName, listeners); |
159,966 | public void computeFullName(EbicsCertificate entity) {<NEW_LINE>StringBuilder fullName = new StringBuilder();<NEW_LINE>Option item = MetaStore.getSelectionItem("bankpayment.ebics.certificate.type.select", entity.getTypeSelect());<NEW_LINE>if (item != null) {<NEW_LINE>fullName.append(I18n.get(item.getTitle()));<NEW_LINE... | setFullName(fullName.toString()); |
1,004,156 | public /* (non-Javadoc)<NEW_LINE>* @see com.kkalice.adempiere.migrate.DBEngineInterface#sqlCreateSchema(com.kkalice.adempiere.migrate.Parameters, com.kkalice.adempiere.migrate.Logger, com.kkalice.adempiere.migrate.DBEngine, int, java.lang.String, java.lang.String, java.lang.String, java.lang.String)<NEW_LINE>*/<NEW_LIN... | ("GRANT DBA TO ").append(schemaName); |
1,032,612 | public Optional<ColumnOrderByItemSegment> convertToSQLSegment(final SqlNode sqlNode) {<NEW_LINE>if (!(sqlNode instanceof SqlIdentifier)) {<NEW_LINE>return Optional.empty();<NEW_LINE>}<NEW_LINE>SqlIdentifier sqlIdentifier = (SqlIdentifier) sqlNode;<NEW_LINE>if (sqlIdentifier.names.size() > 1) {<NEW_LINE>SqlIdentifier co... | (column.toString())); |
1,409,026 | private List<Pair<String, ResourceType>> populatePrefixes(Configuration configuration) {<NEW_LINE>List<Pair<String, ResourceType>> prefixes = new ArrayList<>();<NEW_LINE>prefixes.add(Pair.of(configuration.getSqlMigrationPrefix(), ResourceType.MIGRATION));<NEW_LINE>prefixes.add(Pair.of(configuration.getRepeatableSqlMigr... | (), ResourceType.CALLBACK)); |
1,534,157 | protected void work() {<NEW_LINE>Map<TailFile, List<Map>> serverlogs = null;<NEW_LINE>try {<NEW_LINE>TailFile tf = (TailFile) this.get("tfevent");<NEW_LINE>this.setCurrenttfref((CopyOfProcessOfLogagent<MASK><NEW_LINE>// tfref = ((TaildirLogComponent) this.get("tfref"));<NEW_LINE>serverlogs = this.getCurrenttfref().tail... | ) this.get("tfref")); |
1,537,830 | public Map<String, Histogram> readChronicle() {<NEW_LINE>try (final ChronicleQueue q = createQueue()) {<NEW_LINE>final ExcerptTailer tailer = q.createTailer();<NEW_LINE>final WireParselet parselet = parselet();<NEW_LINE>final FieldNumberParselet fieldNumberParselet = (methodId, wire) -> parselet.accept(Long.toString(me... | .set(new VanillaMessageHistory()); |
254,748 | private void handleEntityData(byte[] data, int size, long totalSize, long contentLength) throws IOException {<NEW_LINE>if (responseOut == null) {<NEW_LINE>if (responseFile != null) {<NEW_LINE>createFileResponseData(false);<NEW_LINE>} else if (contentLength > maxBufferSize) {<NEW_LINE>createFileResponseData(false);<NEW_... | callbackData.put("totalSize", totalSize); |
1,356,590 | public ValueHolder<V> replace(K key, V value) throws StoreAccessException {<NEW_LINE>@SuppressWarnings("unchecked")<NEW_LINE>V[] old = (V<MASK><NEW_LINE>BiFunction<K, V, V> remappingFunction = (k, inCache) -> {<NEW_LINE>inCache = loadFromLoaderWriter(key, inCache);<NEW_LINE>if (inCache == null) {<NEW_LINE>return null;<... | []) new Object[1]; |
1,379,444 | public void delete(Set<String> declarationNames) throws InvokerException {<NEW_LINE>Map<Identifier, GlobalVariable> queuedGlobalVars = new HashMap<>();<NEW_LINE>Map<Identifier, String> queuedModuleDclns = new HashMap<>();<NEW_LINE>for (String declarationName : declarationNames) {<NEW_LINE>Identifier identifier = new Id... | ).forEach(moduleDclns::remove); |
706,163 | public void write(final char[] cbuf, final int off, final int len) throws IOException {<NEW_LINE>if (thread == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (thread.isInterrupted()) {<NEW_LINE>content = null;<NEW_LINE>thread = null;<NEW_LINE>throw new InterruptedIOException();<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>conte... | throw new IOException("Bad location in TextAreaWriter::write", e1); |
1,609,669 | public void onTestIgnored(@Nonnull final TestIgnoredEvent testIgnoredEvent) {<NEW_LINE>addToInvokeLater(() -> {<NEW_LINE>final String testName = testIgnoredEvent.getName();<NEW_LINE>if (testName == null) {<NEW_LINE>logProblem("TestIgnored event: no name");<NEW_LINE>}<NEW_LINE>String ignoreComment = testIgnoredEvent.get... | + "}. " + cannotFindFullTestNameMsg(fullTestName)); |
1,565,359 | public static String calculatePathMD5(final Path path) throws IOException {<NEW_LINE>// This doesn't have as nice error messages as FileUtils, but it's close.<NEW_LINE>String fname = path.toUri().toString();<NEW_LINE>if (!Files.exists(path)) {<NEW_LINE>throw new FileNotFoundException("File '" + fname + "' does not exis... | is = Files.newInputStream(path); |
784,763 | public void run(RegressionEnvironment env) {<NEW_LINE>EPStage stageA = env.stageService().getStage("ST");<NEW_LINE>env.compileDeploy("@name('s0') select * from SupportBean");<NEW_LINE>String deploymentId = env.deploymentId("s0");<NEW_LINE>stageIt(env, "ST", deploymentId);<NEW_LINE>try {<NEW_LINE>stageA.destroy();<NEW_L... | ) -> stageA.getEventService()); |
1,195,115 | public io.kubernetes.client.proto.V1beta1Apiextensions.JSONSchemaPropsOrArray buildPartial() {<NEW_LINE>io.kubernetes.client.proto.V1beta1Apiextensions.JSONSchemaPropsOrArray result = new io.kubernetes.client.<MASK><NEW_LINE>int from_bitField0_ = bitField0_;<NEW_LINE>int to_bitField0_ = 0;<NEW_LINE>if (((from_bitField0... | proto.V1beta1Apiextensions.JSONSchemaPropsOrArray(this); |
449,506 | private void runAssertion_A_Bstar(RegressionEnvironment env, AtomicInteger milestone, boolean allMatches) {<NEW_LINE>sendTimer(env, 0);<NEW_LINE>String[] fields = "a,b0,b1,b2".split(",");<NEW_LINE>String text = "@name('s0') select * from SupportRecogBean#keepall " + "match_recognize (" + " measures A.theString as a, B[... | sendEventBean(new SupportRecogBean("X1")); |
1,548,892 | public void deleteV2LoggingLevel(DeleteV2LoggingLevelRequest deleteV2LoggingLevelRequest) throws AmazonServiceException, AmazonClientException {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteV2LoggingLevelRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequest... | awsRequestMetrics.endEvent(Field.RequestMarshallTime); |
1,681,394 | public void testRxObservableInvoker_postReceiveTimeout(Map<String, String> param, StringBuilder ret) {<NEW_LINE>long timeout = messageTimeout;<NEW_LINE>if (isZOS()) {<NEW_LINE>timeout = zTimeout;<NEW_LINE>}<NEW_LINE>String serverIP = param.get("serverIP");<NEW_LINE>String serverPort = param.get("serverPort");<NEW_LINE>... | ":" + serverPort + "/jaxrs21bookstore/JAXRS21bookstore2/post/" + SLEEP); |
329,506 | private static boolean check_ARB_vertex_attrib_64bit(FunctionProvider provider, PointerBuffer caps, Set<String> ext) {<NEW_LINE>if (!ext.contains("GL_ARB_vertex_attrib_64bit")) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>int flag0 = ext.contains("GL_EXT_direct_state_access") ? 0 : Integer.MIN_VALUE;<NEW_LINE>return (c... | ) || reportMissing("GL", "GL_ARB_vertex_attrib_64bit"); |
614,448 | public void select(int mode) {<NEW_LINE>if (searchPoint == null) {<NEW_LINE>Toast.makeText(getActivity(), R.string.please_select_address, Toast.LENGTH_SHORT).show();<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>AddressInformation ai = new AddressInformation();<NEW_LINE>PointDescription pointDescription = ai.getHistoryName();<N... | build2StreetIntersection(getActivity(), osmandSettings); |
1,134,928 | public static void createProblem(@Nonnull PsiElement elt, @Nonnull HighlightInfo info, TextRange range, @javax.annotation.Nullable ProblemGroup problemGroup, @Nonnull InspectionManager manager, @Nonnull ProblemDescriptionsProcessor problemDescriptionsProcessor, @Nonnull GlobalInspectionContext globalContext) {<NEW_LINE... | = new ArrayList<LocalQuickFix>(); |
1,597,586 | private void drawStrokes(Canvas canvas) {<NEW_LINE>if (mReversed) {<NEW_LINE>canvas.translate(mBounds.width(), 0);<NEW_LINE>canvas.scale(-1, 1);<NEW_LINE>}<NEW_LINE>float prevValue = 0f;<NEW_LINE><MASK><NEW_LINE>if (mMirrorMode)<NEW_LINE>boundsWidth /= 2;<NEW_LINE>int width = boundsWidth + mSeparatorLength + mSectionsC... | int boundsWidth = mBounds.width(); |
1,294,844 | public static INDArray predict(String filepath) throws IOException {<NEW_LINE>File file = new File(filepath);<NEW_LINE>if (!file.exists()) {<NEW_LINE>file = new File(filepath);<NEW_LINE>}<NEW_LINE>BufferedImage img = ImageIO.read(file);<NEW_LINE>double[] data = new double[28 * 28];<NEW_LINE>for (int i = 0; i < 28; i++)... | int r = color.getRed(); |
1,188,931 | private Mono<PagedResponse<SecurityPartnerProviderInner>> listByResourceGroupSinglePageAsync(String resourceGroupName, Context context) {<NEW_LINE>if (this.client.getEndpoint() == null) {<NEW_LINE>return Mono.error(new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));<NEW... | .nextLink(), null)); |
1,190,962 | public void tableChanged(TableModelEvent evt) {<NEW_LINE>// NOI18N<NEW_LINE>if (debug)<NEW_LINE>log("tableChanged");<NEW_LINE>RequestData rd = monitorData.getRequestData();<NEW_LINE>// The query panel depends on the value of the<NEW_LINE>// method attribute.<NEW_LINE>String method = rd.getAttributeValue(EditPanel.METHO... | requestTable.getValueAt(0, 1); |
38,009 | /*<NEW_LINE>* Computes the paths of projects and jars that the hierarchy on the given type could contain.<NEW_LINE>* This is a super set of the project and jar paths once the hierarchy is computed.<NEW_LINE>*/<NEW_LINE>private IPath[] computeProjectsAndJars(IType type) throws JavaModelException {<NEW_LINE>HashSet set =... | add(pkgFragmentRoot.getPath()); |
627,582 | public static FindServiceStatisticalDataResponse unmarshall(FindServiceStatisticalDataResponse findServiceStatisticalDataResponse, UnmarshallerContext _ctx) {<NEW_LINE>findServiceStatisticalDataResponse.setRequestId(_ctx.stringValue("FindServiceStatisticalDataResponse.RequestId"));<NEW_LINE>findServiceStatisticalDataRe... | ("FindServiceStatisticalDataResponse.Data.MonitorStatisticData[" + i + "].MinRt")); |
611,398 | private // WebSphere:feature=wasJmsServer,type=Topic,name=*<NEW_LINE>void displayJMSMBeans(MBeanServerConnection localEngine) throws IOException {<NEW_LINE>System.out.println("JMS MBeans [ " + getTest() + " ]");<NEW_LINE>// List all; do not filter the results<NEW_LINE>// throws IOException<NEW_LINE>Set<ObjectInstance> ... | String mbeanPrintString = mbean.toString(); |
299,698 | private void addPolicies(AbstractServiceFactoryBean factory, Server server, Class<?> cls) {<NEW_LINE>List<Policy> list = CastUtils.cast((List<?>) server.getEndpoint().getEndpointInfo().getInterface<MASK><NEW_LINE>if (list != null) {<NEW_LINE>addPolicies(factory, server.getEndpoint(), cls, list, Policy.Placement.BINDING... | ().removeProperty(EXTRA_POLICIES)); |
24,109 | protected StateMachineContext<S, E> buildStateMachineContext(StateMachine<S, E> stateMachine) {<NEW_LINE>ExtendedState extendedState = new DefaultExtendedState();<NEW_LINE>extendedState.getVariables().putAll(stateMachine.getExtendedState().getVariables());<NEW_LINE>ArrayList<StateMachineContext<S, E>> childs = new Arra... | >) stateMachine).getHistoryState(); |
729,145 | final GetManagedPrefixListAssociationsResult executeGetManagedPrefixListAssociations(GetManagedPrefixListAssociationsRequest getManagedPrefixListAssociationsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getManagedPrefixListAssociationsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetri... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
372,197 | private static // of a Pinned sketch before compressing it. Hence the name Hybrid.<NEW_LINE>void compressHybridFlavor(final CompressedState target, final CpcSketch source) {<NEW_LINE>final <MASK><NEW_LINE>final PairTable srcPairTable = source.pairTable;<NEW_LINE>final int srcNumPairs = srcPairTable.getNumPairs();<NEW_L... | int srcK = 1 << source.lgK; |
1,214,423 | public boolean apply(Game game, Ability source) {<NEW_LINE>Player player = game.getPlayer(source.getControllerId());<NEW_LINE>if (player == null) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>TargetPermanent target = new TargetPermanent(0, 1, StaticFilters.FILTER_CONTROLLED_ANOTHER_CREATURE, true);<NEW_LINE>player.choos... | getPermanent(target.getFirstTarget()); |
1,584,958 | final GetWorkUnitsResult executeGetWorkUnits(GetWorkUnitsRequest getWorkUnitsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getWorkUnitsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExec... | HandlerContextKey.ENDPOINT_OVERRIDDEN, isEndpointOverridden()); |
1,537,076 | public Node visit(String methodName, MethodDeclaration n) {<NEW_LINE>switch(methodName) {<NEW_LINE>case "createBundleURL":<NEW_LINE>// In RN 0.54 this method is overloaded; skip the convenience version<NEW_LINE>NodeList<Parameter> params = n.getParameters();<NEW_LINE>if (params.size() == 2 && params.get(0).getNameAsStr... | ).remove(Modifier.STATIC); |
1,604,318 | protected // Opting for console command, as -data-write-register-values is buggy<NEW_LINE>String encode(String threadPart, String framePart) {<NEW_LINE>StringBuilder b = new StringBuilder();<NEW_LINE>b.append("-interpreter-exec");<NEW_LINE>b.append(threadPart);<NEW_LINE>b.append(framePart);<NEW_LINE>b.append(" console ... | append(value.toString()); |
672,419 | protected void download() throws SubscriptionException {<NEW_LINE>log("Downloading");<NEW_LINE>Map map = JSONUtils.decodeJSON(subs.getJSON());<NEW_LINE>Long engine_id = (Long) map.get("engine_id");<NEW_LINE>String search_term = (String) map.get("search_term");<NEW_LINE>String networks = (<MASK><NEW_LINE>Map filters = (... | String) map.get("networks"); |
797,271 | private static void addBody(HttpURLConnection connection, File file, boolean requiresBody) throws IOException {<NEW_LINE>if (requiresBody) {<NEW_LINE>String filename = file.getName();<NEW_LINE>String formName = "file";<NEW_LINE>InputStream stream = new FileInputStream(file);<NEW_LINE>connection.setDoInput(true);<NEW_LI... | + "--\r\n").getBytes()); |
1,383,173 | private Hashtable generateDependencies(Constructor[] constructors, Method[] methods, Field[] fields) {<NEW_LINE>String x, y;<NEW_LINE>Hashtable classRef = new Hashtable();<NEW_LINE>for (int i = 0; i < fields.length; i++) {<NEW_LINE>x = ClassTypeAlgorithm.TypeName(fields[i].getType().getName(), classRef);<NEW_LINE>}<NEW... | ).getName(), classRef); |
493,305 | protected void removeDefaultClusters() {<NEW_LINE>listener.onMessage("\nWARN: Exported database does not support manual index separation." + " Manual index cluster will be dropped.");<NEW_LINE>// In v4 new cluster for manual indexes has been implemented. To keep database consistent we<NEW_LINE>// should shift back all ... | database.dropCluster(OStorage.CLUSTER_DEFAULT_NAME); |
151,279 | public void run(ReturnValueCompletion<Boolean> completion) {<NEW_LINE>try {<NEW_LINE>if (!forceRun && !isNeedRun()) {<NEW_LINE>completion.success(false);<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>int port = new URI(restf.getBaseUrl()).getPort();<NEW_LINE>putArgument("pip_url", String.format("http://%s:%d/zstack/static/pypi/... | == null ? playBookName : playBookPath)); |
1,811,012 | protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3) {<NEW_LINE>GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);<NEW_LINE>bindGuiTexture();<NEW_LINE>drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);<NEW_LINE>RenderUtil.renderGuiTank(getTileEntity().inputTank, guiLeft + RECTANGLE_TANK.x,... | guiTop + 28, 39, 56); |
185,483 | private Challenge dnsChallenge(final Authorization auth, final Integer wait) throws FrameworkException {<NEW_LINE>final Dns01Challenge challenge = auth.findChallenge(Dns01Challenge.TYPE);<NEW_LINE>if (challenge == null) {<NEW_LINE>error("No " + Dns01Challenge.TYPE + " challenge found, aborting.");<NEW_LINE>}<NEW_LINE>f... | waitForSeconds + " seconds, create a TXT record in your DNS for " + domain + " with the following data:"); |
1,468,386 | public static FileInfo parseFilename(String filename) throws ParseException {<NEW_LINE>if (filename == null) {<NEW_LINE><MASK><NEW_LINE>}<NEW_LINE>final String ext = ".json";<NEW_LINE>if (!filename.endsWith(ext)) {<NEW_LINE>throwBadFormat(filename);<NEW_LINE>}<NEW_LINE>filename = filename.substring(0, filename.length()... | throw new ParseException("The filename must not be null", 0); |
1,107,361 | public DenseVector rightMultiply(SGDVector input) {<NEW_LINE>if (input.size() == dim1) {<NEW_LINE>double[<MASK><NEW_LINE>if (input instanceof DenseVector) {<NEW_LINE>// If it's dense we can use loops<NEW_LINE>for (int i = 0; i < dim1; i++) {<NEW_LINE>double curValue = input.get(i);<NEW_LINE>for (int j = 0; j < dim2; j+... | ] output = new double[dim2]; |
538,800 | protected Object doInvoke(Object... args) throws Exception {<NEW_LINE>try {<NEW_LINE>return getBridgedMethod().<MASK><NEW_LINE>} catch (IllegalArgumentException ex) {<NEW_LINE>assertTargetBean(getBridgedMethod(), getBean(), args);<NEW_LINE>String text = (ex.getMessage() != null ? ex.getMessage() : "Illegal argument");<... | invoke(getBean(), args); |
474,695 | final GetIpamAddressHistoryResult executeGetIpamAddressHistory(GetIpamAddressHistoryRequest getIpamAddressHistoryRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getIpamAddressHistoryRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
948,580 | private final void consumeNonPersistentMessages(java.util.ArrayList consumeList) {<NEW_LINE>if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())<NEW_LINE>SibTr.entry(tc, "consumeNonPersistentMessages", consumeList);<NEW_LINE>// use a local transaction to consume all these messages<NEW_LINE>LocalTransaction ... | msgItem = consumerDispatcher.getMessageByValue(value); |
509,911 | public ReadableVectorMatch match(final ReadableVectorMatch mask) {<NEW_LINE>final IndexedInts[] vector = selector.getRowVector();<NEW_LINE>final int[] selection = match.getSelection();<NEW_LINE>int numRows = 0;<NEW_LINE>for (int i = 0; i < mask.getSelectionSize(); i++) {<NEW_LINE>final int rowNum = mask.getSelection()[... | matches = matchingIds.get(id); |
550,495 | final ModifyVpcAttributeResult executeModifyVpcAttribute(ModifyVpcAttributeRequest modifyVpcAttributeRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(modifyVpcAttributeRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetri... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "ModifyVpcAttribute"); |
1,633,994 | public void rgbToGreyKernelSmall() {<NEW_LINE>final int size = 256;<NEW_LINE>byte[] rgbBytes = new byte[size];<NEW_LINE>int[] greyInts = new int[size];<NEW_LINE>int[<MASK><NEW_LINE>Random r = new Random();<NEW_LINE>IntStream.range(0, rgbBytes.length).forEach(i -> {<NEW_LINE>rgbBytes[i] = (byte) -10;<NEW_LINE>});<NEW_LI... | ] seq = new int[size]; |
1,189,383 | // Task: parser string with text and show all indexes of all words<NEW_LINE>public static void main(String[] args) {<NEW_LINE>String INPUT_TEXT = "Hello World! Hello All! Hi World!";<NEW_LINE>// Parse text to words and index<NEW_LINE>List<String> words = Arrays.asList(INPUT_TEXT.split(" "));<NEW_LINE>// Create Multimap... | println(multiMap.keySet()); |
973,900 | private void deleteRecords(int AD_Client_ID, int AD_Org_ID, int S_Resource_ID, int M_Warehouse_ID) throws SQLException {<NEW_LINE>// Delete MRP records (Orders (SO,PO), Forecasts, Material Requisitions, Distribution Order):<NEW_LINE>{<NEW_LINE>List<Object> params = new ArrayList<Object>();<NEW_LINE>params.add(AD_Client... | executeUpdate("DELETE FROM PP_MRP WHERE " + whereClause, params); |
760,870 | private FormulaNode parseExplicitVariable() {<NEW_LINE>if (!p.eat('$')) {<NEW_LINE>throw new FormulaException(UNEXPECTED_TOKEN, '$');<NEW_LINE>}<NEW_LINE>// might be var with {} around it<NEW_LINE>final boolean hasParen = p.eat('{');<NEW_LINE>final int posOpening = p.pos() - 1;<NEW_LINE>// first variable name char MUST... | value = vars.call(parsed); |
1,224,406 | public void process() {<NEW_LINE>try {<NEW_LINE>final InputStream istream = this.getClass().getResourceAsStream("/iris.csv");<NEW_LINE>if (istream == null) {<NEW_LINE>System.out.println("Cannot access data set, make sure the resources are available.");<NEW_LINE>System.exit(1);<NEW_LINE>}<NEW_LINE>final DataSet ds = Dat... | 0, 4, 4, 2); |
1,787,489 | public GetAccessPreviewResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>GetAccessPreviewResult getAccessPreviewResult = new GetAccessPreviewResult();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_... | int originalDepth = context.getCurrentDepth(); |
1,008,503 | public static WsdlTestSuite cloneToAnotherProject(WsdlTestSuite testSuite, String targetProjectName, String name, boolean move, String description) {<NEW_LINE>WorkspaceImpl workspace = testSuite.getProject().getWorkspace();<NEW_LINE>WsdlProject targetProject = (WsdlProject) workspace.getProjectByName(targetProjectName)... | >) iface, true, true); |
1,629,624 | public static JsonRequestBPartnerUpsertItem mapHospitalToUpsertRequest(@NonNull final Hospital hospital, @Nullable final String orgCode) {<NEW_LINE>final String hospitalExternalIdentifier = formatExternalId(hospital.getId());<NEW_LINE>final JsonRequestBPartner jsonRequestBPartner = new JsonRequestBPartner();<NEW_LINE>j... | final JsonAlbertaBPartner albertaBPartner = new JsonAlbertaBPartner(); |
813,046 | public static void deletePath(String path, BrokerDesc brokerDesc) throws UserException {<NEW_LINE>TNetworkAddress address = getAddress(brokerDesc);<NEW_LINE>TFileBrokerService.Client client = borrowClient(address);<NEW_LINE>boolean failed = true;<NEW_LINE>try {<NEW_LINE>TBrokerDeletePathRequest tDeletePathRequest = new... | returnClient(client, address, failed); |
618,266 | private void updateWithCluster(ManagerService service, MySqlUpdateStatement update, ManagerWritableTable managerTable, LinkedHashMap<String, String> values, PacketResult packetResult) {<NEW_LINE>// cluster-lock<NEW_LINE>DistributeLock distributeLock;<NEW_LINE>ClusterHelper clusterHelper = ClusterHelper.getInstance(Clus... | ), ClusterMetaUtil.getConfChangeLockPath()); |
559,324 | protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {<NEW_LINE>String method = request.getParameter("testMethod");<NEW_LINE>System.out.println(">>> BEGIN: " + method);<NEW_LINE>System.out.println("Request URL: " + request.getRequestURL() + '?' + request.ge... | getClass().getName()); |
840,545 | protected JRBaseFiller createBandSubfiller(final PartPrintOutput output) throws JRException {<NEW_LINE>BandReportFillerParent bandParent = new PartBandParent(output);<NEW_LINE>JRBaseFiller bandFiller;<NEW_LINE>JasperReport jasperReport = getReport();<NEW_LINE>switch(jasperReport.getPrintOrderValue()) {<NEW_LINE>case HO... | getJasperReportsContext(), jasperReportSource, bandParent); |
1,414,818 | public void load(SerializedField metadata, DrillBuf buffer) {<NEW_LINE>List<SerializedField> children = metadata.getChildList();<NEW_LINE>SerializedField offsetField = children.get(0);<NEW_LINE><MASK><NEW_LINE>int bufOffset = offsetField.getBufferLength();<NEW_LINE>for (int i = 1; i < children.size(); i++) {<NEW_LINE>S... | offsets.load(offsetField, buffer); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.