idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,703,750 | private void visitFunction(Node n) {<NEW_LINE>if (NodeUtil.isEs6Constructor(n)) {<NEW_LINE>// These will be checked via the CLASS node.<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>FunctionType functionType = JSType.toMaybeFunctionType(n.getJSType());<NEW_LINE>if (functionType.isConstructor()) {<NEW_LINE>checkConstructor(n, fu... | JSType returnType = functionType.getReturnType(); |
1,451,021 | public void resize() {<NEW_LINE>if (((m_initialMovieHeight == -1 || m_initialMovieWidth == -1) && !m_isAudioOnly) || m_textureView == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Handler handler = new <MASK><NEW_LINE>handler.post(new Runnable() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void run() {<NEW_LINE>View c... | Handler(Looper.getMainLooper()); |
239,487 | static VisitsForWeek boundContributedDays(VisitsForWeek visits, int maxContributedDays) {<NEW_LINE>Map<String, Set<DayOfWeek>> boundedVisitorDays = new HashMap<>();<NEW_LINE>List<Visit> allVisits = new ArrayList<>();<NEW_LINE>VisitsForWeek boundedVisits = new VisitsForWeek();<NEW_LINE>// Add all visits to a list in ord... | visitorDays = new HashSet<>(); |
835,266 | protected void configure() {<NEW_LINE>bind(AddressServiceStockImpl.class);<NEW_LINE>bind(StockRulesService.class).to(StockRulesServiceImpl.class);<NEW_LINE>bind(InventoryRepository.class).to(InventoryManagementRepository.class);<NEW_LINE>bind(StockMoveRepository.class<MASK><NEW_LINE>bind(StockLocationLineService.class)... | ).to(StockMoveManagementRepository.class); |
912,503 | private void parseZone3(String text, boolean multipleInfo) {<NEW_LINE>String value = text.trim();<NEW_LINE>String valueLowerCase = value.toLowerCase();<NEW_LINE>if (valueLowerCase.startsWith(KEY1_HEX_VOLUME) || valueLowerCase.startsWith(KEY2_HEX_VOLUME)) {<NEW_LINE>value = extractNumber(value, valueLowerCase.startsWith... | RotelCommand cmd = source.getZone3Command(); |
216,660 | private void createSimpleRoutingParameterButton(MapActivity mapActivity, final LocalRoutingParameter parameter, LinearLayout optionsContainer) {<NEW_LINE><MASK><NEW_LINE>RoutingHelper routingHelper = app.getRoutingHelper();<NEW_LINE>final int colorActive = ContextCompat.getColor(app, ColorUtilities.getActiveColorId(nig... | OsmandApplication app = mapActivity.getMyApplication(); |
858,629 | public String replace(String templateStr) {<NEW_LINE>if (templateStr == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>StringBuilder result = new StringBuilder();<NEW_LINE>int position = 0;<NEW_LINE>int prefixPosition;<NEW_LINE>while ((prefixPosition = templateStr.indexOf(parameterPrefix, position)) >= 0) {<NEW_LINE... | = suffixPosition + parameterSuffix.length(); |
855,239 | public PublicDnsNamespaceProperties unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>PublicDnsNamespaceProperties publicDnsNamespaceProperties = new PublicDnsNamespaceProperties();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth =... | int originalDepth = context.getCurrentDepth(); |
968,926 | public void scheduleConnect() {<NEW_LINE>ApplicationManager.getApplication().executeOnPooledThread(() -> {<NEW_LINE>// Poll, waiting for "flutter run" to give us a websocket.<NEW_LINE>// Don't use a timeout - the user can cancel manually the operation.<NEW_LINE><MASK><NEW_LINE>while (url == null) {<NEW_LINE>if (getSess... | String url = myConnector.getWebSocketUrl(); |
284,869 | final ReplicationGroup executeDeleteReplicationGroup(DeleteReplicationGroupRequest deleteReplicationGroupRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteReplicationGroupRequest);<NEW_LINE><MASK><NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTime);<NEW_LINE>Request<DeleteR... | AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); |
1,553,864 | private void configureIncrementalCompilation(ScalaCompileSpec spec) {<NEW_LINE>IncrementalCompileOptions incrementalOptions = scalaCompileOptions.getIncrementalOptions();<NEW_LINE>File analysisFile = incrementalOptions.getAnalysisFile().getAsFile().get();<NEW_LINE>File classpathBackupDir = incrementalOptions.getClassfi... | LOGGER.debug("scala-incremental Published code: {}", publishedCode); |
1,038,147 | // GEN-LAST:event_browseLicenceButtonActionPerformed<NEW_LINE>private void browseLibraryButtonActionPerformed(java.awt.event.ActionEvent evt) {<NEW_LINE>// GEN-FIRST:event_browseLibraryButtonActionPerformed<NEW_LINE>JFileChooser chooser = new JFileChooser(ModuleUISettings.getDefault().getLastChosenLibraryLocation());<N... | chooser.setFileSelectionMode(JFileChooser.FILES_ONLY); |
1,752,905 | // invokes all methods starting with "test"<NEW_LINE>public void run() {<NEW_LINE>Util.TRACE_ENTRY();<NEW_LINE>String className = this.getClass().getCanonicalName();<NEW_LINE>String methodName = "";<NEW_LINE>String testToRun = System.getProperty("fat.test.method.name", "");<NEW_LINE>Util.TRACE("fat.test.method.name=" +... | "FAT0001E: Client setup failed." + Util.LS, e); |
868,626 | public void doLayout() {<NEW_LINE>if (!topDragComp.isVisible())<NEW_LINE>return;<NEW_LINE>int x = 0;<NEW_LINE>int y = 0;<NEW_LINE>int width = resizeComp.getWidth();<NEW_LINE>int height = resizeComp.getHeight();<NEW_LINE>if (width == 0 || height == 0)<NEW_LINE>return;<NEW_LINE>Insets resizeInsets = getResizeInsets();<NE... | leftThickness + cornerDelta, rightThickness + cornerDelta); |
494,184 | void updateEventList() {<NEW_LINE>String[] producerEvents = producerTool.getToolEventNames();<NEW_LINE>String[] consumedEvents = consumerTool.getConsumedToolEventNames();<NEW_LINE>List<String> <MASK><NEW_LINE>List<String> cList = Arrays.asList(consumedEvents);<NEW_LINE>ArrayList<String> producerList = new ArrayList<>(p... | pList = Arrays.asList(producerEvents); |
636,454 | public void sort(FacesContext context, DataTable table) {<NEW_LINE>Object value = table.getValue();<NEW_LINE>if (value == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>List<<MASK><NEW_LINE>Locale locale = table.resolveDataLocale();<NEW_LINE>String var = table.getVar();<NEW_LINE>Collator collator = Collator.getInstance(l... | ?> list = resolveList(value); |
798,126 | public AssessmentReportsDestination unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>AssessmentReportsDestination assessmentReportsDestination = new AssessmentReportsDestination();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentPar... | class).unmarshall(context)); |
903,651 | private static CrashlyticsReport.Session.Application parseApp(@NonNull JsonReader jsonReader) throws IOException {<NEW_LINE>final CrashlyticsReport.Session.Application.Builder builder = CrashlyticsReport.Session.Application.builder();<NEW_LINE>jsonReader.beginObject();<NEW_LINE>while (jsonReader.hasNext()) {<NEW_LINE>S... | setInstallationUuid(jsonReader.nextString()); |
1,295,182 | public void menuAboutToShow(IMenuManager manager) {<NEW_LINE>manager.add(new Action(Messages.MenuExportChartData) {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void run() {<NEW_LINE>TimelineChartCSVExporter exporter = new TimelineChartCSVExporter(chart);<NEW_LINE>exporter.addDiscontinousSeries(Messages.PerformanceChar... | .add(new Separator()); |
238,107 | protected String doIt() throws Exception {<NEW_LINE>MClientInfo clientInfo = MClientInfo.get(getCtx(), getAD_Client_ID());<NEW_LINE>int AD_Tree_ID = clientInfo.getAD_Tree_Menu_ID();<NEW_LINE>MTree thisTree = new MTree(getCtx(), AD_Tree_ID, true, true, null, get_TrxName());<NEW_LINE>MTreeNode node;<NEW_LINE>if (menuId >... | getRoot().findNode(menuId); |
576,728 | private void updateCheckpoint(AtomicLong checkPoint, LongObjectHashMap<CountedBitSet> bitSetMap) {<NEW_LINE>assert Thread.holdsLock(this);<NEW_LINE>assert getBitSetForSeqNo(bitSetMap, checkPoint.get() + 1).get(seqNoToBitSetOffset(checkPoint.get() + 1)) : "updateCheckpoint is called but the bit following the checkpoint ... | removed = bitSetMap.remove(bitSetKey); |
87,119 | private int decodePacket() {<NEW_LINE>// check the endianes of the computer.<NEW_LINE>final boolean bigEndian = ByteOrder.nativeOrder() == ByteOrder.BIG_ENDIAN;<NEW_LINE>if (block.synthesis(packet) == 0) {<NEW_LINE>dspState.synthesis_blockin(block);<NEW_LINE>}<NEW_LINE>// **pcm is a multichannel float vector. In stere... | localPcm = this.pcm[0]; |
797,946 | static void c_2_2() throws Exception {<NEW_LINE>BatchOperator<?> ratings = Chap24.getSourceRatings();<NEW_LINE>BatchOperator<?> items = Chap24.getSourceItems();<NEW_LINE>BatchOperator left_ratings = ratings.filter("user_id<3 AND item_id<4").select("user_id, item_id, rating");<NEW_LINE>BatchOperator right_movies = items... | left_ratings, right_movies).print(); |
771,876 | public void RestartMaster(String deviceId) {<NEW_LINE>Reader reader = null;<NEW_LINE>logger.debug("Restart master device id '{}'", deviceId);<NEW_LINE>try {<NEW_LINE>String url = API_URL + "device/restart" + "?authToken=" + this.authToken + "&id=" + deviceId;<NEW_LINE>HttpURLConnection httpURLConnection;<NEW_LINE>httpU... | = new InputStreamReader(inputStream, "UTF-8"); |
341,122 | private static byte[] ntlm2SessionResponse(final byte[] ntlmHash, final byte[] challenge, final byte[] clientChallenge) throws NtlmEngineException {<NEW_LINE>try {<NEW_LINE>// Look up MD5 algorithm (was necessary on jdk 1.4.2)<NEW_LINE>// This used to be needed, but java 1.5.0_07 includes the MD5<NEW_LINE>// algorithm ... | e.getMessage(), e); |
1,764,989 | public static <ENTITY> List<FieldPredicate<?>> andPredicates(FilterAction<ENTITY> action) {<NEW_LINE>requireNonNull(action);<NEW_LINE>final List<FieldPredicate<?>> andPredicateBuilders = new ArrayList<>();<NEW_LINE>final Predicate<? super ENTITY> predicate = action.getPredicate();<NEW_LINE>final Optional<FieldPredicate... | cast(predicate, FieldPredicate.class); |
457,528 | final RemoveRegionResult executeRemoveRegion(RemoveRegionRequest removeRegionRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(removeRegionRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExec... | invoke(request, responseHandler, executionContext); |
1,129,573 | public static void writePublisherStats(StatsOutputStream statsStream, PublisherStatsImpl stats) {<NEW_LINE>statsStream.startObject();<NEW_LINE>statsStream.writePair("msgRateIn", stats.msgRateIn);<NEW_LINE>statsStream.writePair("msgThroughputIn", stats.msgThroughputIn);<NEW_LINE>statsStream.writePair("averageMsgSize", s... | "producerName", stats.getProducerName()); |
819,243 | protected void readJson(JsonObject json, DeckCardLists deckList) {<NEW_LINE>JsonObject data = JsonUtil.getAsObject(json, "data");<NEW_LINE>if (data == null) {<NEW_LINE>sbMessage.append("Could not find data in json").append("'\n");<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>// info<NEW_LINE>String deckSet = JsonUtil.getAsStri... | JsonUtil.getAsString(data, "name"); |
1,528,806 | private static WorkspacePathResolver computeWorkspacePathResolver(Project project, BlazeContext context) {<NEW_LINE>BlazeProjectData projectData = BlazeProjectDataManager.getInstance(project).getBlazeProjectData();<NEW_LINE>if (projectData != null) {<NEW_LINE>return projectData.getWorkspacePathResolver();<NEW_LINE>}<NE... | vcsHandler.createSyncHandler(project, workspaceRoot); |
958,007 | private <T> List<T> doFind(RedisOperationChain criteria, long offset, int rows, String keyspace, Class<T> type) {<NEW_LINE>if (criteria == null || (CollectionUtils.isEmpty(criteria.getOrSismember()) && CollectionUtils.isEmpty(criteria.getSismember())) && criteria.getNear() == null) {<NEW_LINE>return getAdapter().getAll... | RedisData(entry.getValue()); |
1,454,631 | public static void main(String[] args) {<NEW_LINE>// idx 0 1 2 3 4 5 6 7 8 9 10, no index 0!<NEW_LINE>// ft = {-,0,0,0,0,0,0,0, 0,0,0}<NEW_LINE><MASK><NEW_LINE>// ft = {-,0,1,0,1,0,0,0, 1,0,0}, idx 2,4,8 => +1<NEW_LINE>ft.update(2, 1);<NEW_LINE>// ft = {-,0,1,0,2,0,0,0, 2,0,0}, idx 4,8 => +1<NEW_LINE>ft.update(4, 1)... | FenwickTree ft = new FenwickTree(10); |
576,561 | private static void dumpMethodAnnotations(PrintStream out, J9ROMMethodPointer romMethod) throws CorruptDataException {<NEW_LINE>U32Pointer methodAnnotationData = ROMHelp.getMethodAnnotationsDataFromROMMethod(romMethod);<NEW_LINE>U32Pointer parametersAnnotationData = ROMHelp.getParameterAnnotationsDataFromROMMethod(romM... | length = methodTypeAnnotations.at(0); |
45,431 | public boolean find(final Path file, final ListProgressListener listener) throws BackgroundException {<NEW_LINE>if (file.isRoot()) {<NEW_LINE>return true;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>if (containerService.isContainer(file)) {<NEW_LINE>try {<NEW_LINE>return session.getClient().isBucketAccessible(containerService.g... | attributes.find(file, listener); |
1,793,610 | InitialSearchPhase.ArraySearchPhaseResults<SearchPhaseResult> newSearchPhaseResults(SearchRequest request, int numShards) {<NEW_LINE><MASK><NEW_LINE>boolean isScrollRequest = request.scroll() != null;<NEW_LINE>final boolean hasAggs = source != null && source.aggregations() != null;<NEW_LINE>final boolean hasTopDocs = s... | SearchSourceBuilder source = request.source(); |
1,701,223 | private void executeImmediateValueMem(Instruction instruction, int source, int destination) {<NEW_LINE>// Source is [x]<NEW_LINE>ip++;<NEW_LINE>int sourceValue = memory.get(memory.get(ip));<NEW_LINE>if (destination == 0) {<NEW_LINE>// Single operand<NEW_LINE>ip++;<NEW_LINE>instruction.execute(memory, memory.get(ip - 1)... | registerSet, destination, sourceValue, status); |
504,695 | private Executable storeValue() {<NEW_LINE>return connection -> {<NEW_LINE>int maxColumnSize = table.getMaxColumnSize();<NEW_LINE>if (maxColumnSize == 0) {<NEW_LINE>return false;<NEW_LINE>}<NEW_LINE>Integer tableID = query(tableID());<NEW_LINE>List<Object[]> rows = table.getRows();<NEW_LINE>Integer oldRowCount <MASK><N... | = query(currentRowCount(tableID)); |
792,703 | protected ResolveResult[] resolveInner(boolean incompleteCode, PsiFile containingFile) {<NEW_LINE>File containingDirectory = ((BuildFile) containingFile).getFile().getParentFile();<NEW_LINE>if (containingDirectory == null) {<NEW_LINE>return ResolveResult.EMPTY_ARRAY;<NEW_LINE>}<NEW_LINE>List<String> includes = resolveL... | results.toArray(ResolveResult.EMPTY_ARRAY); |
1,502,362 | public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {<NEW_LINE>getSerializedSize();<NEW_LINE>if (((bitField0_ & 0x00000001) == 0x00000001)) {<NEW_LINE>output.writeUInt32(1, version_);<NEW_LINE>}<NEW_LINE>if (((bitField0_ & 0x00000002) == 0x00000002)) {<NEW_LINE><MASK><NEW_LINE>}... | output.writeFixed64(2, uuidTime_); |
1,425,407 | public boolean value(E e) {<NEW_LINE>boolean sep = condition.value(e);<NEW_LINE>int st0 = st;<NEW_LINE>st = st0 < 0 && sep ? -2 : st0 > 0 && !sep ? 2 : sep ? -1 : 1;<NEW_LINE>boolean result;<NEW_LINE>switch(mode) {<NEW_LINE>case AFTER:<NEW_LINE>result = st != -2 && (st != 1 || st0 == 0);<NEW_LINE>break;<NEW_LINE>case B... | || st0 <= 0 && st < 0; |
875,964 | public ServiceResponse serviceImpl(Query call, HttpServletResponse response, Authorization rights, final JsonObjectWithDefault permissions) throws APIException {<NEW_LINE>SkillQuery skillQuery = SkillQuery.getParser().<MASK><NEW_LINE>String model_name = skillQuery.getModel();<NEW_LINE>String group_name = skillQuery.get... | parse(call).requireOrThrow(); |
1,201,240 | /* (non-Javadoc)<NEW_LINE>* @see fr.opensagres.xdocreport.service.rest.XDocReportService#processReport(fr.opensagres.xdocreport.document.domain.ReportAndDataRepresentation)<NEW_LINE>*/<NEW_LINE>@POST<NEW_LINE>@Path("/processReport")<NEW_LINE>@Consumes(MediaType.APPLICATION_JSON)<NEW_LINE>@Produces(MediaType.WILDCARD)<N... | via(wsOptions.getVia()); |
922,350 | @Produces("application/json")<NEW_LINE>public Response findAll(@QueryParam("scopeId") String id, @QueryParam("name") String name, @QueryParam("first") Integer firstResult, @QueryParam("max") Integer maxResult) {<NEW_LINE>this.auth.realm().requireViewAuthorization();<NEW_LINE>Map<Scope.FilterOption, String[]> search = n... | ())).build(); |
615,098 | public BigInteger decryptBlock(CramerShoupCiphertext input) throws CramerShoupCiphertextException {<NEW_LINE>BigInteger result = null;<NEW_LINE>if (key.isPrivate() && !this.forEncryption && key instanceof CramerShoupPrivateKeyParameters) {<NEW_LINE>CramerShoupPrivateKeyParameters sk = (CramerShoupPrivateKeyParameters) ... | p)).mod(p); |
1,560,981 | public static void signUp(Start start, io.supertokens.pluginInterface.thirdparty.UserInfo userInfo) throws StorageQueryException, StorageTransactionLogicException {<NEW_LINE>start.startTransaction(con -> {<NEW_LINE>Connection sqlCon = (Connection) con.getConnection();<NEW_LINE>try {<NEW_LINE>{<NEW_LINE>String QUERY = "... | 1, userInfo.thirdParty.id); |
566,267 | public ExternalWorkflowExecutionSignaledEventAttributes unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>ExternalWorkflowExecutionSignaledEventAttributes externalWorkflowExecutionSignaledEventAttributes = new ExternalWorkflowExecutionSignaledEventAttributes();<NEW_LINE>int originalDepth = context... | String currentParentElement = context.getCurrentParentElement(); |
1,748,730 | protected INDArray createWeightMatrix(NeuralNetConfiguration conf, INDArray weightView, boolean initializeParams) {<NEW_LINE>Convolution3D layerConf = <MASK><NEW_LINE>if (initializeParams) {<NEW_LINE>int[] kernel = layerConf.getKernelSize();<NEW_LINE>int[] stride = layerConf.getStride();<NEW_LINE>val inputDepth = layer... | (Convolution3D) conf.getLayer(); |
1,243,164 | final GetReservationCoverageResult executeGetReservationCoverage(GetReservationCoverageRequest getReservationCoverageRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getReservationCoverageRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "GetReservationCoverage"); |
228,690 | private void submitClearVotingConfigExclusionsTask(ClearVotingConfigExclusionsRequest request, long startTimeMillis, ActionListener<ActionResponse.Empty> listener) {<NEW_LINE>clusterService.submitStateUpdateTask("clear-voting-config-exclusions", new ClusterStateUpdateTask(Priority.URGENT, TimeValue.timeValueMillis(Math... | coordinationMetadata(newCoordinationMetadata).build(); |
1,150,479 | public boolean isInstanceOf(String candidateClassName, String criterionClassName, boolean isInterface) {<NEW_LINE>String methodName = "isInstanceOf";<NEW_LINE>ensureExternalResults();<NEW_LINE>displayClassNames();<NEW_LINE>String i_classOrInterfaceName = internClassName(criterionClassName, Util_InternMap.DO_NOT_FORCE);... | internClassName(candidateClassName, Util_InternMap.DO_NOT_FORCE); |
778,097 | final DeleteAppInstanceResult executeDeleteAppInstance(DeleteAppInstanceRequest deleteAppInstanceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteAppInstanceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE><MASK><NEW_LINE>Requ... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
221,176 | public static void main(String[] args) throws IOException {<NEW_LINE>Cmd cmd = MainUtils.parseArguments(args, FLAGS);<NEW_LINE>if (cmd.argsLength() < 2) {<NEW_LINE>MainUtils.printHelpArgs(FLAGS, new String[] { "input file", "output file" });<NEW_LINE>System.exit(-1);<NEW_LINE>}<NEW_LINE>String input = cmd.getArg(0);<NE... | audioCodec = getAudioCodec(format, input); |
636,740 | public CreateEndpointResult createEndpoint(CreateEndpointRequest createEndpointRequest) throws AmazonServiceException, AmazonClientException {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createEndpointRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(... | JsonUnmarshallerContext> unmarshaller = new CreateEndpointResultJsonUnmarshaller(); |
1,544,391 | boolean isValidDefinition() {<NEW_LINE>if (this.nameTextField.getText().isEmpty()) {<NEW_LINE>NotifyDescriptor notifyDesc = new NotifyDescriptor.Message(mustBeNamedErrorText, NotifyDescriptor.WARNING_MESSAGE);<NEW_LINE>DialogDisplayer.getDefault().notify(notifyDesc);<NEW_LINE>return false;<NEW_LINE>} else {<NEW_LINE>//... | getDefault().notify(notifyDesc); |
1,333,890 | public <T> void updateIcons(List<T> apps, CachingLogic<T> cachingLogic, OnUpdateCallback onUpdateCallback) {<NEW_LINE>// Filter the list per user<NEW_LINE>HashMap<UserHandle, HashMap<ComponentName, T>> userComponentMap = new HashMap<>();<NEW_LINE>int count = apps.size();<NEW_LINE>for (int i = 0; i < count; i++) {<NEW_L... | getValue(), cachingLogic, onUpdateCallback); |
638,414 | public void blockHarvestDrops(ItemStack tool, HarvestDropsEvent event) {<NEW_LINE>if (ToolHelper.isToolEffective2(tool, event.getState())) {<NEW_LINE>ModifierNBT data = new ModifierNBT(TinkerUtil.getModifierTag(tool, name));<NEW_LINE><MASK><NEW_LINE>final World world = event.getWorld();<NEW_LINE>for (Iterator<ItemStack... | BlockPos pos = event.getPos(); |
225,498 | public Filter unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>Filter filter = new Filter();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = context.getCurrentToken();<NEW_LINE>if (token == null)<NEW_... | String currentParentElement = context.getCurrentParentElement(); |
519,057 | public void testContextInfoExactMatchOverrideDefault() throws Exception {<NEW_LINE>CommonTasks.writeLogMsg(Level.INFO, "**** >>>>> server configuration thresholds for - <global - slow : 5s , hung : 10s> <timing - Slow : 120s , hung : 120s>");<NEW_LINE>server.setServerConfigurationFile("contextInfoPattern/server_timing_... | writeLogMsg(Level.INFO, "***** Testcase testContextInfoExactMatchOverrideDefault pass *****"); |
418,380 | public void updateContact(VCard vcard, Long key) throws RemoteException, OperationApplicationException {<NEW_LINE>List<NonEmptyContentValues> contentValues = new ArrayList<NonEmptyContentValues>();<NEW_LINE>convertName(contentValues, vcard);<NEW_LINE>convertNickname(contentValues, vcard);<NEW_LINE>convertPhones(content... | mimeType = cv.getAsString("mimetype"); |
391,880 | final SendUsersMessagesResult executeSendUsersMessages(SendUsersMessagesRequest sendUsersMessagesRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(sendUsersMessagesRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.st... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
1,265,155 | public List<Request> verifyTimes(final HttpMethod method, final String url, final int times) {<NEW_LINE>if (times < 0) {<NEW_LINE>throw new IllegalArgumentException("times must be a non negative number");<NEW_LINE>}<NEW_LINE>if (times == 0) {<NEW_LINE>verifyNever(method, url);<NEW_LINE>return Collections.emptyList();<N... | method, url).build(); |
35,179 | public static void validateTwitter(JReleaserContext context, Twitter twitter, Errors errors) {<NEW_LINE>if (!twitter.resolveEnabled(context.getModel().getProject()))<NEW_LINE>return;<NEW_LINE>context.getLogger().debug("announce.twitter");<NEW_LINE>twitter.setConsumerKey(checkProperty(context, TWITTER_CONSUMER_KEY, "twi... | (RB.$("default.release.message")); |
1,509,918 | public void start(BundleContext context) throws Exception {<NEW_LINE>final Hashtable<String, Object> handlerProps = new Hashtable<String, Object>();<NEW_LINE>handlerProps.put(HandlerConstants.ENGINE_TYPE, HandlerConstants.ENGINE_TYPE_JAXWS);<NEW_LINE>handlerProps.put(HandlerConstants.FLOW_TYPE, HandlerConstants.FLOW_TY... | framework.Constants.SERVICE_RANKING, 3); |
894,943 | public void run(RegressionEnvironment env) {<NEW_LINE>RegressionPath path = new RegressionPath();<NEW_LINE>env.compileDeploy("@name('create') @public create window MyWindow#keepall() as select theString, longPrimitive from SupportBean", path);<NEW_LINE>SupportMTUpdateListener listenerWindow = new SupportMTUpdateListene... | ("s0").addListener(listenerConsumer); |
1,182,750 | public void marshall(NetworkInterface networkInterface, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (networkInterface == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(networkInterface.getNetworkInterface... | networkInterface.getPublicIp(), PUBLICIP_BINDING); |
150,057 | public static int countDPEff(String exp, boolean result, int start, int end, HashMap<String, Integer> cache) {<NEW_LINE>String key = "" + start + end;<NEW_LINE>int count = 0;<NEW_LINE>if (!cache.containsKey(key)) {<NEW_LINE>if (start == end) {<NEW_LINE>if (exp.charAt(start) == '1') {<NEW_LINE>count = 1;<NEW_LINE>} else... | count = cache.get(key); |
1,379,623 | public void execute(MacroContext context, String parameter, MapToolMacroContext executionContext) {<NEW_LINE>StringBuilder builder = new StringBuilder();<NEW_LINE>List<Macro> macros = new ArrayList<Macro<MASK><NEW_LINE>macros.sort(MACRO_NAME_COMPARATOR);<NEW_LINE>builder.append("<table border='1'>");<NEW_LINE>builder.a... | >(MacroManager.getRegisteredMacros()); |
790,881 | public void draw(CrusherRecipe recipe, PoseStack transform, double mouseX, double mouseY) {<NEW_LINE>List<StackWithChance> validSecondaries = getValidSecondaryOutputs(recipe);<NEW_LINE>int yBase = validSecondaries.isEmpty() ? 36 : validSecondaries.size() < 2 ? 27 : 18;<NEW_LINE>for (int i = 0; i < validSecondaries.size... | draw(transform, 8, 0); |
667,886 | public // must obey all Subscriber rules on its consuming side<NEW_LINE>Subscriber<T> createSubscriber(final SubscriberWhiteboxVerification.WhiteboxSubscriberProbe<T> probe) {<NEW_LINE>final Processor<T, T> processor = createIdentityProcessor(processorBufferSize);<NEW_LINE>processor.subscribe(new Subscriber<T>() {<NEW_... | .format("whiteboxSubscriber::onError(%s)", cause)); |
1,436,425 | private boolean checkRequest(String request) {<NEW_LINE>shouldKeep = false;<NEW_LINE>rCommand = "NOOP";<NEW_LINE>rMessage = "invalid: " + request;<NEW_LINE>rStatus = rStatusBadRequest;<NEW_LINE>String[] parts = request.split("\\s");<NEW_LINE>if (parts.length != 3 || !"GET".equals(parts[0]) || !parts[1].startsWith("/"))... | cmd = cmd.substring(1); |
957,338 | public void addMappingForUrlPatterns(EnumSet<DispatcherType> types, boolean isLast, String... patterns) {<NEW_LINE>if (types == null) {<NEW_LINE>dispatcherTypes.add(DispatcherType.REQUEST);<NEW_LINE>dispatcherTypes.add(DispatcherType.ASYNC);<NEW_LINE>} else {<NEW_LINE>dispatcherTypes.addAll(types);<NEW_LINE>}<NEW_LINE>... | newUrlList = new ArrayList<>(); |
953,518 | public static <T extends Model> List<T> processCursor(Class<? extends Model> type, Cursor cursor) {<NEW_LINE>TableInfo tableInfo = Cache.getTableInfo(type);<NEW_LINE><MASK><NEW_LINE>final List<T> entities = new ArrayList<T>();<NEW_LINE>try {<NEW_LINE>Constructor<?> entityConstructor = type.getConstructor();<NEW_LINE>if... | String idName = tableInfo.getIdName(); |
508,725 | protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {<NEW_LINE>String test = request.getParameter("test");<NEW_LINE>PrintWriter out = response.getWriter();<NEW_LINE>out.println("Starting --" + test + "<br>");<NEW_LINE>final TraceComponent tc = <MASK><NEW_L... | Tr.register(JMSContextTestServlet.class); |
848,430 | public void testTimerAccessFromTimeoutAfterCancelFromTimeout() throws Exception {<NEW_LINE>NpTimedObjectTimerLocal timerBean;<NEW_LINE>// --------------------------------------------------------------------<NEW_LINE>// Create a BMT Stateless Bean to test it<NEW_LINE>// --------------------------------------------------... | NpTimedObjectTimerBean.infoAccessAfterCancelFromTimeout, NpTimedObjectTimerBean.svAccessAfterCreateResult); |
1,648,958 | final DeleteConnectorResult executeDeleteConnector(DeleteConnectorRequest deleteConnectorRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteConnectorRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(F... | (super.beforeMarshalling(deleteConnectorRequest)); |
110,922 | private void load(SoundEffect3Definition se, InputStream var1, SoundEffect2Definition var2) {<NEW_LINE><MASK><NEW_LINE>se.field1155[0] = var3 >> 4;<NEW_LINE>se.field1155[1] = var3 & 15;<NEW_LINE>if (var3 != 0) {<NEW_LINE>se.field1156[0] = var1.readUnsignedShort();<NEW_LINE>se.field1156[1] = var1.readUnsignedShort();<NE... | int var3 = var1.readUnsignedByte(); |
905,609 | public PageSet<? extends StorageMetadata> list() {<NEW_LINE>PageSet<? extends StorageMetadata> upstream = this.delegate().list();<NEW_LINE>ImmutableList.Builder<StorageMetadata> results = new ImmutableList.Builder<>();<NEW_LINE>Set<String> virtualBuckets = new HashSet<>();<NEW_LINE>for (StorageMetadata sm : upstream) {... | setSize(sm.getSize()); |
426,264 | public void display(final SheetStub stub, final boolean early) {<NEW_LINE>// Since we are on Swing EDT, use asynchronous processing<NEW_LINE>OmrExecutors.getCachedLowExecutor().submit(() -> {<NEW_LINE>try {<NEW_LINE>LogUtil.start(stub);<NEW_LINE>// Check whether we should run early steps on the sheet<NEW_LINE>checkStub... | logger.debug("Too late for {}", stub); |
1,577,803 | public List<DataFetcherResult<CorpUser>> batchLoad(final List<String> urns, final QueryContext context) {<NEW_LINE>try {<NEW_LINE>final List<Urn> corpUserUrns = urns.stream().map(UrnUtils::getUrn).<MASK><NEW_LINE>final Map<Urn, EntityResponse> corpUserMap = _entityClient.batchGetV2(CORP_USER_ENTITY_NAME, new HashSet<>(... | collect(Collectors.toList()); |
694,438 | final GetWorkUnitResultsResult executeGetWorkUnitResults(GetWorkUnitResultsRequest getWorkUnitResultsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getWorkUnitResultsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetri... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
1,764,474 | public void init(SegmentGenerationJobSpec spec) {<NEW_LINE>_spec = spec;<NEW_LINE>if (_spec.getInputDirURI() == null) {<NEW_LINE>throw new RuntimeException("Missing property 'inputDirURI' in 'jobSpec' file");<NEW_LINE>}<NEW_LINE>if (_spec.getOutputDirURI() == null) {<NEW_LINE>throw new RuntimeException("Missing propert... | (new HashMap<>()); |
100,082 | private List<Object> createDefaultHoverInfos(String textAtHoverPosition, Object evalResultObject, LanguageInfo langInfo) {<NEW_LINE>List<Object> contents = new ArrayList<>();<NEW_LINE>contents.add(org.graalvm.tools.lsp.server.types.MarkedString.create(langInfo.getId(), textAtHoverPosition));<NEW_LINE>String result = ev... | , markup.getValue())); |
523,128 | public void fetch() {<NEW_LINE>collectObj();<NEW_LINE>Iterator<Integer> itr = serverObjMap.keySet().iterator();<NEW_LINE>ActiveSpeedData a = new ActiveSpeedData();<NEW_LINE>while (itr.hasNext()) {<NEW_LINE>int serverId = itr.next();<NEW_LINE>TcpProxy tcp = TcpProxy.getTcpProxy(serverId);<NEW_LINE>try {<NEW_LINE>MapPack... | (p.get("act1")); |
499,989 | private void sendRequest(Request request, RequestContext requestContext, Map<String, String> wireAttrs, TransportCallback<StreamResponse> callback) {<NEW_LINE>final TransportCallback<StreamResponse> decoratedCallback = decorateUserCallback(request, callback);<NEW_LINE>final NettyClientState state = _state.get();<NEW_LI... | MILLISECONDS, None.none()); |
1,039,039 | protected void onSizeChanged(int w, int h, int oldw, int oldh) {<NEW_LINE>super.onSizeChanged(w, h, oldw, oldh);<NEW_LINE>try {<NEW_LINE>rect = new Rect(innerPadding, innerPadding, w - innerPadding, h - innerPadding);<NEW_LINE>bitmap = Bitmap.createBitmap(w - 2 * innerPadding, h - 2 * innerPadding, Config.ARGB_8888);<N... | = new int[scaledWidth * scaledHeight]; |
1,004,750 | private ImmutableMap<String, ?> generateBootstrap(String zone, boolean supportIpv6) {<NEW_LINE>ImmutableMap.Builder<String, Object> nodeBuilder = ImmutableMap.builder();<NEW_LINE>nodeBuilder.put("id", "C2P-" + (rand.nextInt() & Integer.MAX_VALUE));<NEW_LINE>if (!zone.isEmpty()) {<NEW_LINE>nodeBuilder.put("locality", Im... | of("type", "google_default"))); |
447,553 | public void onDraw(Canvas canvas) {<NEW_LINE>Rect rect = targetElement.getRect();<NEW_LINE>Rect originRect = targetElement.getOriginRect();<NEW_LINE>canvas.drawRect(originRect, dashLinePaint);<NEW_LINE>Element parentElement = targetElement.getParentElement();<NEW_LINE>if (parentElement != null) {<NEW_LINE>Rect parentRe... | , y, dip2px(2)); |
1,575,086 | public void beforeStartNewCreatedVm(VmInstanceSpec spec) {<NEW_LINE>String providerUuid = new NetworkServiceProviderLookup().lookupUuidByType(FlatNetworkServiceConstant.FLAT_NETWORK_SERVICE_TYPE_STRING);<NEW_LINE>Map<String, List<String>> vmStaticIps = new StaticIpOperator().getStaticIpbyVmUuid(spec.getVmInventory().ge... | (l3.getUuid())); |
362,762 | public void invoke(@NotNull String line, @NotNull Repl api, @NotNull Supplier<@NotNull String> scanner) throws QuitReplException {<NEW_LINE>Concrete.Expression expr = api.preprocessExpr(line);<NEW_LINE>if (api.checkErrors() || expr == null)<NEW_LINE>return;<NEW_LINE>if (expr instanceof Concrete.ReferenceExpression && (... | normalize(result.expression))); |
1,358,870 | public String render(EnumModel model, int index, int size, Map<String, Object> session) {<NEW_LINE>if (isExcludedClass(model.getType().getName())) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>StringWriter sw = new StringWriter();<NEW_LINE>PrintWriter writer = new PrintWriter(sw);<NEW_LINE>if (index == 0) {<NEW_LINE>Util... | " %s", value.getIdentifier()); |
1,211,371 | public boolean handle(KeyEvent event) {<NEW_LINE>event = mTranslator.doTranslateKeys(event);<NEW_LINE>setDispatchEvent(event);<NEW_LINE>boolean isUpAction = event.getAction() == DEFAULT_ACTION;<NEW_LINE>boolean isDownAction = event.getAction() == KeyEvent.ACTION_DOWN;<NEW_LINE>// user opens the video and continue to ho... | .getExoPlayerView().showController(); |
61,899 | public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {<NEW_LINE>app = requireMyApplication();<NEW_LINE>boolean nightMode = !app.getSettings().isLightActionBar();<NEW_LINE>LayoutInflater themedInflater = UiUtilities.getInflater(requireContext(), n... | ADDR_HOUSE_NUMBER.getValue(), houseNumberEditText); |
66,054 | public static void main(String[] args) throws InterruptedException {<NEW_LINE>observationRegistry.observationConfig().observationHandler(new ObservationTextPublisher()).<MASK><NEW_LINE>observationRegistry.observationConfig().tagsProvider(new CustomTagsProvider()).observationPredicate(new IgnoringObservationPredicate())... | observationHandler(new TimerObservationHandler(registry)); |
834,942 | public List<String> suggestionList(final String query) throws IOException, ExtractionException {<NEW_LINE>final List<String> suggestions = new ArrayList<>();<NEW_LINE>final Downloader dl = NewPipe.getDownloader();<NEW_LINE>final String url = SOUNDCLOUD_API_V2_URL + "search/queries" + "?q=" + URLEncoder.encode(query, UT... | + SoundcloudParsingHelper.clientId() + "&limit=10"; |
1,699,468 | public static Object calculateValue(Expression e) {<NEW_LINE>if (e instanceof Literal) {<NEW_LINE>((Literal) e).computeConstant();<NEW_LINE>switch(e.constant.typeID()) {<NEW_LINE>case TypeIds.T_int:<NEW_LINE>return e.constant.intValue();<NEW_LINE>case TypeIds.T_byte:<NEW_LINE><MASK><NEW_LINE>case TypeIds.T_short:<NEW_L... | return e.constant.byteValue(); |
544,843 | public Clustering<MeanModel> run(Relation<NumberVector> relation) {<NEW_LINE>final int dim = RelationUtil.dimensionality(relation);<NEW_LINE>CFTree<?> tree = cffactory.newTree(relation.getDBIDs(), relation, storeIds);<NEW_LINE>Map<ClusterFeature, DBIDs> idmap = new Reference2ObjectOpenHashMap<>(tree.numLeaves());<NEW_L... | , diagonal(variance)))); |
815,003 | private void readObject(java.io.ObjectInputStream objectInputStream) throws java.io.IOException, java.lang.ClassNotFoundException {<NEW_LINE>if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())<NEW_LINE>trace.entry(this, cclass, "readObject", "objectInputStream=" + objectInputStream + "(java.io.ObjectInputStrea... | exit(this, cclass, "readObject"); |
17,790 | public DataSource doCreateDataSource(DataSourceProperty dataSourceProperty) {<NEW_LINE>BeeDataSourceConfig config = MERGE_CREATOR.create(gConfig, dataSourceProperty.getBeecp());<NEW_LINE>config.setUsername(dataSourceProperty.getUsername());<NEW_LINE>config.setPassword(dataSourceProperty.getPassword());<NEW_LINE>config.... | setJdbcUrl(dataSourceProperty.getUrl()); |
433,657 | public void onBindItemViewHolder(RecentPhotoViewHolder viewHolder, @NonNull Cursor cursor) {<NEW_LINE>viewHolder.imageView.setImageDrawable(null);<NEW_LINE>long rowId = cursor.getLong(cursor.getColumnIndexOrThrow(MediaStore.Images.ImageColumns._ID));<NEW_LINE>long dateTaken = cursor.getLong(cursor.getColumnIndexOrThrow... | MediaStoreSignature(mimeType, dateModified, orientation); |
61,492 | public void mouseDragged(MouseEvent e) {<NEW_LINE>if (!selectionActive || e.isConsumed()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>e.consume();<NEW_LINE>Point p = e.getPoint();<NEW_LINE>if (p.x == lastX) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>Cursor cursor = Cursor.getPredefinedCursor(p.x < lastX ? Cursor.W_RESIZE_CURSOR... | abs(bitOffset - startBit) + 1; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.