idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
359,448 | private void extractInstance(ExtractionInstance instance, String alias) {<NEW_LINE>PrototypeMemberDeclaration first = instance.declarations.get(0);<NEW_LINE>String className = first.qualifiedClassName;<NEW_LINE>if (pattern == Pattern.USE_GLOBAL_TEMP || pattern == Pattern.USE_CHUNK_TEMP) {<NEW_LINE>// Use the temp varia... | NodeUtil.newQName(compiler, className); |
193,980 | public static void main(String[] args) {<NEW_LINE>if (args.length < 1) {<NEW_LINE>System.out.println("Usage: java twitter4j.examples.suggestedusers.GetMemberSuggestions [slug]");<NEW_LINE>System.exit(-1);<NEW_LINE>}<NEW_LINE>System.out.println("Showing suggested users in " <MASK><NEW_LINE>try {<NEW_LINE>Twitter twitter... | + args[0] + " category."); |
1,711,496 | public boolean visit(SwitchCase node) {<NEW_LINE>if (!hasChildrenChanges(node)) {<NEW_LINE>return doVisitUnchangedChildren(node);<NEW_LINE>}<NEW_LINE>// dont allow switching from case to default or back. New statements should be created.<NEW_LINE>if (node.getAST().apiLevel() >= JLS12_INTERNAL) {<NEW_LINE>int pos = // $... | ).getTokenEndOffset(oldToken, pos); |
1,179,524 | default F2<TreeZipper<A>, TreeZipper<B>, TreeZipper<C>> zipTreeZipperM() {<NEW_LINE>F2<A, B, C> outer = this;<NEW_LINE>return (ta, tb) -> {<NEW_LINE>final F2<Stream<Tree<A>>, Stream<Tree<B>>, Stream<Tree<C>>> sf = outer.treeM().zipStreamM();<NEW_LINE>F2<P3<Stream<Tree<A>>, A, Stream<Tree<A>>>, P3<Stream<Tree<B>>, B, St... | , pb._3())); |
922,997 | public static void main(final String[] args) {<NEW_LINE>// test parsing of a url<NEW_LINE>DigestURL url;<NEW_LINE>try {<NEW_LINE>url = new DigestURL(args[0]);<NEW_LINE>final byte[] content = url.get(ClientIdentification.yacyInternetCrawlerAgent, null, null);<NEW_LINE>final Document[] document = new htmlParser().parse(u... | System.out.println(title); |
404,114 | public boolean beginTrans(boolean mutable, boolean failEarly) {<NEW_LINE>if (DEBUG) {<NEW_LINE>System.out.println(// NOI18N<NEW_LINE>"DEBUG: [" + Thread.currentThread().getName() + "] Starting transaction: mutable = " + mutable + ", failEarly = " + failEarly);<NEW_LINE>}<NEW_LINE>synchronized (transactionLock) {<NEW_LI... | while (!result && !failEarly); |
1,816,742 | public List<ValidateError> validate() {<NEW_LINE>List<ValidateError> errors = new ArrayList<>();<NEW_LINE>Validator validator;<NEW_LINE>ValidateError error;<NEW_LINE>validator = <MASK><NEW_LINE>error = validator.validate(this.no, convLabelName("No"));<NEW_LINE>if (error != null) {<NEW_LINE>errors.add(error);<NEW_LINE>}... | ValidatorFactory.getInstance(Validator.REQUIRED); |
1,257,633 | private static Sorting computeSorting(final PartialDruidQuery partialQuery, final PlannerContext plannerContext, final RowSignature rowSignature, @Nullable final VirtualColumnRegistry virtualColumnRegistry) {<NEW_LINE>final Sort sort = Preconditions.checkNotNull(partialQuery.getSort(), "sort");<NEW_LINE>final Project s... | "Don't know what to do with direction[%s]", collation.getDirection()); |
1,170,463 | public void deploy(EngineDeployment deployment, Map<String, Object> deploymentSettings) {<NEW_LINE>LOGGER.debug("Processing deployment {}", deployment.getName());<NEW_LINE><MASK><NEW_LINE>for (EngineResource resource : deployment.getResources().values()) {<NEW_LINE>if (isCmmnResource(resource.getName())) {<NEW_LINE>LOG... | CmmnParseResult parseResult = new CmmnParseResult(deployment); |
774,620 | final ListApplicationsResult executeListApplications(ListApplicationsRequest listApplicationsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listApplicationsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | invoke(request, responseHandler, executionContext); |
1,370,076 | public void doInTransactionWithoutResult(final TransactionStatus status) {<NEW_LINE>final NetworkVO vo = new NetworkVO(id, network, offering.getId(), guru.getName(), owner.getDomainId(), owner.getId(), relatedFile, name, displayText, predefined.getNetworkDomain(), offering.getGuestType(), plan.getDataCenterId(), plan.g... | final NetworkGuruAdditionalFunctions functions = (NetworkGuruAdditionalFunctions) guru; |
1,239,897 | final GetFlowTemplateResult executeGetFlowTemplate(GetFlowTemplateRequest getFlowTemplateRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(getFlowTemplateRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(F... | addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig); |
1,452,127 | public void onCreate(final Bundle savedInstanceState) {<NEW_LINE>super.onCreate(savedInstanceState);<NEW_LINE>setTheme();<NEW_LINE>binding = AuthorizationTokenActivityBinding.inflate(getLayoutInflater());<NEW_LINE>setContentView(binding.getRoot());<NEW_LINE>final Bundle extras = getIntent().getExtras();<NEW_LINE>if (ex... | auth1.setText(getAuthExplainShort()); |
1,327,915 | private void saveGroups(JMeterVariables vars, String basename, java.util.regex.MatchResult match) {<NEW_LINE>StringBuilder buf = new StringBuilder();<NEW_LINE>buf.append(basename);<NEW_LINE>// $NON-NLS-1$<NEW_LINE>buf.append("_g");<NEW_LINE>int pfxlen = buf.length();<NEW_LINE>String prevString = vars.<MASK><NEW_LINE>in... | get(buf.toString()); |
1,437,095 | protected ActionResult<WrapOutString> execute(HttpServletRequest request, EffectivePerson effectivePerson, Integer size, byte[] bytes, FormDataContentDisposition disposition) {<NEW_LINE>ActionResult<WrapOutString> result = new ActionResult<>();<NEW_LINE>ByteArrayOutputStream baos = new ByteArrayOutputStream();<NEW_LINE... | int height = image.getHeight(); |
1,016,217 | public static List<String> directWrite(String path, List<String> classNames) throws Exception {<NEW_LINE>try {<NEW_LINE>Document document = DocumentHelper.createDocument();<NEW_LINE>Element persistence = document.addElement("persistence", "http://java.sun.com/xml/ns/persistence");<NEW_LINE>persistence.addAttribute(QNam... | sliceJpaObject_element = unit.addElement("class"); |
1,425,357 | private Mode promptForMode(final File sketch, final ModeInfo preferredMode) {<NEW_LINE>final String extension = sketch.getName().substring(sketch.getName().lastIndexOf('.') + 1);<NEW_LINE>final List<Mode> possibleModes = new ArrayList<>();<NEW_LINE>for (final Mode mode : getModeList()) {<NEW_LINE>if (mode.canEdit(sketc... | Messages.showWarning("Modeless Dialog", msg); |
1,410,129 | private void renderReport() throws Exception {<NEW_LINE>AMedia media = null;<NEW_LINE>Listitem selected = previewType.getSelectedItem();<NEW_LINE>if (selected == null || "PDF".equals(selected.getValue())) {<NEW_LINE>String path = System.getProperty("java.io.tmpdir");<NEW_LINE>String prefix = makePrefix(m_reportEngine.g... | "xlsx", "application/vnd.ms-excel", file, true); |
870,303 | protected void addCompletions(CompletionParameters completionParameters, ProcessingContext processingContext, CompletionResultSet completionResultSet) {<NEW_LINE>if (completionResultSet == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (completionParameters == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (!LithoPlu... | PsiElement element = completionParameters.getPosition(); |
668,352 | public void doFilter(ServletRequest request, ServletResponse response) throws IOException, ServletException {<NEW_LINE>// Call the next filter if there is one<NEW_LINE>AtomicInteger pos = ((AtomicInteger) request.getAttribute("pos"));<NEW_LINE>if (pos.get() < n) {<NEW_LINE>FilterConfigImpl filterConfig = filters[pos.ge... | getServletContext().getNamedDispatcher("default"); |
1,341,431 | public void handle(AnnotationValues<NonNull> annotation, JCAnnotation ast, JavacNode annotationNode) {<NEW_LINE>handleFlagUsage(annotationNode, ConfigurationKeys.NON_NULL_FLAG_USAGE, "@NonNull");<NEW_LINE>if (annotationNode.up().getKind() == Kind.FIELD) {<NEW_LINE>// This is meaningless unless the field is used to gene... | addNullCheckIfNeeded(declaration, paramNode, annotationNode); |
150,430 | public RFuture<Boolean> addAsync(V value, long ttl, TimeUnit unit) {<NEW_LINE>if (ttl < 0) {<NEW_LINE>throw new IllegalArgumentException("TTL can't be negative");<NEW_LINE>}<NEW_LINE>if (ttl == 0) {<NEW_LINE>return addAsync(value);<NEW_LINE>}<NEW_LINE>if (unit == null) {<NEW_LINE>throw new NullPointerException("TimeUni... | ) + unit.toMillis(ttl); |
736,479 | private Object createRangeWithThreeGivenArguments(Object[] args) {<NEW_LINE>Object firstArg = args[0];<NEW_LINE>Object secondArg = args[1];<NEW_LINE>Object thirdArg = args[2];<NEW_LINE>// Deal with negative integers first<NEW_LINE>if (firstArg != null && firstArg instanceof Double && (Double) firstArg % 1 == 0) {<NEW_L... | (secondArg).trim()); |
1,743,469 | public void onReceive(Context context, Intent intent) {<NEW_LINE>this.context = context;<NEW_LINE>Settings settings = new Settings(context);<NEW_LINE>if (!settings.isPlainTextBackupBroadcastEnabled()) {<NEW_LINE>NotificationHelper.notify(context, Constants.NotificationChannel.BACKUP_FAILED, R.string.<MASK><NEW_LINE>ret... | backup_receiver_title_backup_failed, R.string.backup_receiver_plain_disabled); |
166,225 | public DescribeReservedNodeOfferingsResult unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>DescribeReservedNodeOfferingsResult describeReservedNodeOfferingsResult = new DescribeReservedNodeOfferingsResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>int targetDepth = origi... | ().unmarshall(context)); |
295,010 | private boolean doConfirm(Node[] sel) {<NEW_LINE>String message;<NEW_LINE>String title;<NEW_LINE>boolean customDelete = true;<NEW_LINE>for (int i = 0; i < sel.length; i++) {<NEW_LINE>if (!Boolean.TRUE.equals(sel[i].getValue("customDelete"))) {<NEW_LINE>// NOI18N<NEW_LINE>customDelete = false;<NEW_LINE>break;<NEW_LINE>}... | ().notify(desc)); |
592,427 | private void locateTableAndProcessMetaData(DatabaseMetaData databaseMetaData, @Nullable String catalogName, @Nullable String schemaName, @Nullable String tableName) {<NEW_LINE>Map<String, TableMetaData> tableMeta = new HashMap<>();<NEW_LINE>ResultSet tables = null;<NEW_LINE>try {<NEW_LINE>tables = databaseMetaData.getT... | toUpperCase() : "", tmd); |
1,787,548 | private void downloadFile(DownloadTaskParams param) throws IOException {<NEW_LINE>String url = param.url;<NEW_LINE>File writePath = param.targetFile;<NEW_LINE>this.hash = param.hash;<NEW_LINE>OkHttpClient client = new OkHttpClient();<NEW_LINE>Request request = new Request.Builder().url(url).build();<NEW_LINE>Response r... | (Okio.sink(writePath)); |
345,854 | protected static byte parseByte(Object obj, String name) throws JMSException {<NEW_LINE>if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())<NEW_LINE>SibTr.entry(tc, "parseByte", new Object[] { obj, name });<NEW_LINE>byte value = 0;<NEW_LINE>if (obj instanceof Byte) {<NEW_LINE>value = ((Byte) obj).byteValue... | debug(tc, "invalid convert", e); |
1,147,801 | public void keyPressed(KeyEvent event) {<NEW_LINE>int code = event.getKeyCode();<NEW_LINE>if (code == KeyEvent.VK_COPY || (code == KeyEvent.VK_C && event.isMetaDown())) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (code == KeyEvent.VK_PASTE || (code == KeyEvent.VK_V && event.isMetaDown())) {<NEW_LINE>Transferable clipData... | 'a' + code - KeyEvent.VK_A); |
281,172 | public NielsenConfiguration unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>NielsenConfiguration nielsenConfiguration = new NielsenConfiguration();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targe... | JsonToken token = context.getCurrentToken(); |
1,646,877 | // InputStream is passed for XmlReaderException creation only<NEW_LINE>private String calculateRawEncoding(final String bomEnc, final String xmlGuessEnc, final String xmlEnc, final InputStream is) throws IOException {<NEW_LINE>String encoding;<NEW_LINE>if (bomEnc == null) {<NEW_LINE>if (xmlGuessEnc == null || xmlEnc ==... | bomEnc, xmlGuessEnc, xmlEnc, is); |
1,077,155 | public static <T> RouterTree<T> build(List<RouterTree<T>> nodes) {<NEW_LINE>if (nodes == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>List<RouterTree<T>> topNodes = new ArrayList<>();<NEW_LINE>nodes.forEach(node -> {<NEW_LINE>String pid = node.getParentId();<NEW_LINE>if (pid == null || TOP_NODE_ID.equals(pid)) {<N... | String id = n.getId(); |
247,026 | protected void addCompletions(@NotNull CompletionParameters completionParameters, ProcessingContext processingContext, @NotNull CompletionResultSet completionResultSet) {<NEW_LINE>PsiElement element = completionParameters.getPosition();<NEW_LINE>// Method parameter type in the Spec class<NEW_LINE>// PsiIdentifier -> Ps... | getMethods(), LithoPluginUtils::isState); |
573,335 | private void generateBrokerHtml(PrintWriter writer, String clusterName, int brokerId) throws ClusterInfoError {<NEW_LINE>KafkaBroker broker = getBroker(clusterName, brokerId);<NEW_LINE>BrokerStats stats = getLatestStats(clusterName, broker);<NEW_LINE>writer.print("<tr> <td> " + new Date(stats.getTimestamp()) + "</td>")... | getPartition()), rs)); |
1,358,769 | public AssemblyResultSet trimTo(final AssemblyRegion trimmedAssemblyRegion) {<NEW_LINE>final Map<Haplotype, Haplotype> originalByTrimmedHaplotypes = <MASK><NEW_LINE>if (refHaplotype == null) {<NEW_LINE>throw new IllegalStateException("refHaplotype is null");<NEW_LINE>}<NEW_LINE>Utils.nonNull(trimmedAssemblyRegion);<NEW... | calculateOriginalByTrimmedHaplotypes(trimmedAssemblyRegion.getPaddedSpan()); |
704,409 | public static RetrieveCallResponse unmarshall(RetrieveCallResponse retrieveCallResponse, UnmarshallerContext _ctx) {<NEW_LINE>retrieveCallResponse.setRequestId(_ctx.stringValue("RetrieveCallResponse.RequestId"));<NEW_LINE>retrieveCallResponse.setCode(_ctx.stringValue("RetrieveCallResponse.Code"));<NEW_LINE>retrieveCall... | (_ctx.stringValue("RetrieveCallResponse.Data.UserContext.BreakCode")); |
416,897 | public Pair<Integer, Location> fillinBuild(VectorSTL<Integer> check, AddrSpace const_space) {<NEW_LINE>// Make sure there is a build statement for all subtable params<NEW_LINE>// Return 0 upon success, 1 if there is a duplicate BUILD, 2 if there is<NEW_LINE>// a build for a non-subtable<NEW_LINE>OpTpl op;<NEW_LINE>Varn... | locations.add(op.location); |
857,105 | public void showSingleChoicePoiFilterDialog(final MapActivity mapActivity, final DismissListener listener) {<NEW_LINE>final PoiFiltersHelper poiFilters = app.getPoiFilters();<NEW_LINE>final ContextMenuAdapter adapter = new ContextMenuAdapter(app);<NEW_LINE>adapter.addItem(new ContextMenuItem(null).setTitleId(R.string.s... | (mapActivity, !isNightMode()); |
23,512 | private OpenAPI prepareModel(OpenApiConfig config, OpenApiStaticFile staticFile, List<? extends IndexView> filteredIndexViews) {<NEW_LINE>try {<NEW_LINE>synchronized (OpenApiDocument.INSTANCE) {<NEW_LINE>OpenApiDocument.INSTANCE.reset();<NEW_LINE>OpenApiDocument.INSTANCE.config(config);<NEW_LINE>OpenApiDocument.INSTANC... | (config, getContextClassLoader())); |
1,829,193 | private XContentBuilder toXContentInternal(final XContentBuilder builder, final ToXContent.Params params) throws IOException {<NEW_LINE>builder.startObject(SNAPSHOT);<NEW_LINE>builder.field(NAME, snapshotId.getName());<NEW_LINE>builder.field(UUID, snapshotId.getUUID());<NEW_LINE>assert version != null : "version must a... | builder.field(TOTAL_SHARDS, totalShards); |
81,332 | public long numParams(NeuralNetConfiguration conf) {<NEW_LINE>VariationalAutoencoder layer = (VariationalAutoencoder) conf.getLayer();<NEW_LINE>val nIn = layer.getNIn();<NEW_LINE>val nOut = layer.getNOut();<NEW_LINE>int[] encoderLayerSizes = layer.getEncoderLayerSizes();<NEW_LINE>int[<MASK><NEW_LINE>int paramCount = 0;... | ] decoderLayerSizes = layer.getDecoderLayerSizes(); |
1,231,166 | protected void copyProcessEngineProperties(ProcessEngineConfigurationImpl processEngineConfiguration) {<NEW_LINE>initProcessInstanceService(processEngineConfiguration);<NEW_LINE>initProcessInstanceStateChangedCallbacks(processEngineConfiguration);<NEW_LINE>initCaseInstanceService(processEngineConfiguration);<NEW_LINE>c... | setAsyncHistoryJsonGroupingThreshold(processEngineConfiguration.getAsyncHistoryJsonGroupingThreshold()); |
933,840 | private void processVisibleModes(String key, MapWidgetInfo widgetInfo) {<NEW_LINE>for (ApplicationMode ms : ApplicationMode.values(app)) {<NEW_LINE>boolean collapse = ms.isWidgetCollapsible(key);<NEW_LINE>boolean <MASK><NEW_LINE>Set<String> set = visibleSideWidgetsFromSettings.get(ms);<NEW_LINE>if (set != null) {<NEW_L... | visible = ms.isWidgetVisible(key); |
1,828,063 | public boolean beforeReadOperations(OIdentifiable identifiable) {<NEW_LINE>if (identifiable instanceof ODocument) {<NEW_LINE>ODocument doc = (ODocument) identifiable;<NEW_LINE>OImmutableClass clazz = <MASK><NEW_LINE>if (clazz != null) {<NEW_LINE>if (clazz.isTriggered()) {<NEW_LINE>ORecordHook.RESULT val = OClassTrigger... | ODocumentInternal.getImmutableSchemaClass(this, doc); |
952,735 | private GroupShardsIterator<ShardIterator> allSatisfyingPredicateShardsGrouped(String[] indices, boolean includeEmpty, Predicate<ShardRouting> predicate) {<NEW_LINE>// use list here since we need to maintain identity across shards<NEW_LINE>ArrayList<ShardIterator> set = new ArrayList<>();<NEW_LINE>for (String index : i... | indexShardRoutingTable = indexRoutingTable.shard(shardId); |
1,550,737 | public static void main(String[] args) {<NEW_LINE>class Local {<NEW_LINE><NEW_LINE>final int x;<NEW_LINE><NEW_LINE>String name;<NEW_LINE><NEW_LINE>@java.lang.SuppressWarnings("all")<NEW_LINE>public Local(final int x) {<NEW_LINE>this.x = x;<NEW_LINE>}<NEW_LINE><NEW_LINE>@java.lang.SuppressWarnings("all")<NEW_LINE>public... | final Local other = (Local) o; |
1,222,951 | public Object call(ExecutionContext context, Object self, Object... args) {<NEW_LINE>if (!(self instanceof DynDate)) {<NEW_LINE>throw new ThrowException(context, context.createTypeError("setUTCSeconds(...) may only be used with Dates"));<NEW_LINE>}<NEW_LINE>DynDate dateObj = (DynDate) self;<NEW_LINE>long t = dateObj.ge... | u = timeClip(context, date); |
1,234,374 | private void queueActionLocked(DeltaType actionType, KubernetesObject obj) {<NEW_LINE>String <MASK><NEW_LINE>Deque<MutablePair<DeltaType, KubernetesObject>> deltas = items.get(id);<NEW_LINE>if (deltas == null) {<NEW_LINE>deltas = new LinkedList<>();<NEW_LINE>deltas.add(new MutablePair(actionType, obj));<NEW_LINE>} else... | id = this.keyOf(obj); |
678,793 | private boolean closeAction() {<NEW_LINE>if (!document.isSaved()) {<NEW_LINE>log.info("Confirming whether to save the design");<NEW_LINE>ComponentConfigDialog.disposeDialog();<NEW_LINE>int result = JOptionPane.showConfirmDialog(this, trans.get("BasicFrame.dlg.lbl1") + rocket.getName() + trans.get("BasicFrame.dlg.lbl2")... | Markers.USER_MARKER, "User cancelled closing, result=" + result); |
1,661,526 | private void registerReturnValueSource(Location location) throws DataflowAnalysisException {<NEW_LINE>// Nothing to do if called method does not return a value<NEW_LINE>InvokeInstruction inv = (InvokeInstruction) location<MASK><NEW_LINE>String calledMethodSig = inv.getSignature(cpg);<NEW_LINE>if (calledMethodSig.endsWi... | .getHandle().getInstruction(); |
131,256 | private static int drawPrism(CommandContext<CommandSourceStack> ctx, String base) {<NEW_LINE>BlockPos pos;<NEW_LINE>double radius;<NEW_LINE>int height;<NEW_LINE>String orientation;<NEW_LINE>BlockInput block;<NEW_LINE>Predicate<BlockInWorld> replacement;<NEW_LINE>try {<NEW_LINE>pos = getArg(ctx, BlockPosArgument::getSpa... | MutableBlockPos mbpos = pos.mutable(); |
991,851 | public DeleteConflictOutcome handleDeleteConflicts(DeleteConflictList theConflictList, RequestDetails theRequest, TransactionDetails theTransactionDetails) {<NEW_LINE>ourLog.debug("Have delete conflicts: {}", theConflictList);<NEW_LINE>if (shouldCascade(theRequest) == DeleteCascadeModeEnum.NONE) {<NEW_LINE>// Add a mes... | IdDt nextSource = next.getSourceId(); |
1,662,491 | private static <T> ConstructorInjectionPoint<T> createConstructorInjectionPoint(ClassBinding<T> binding, Bean<T> bean, Collection<InjectionResolver> resolvers, BeanManager beanManager) {<NEW_LINE>final Class<T> bindingClass = binding.getImplementationType();<NEW_LINE>final AnnotatedType<T> annotatedType = beanManager.c... | , InjectionUtils.getInjectAnnotations(resolvers)); |
994,909 | private Map<?, String> initializeColors(BlameType blameType, List<AnnotatedLine> lines) {<NEW_LINE>ColorFactory colorFactory = new ColorFactory();<NEW_LINE>Map<?, String> colorMap;<NEW_LINE>if (BlameType.AGE == blameType) {<NEW_LINE>Set<Date> keys = new TreeSet<Date>(new Comparator<Date>() {<NEW_LINE><NEW_LINE>@Overrid... | keys.add(line.when); |
1,287,491 | private static Vector apply(CompLongLongVector v1, LongIntVector v2, Binary op) {<NEW_LINE>LongLongVector[] parts = v1.getPartitions();<NEW_LINE>Storage[] resParts = StorageSwitch.applyComp(v1, v2, op);<NEW_LINE>if (!op.isKeepStorage()) {<NEW_LINE>for (int i = 0; i < parts.length; i++) {<NEW_LINE>if (parts[i].getStorag... | get(subidx), 0)); |
613,329 | public void generateNormalAppearance() {<NEW_LINE>float lineWidth = getLineWidth();<NEW_LINE>PDAnnotationSquareCircle annotation = (PDAnnotationSquareCircle) getAnnotation();<NEW_LINE>PDAppearanceContentStream contentStream = null;<NEW_LINE>try {<NEW_LINE>contentStream = getNormalAppearanceAsContentStream();<NEW_LINE>b... | e.getMessage(), e); |
373,753 | public String executeCustomFormLogin(HttpClient httpclient, String url, String username, String password, String viewState, String[] cookies) throws Exception {<NEW_LINE>String methodName = "executeCustomFormLogin";<NEW_LINE>Log.info(logClass, methodName, "Submitting custom login form (POST) = " + url + ", username = ... | cookieHeader = getCookieHeader(response, cookie); |
1,447,858 | private Query createQueryInternal(ConvertingParameterAccessor accessor, boolean isCountQuery) {<NEW_LINE>MongoQueryCreator creator = new MongoQueryCreator(tree, accessor, context, isCountQuery ? false : isGeoNearQuery);<NEW_LINE>Query query = creator.createQuery();<NEW_LINE>if (isCountQuery) {<NEW_LINE>return query;<NE... | query.fields()::include); |
581,447 | public Dialog onCreateDialog(Bundle savedInstanceState) {<NEW_LINE>View view = View.inflate(getActivity(), R.layout.site_settings_format_dialog, null);<NEW_LINE>TextView txtTitle = view.findViewById(R.id.text_title);<NEW_LINE>TextView txtHelp = view.findViewById(R.id.text_help);<NEW_LINE>mEditCustomFormat = view.findVi... | (), Constants.URL_DATETIME_FORMAT_HELP)); |
1,739,507 | /*<NEW_LINE>* (non-Javadoc)<NEW_LINE>*<NEW_LINE>* @see<NEW_LINE>* com.sitewhere.grpc.service.DeviceManagementGrpc.DeviceManagementImplBase#<NEW_LINE>* removeDeviceGroupElements(com.sitewhere.grpc.service.<NEW_LINE>* GRemoveDeviceGroupElementsRequest, io.grpc.stub.StreamObserver)<NEW_LINE>*/<NEW_LINE>@Override<NEW_LINE>... | onNext(response.build()); |
149,841 | public boolean replaceEvent(GameEvent event, Ability source, Game game) {<NEW_LINE>PreventionEffectData preventionData = preventDamageAction(event, source, game);<NEW_LINE>this.used = true;<NEW_LINE>// only one use<NEW_LINE>this.discard();<NEW_LINE>if (preventionData.getPreventedDamage() > 0) {<NEW_LINE>UUID damageTarg... | " to " + permanent.getLogName()); |
23,863 | private ChaiProvider newProxyChaiProvider(final SessionLabel sessionLabel, final LdapProfile ldapProfile) throws PwmUnrecoverableException {<NEW_LINE>Objects.requireNonNull(ldapProfile, "ldapProfile must not be null");<NEW_LINE>try {<NEW_LINE>final ChaiProvider chaiProvider = LdapOperationsHelper.openProxyChaiProvider(... | = "unexpected error creating new proxy ldap connection: " + e.getMessage(); |
1,383,432 | private BeanReference createAuthenticationManager(Element element, ParserContext pc, ManagedList<BeanReference> authenticationProviders) {<NEW_LINE>String parentMgrRef = element.getAttribute(ATT_AUTHENTICATION_MANAGER_REF);<NEW_LINE>BeanDefinitionBuilder authManager = BeanDefinitionBuilder.rootBeanDefinition(ProviderMa... | new BeanComponentDefinition(amfb, amfbId)); |
684,322 | public GetQueueResult unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>GetQueueResult getQueueResult = new GetQueueResult();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth +... | JsonToken token = context.getCurrentToken(); |
1,301,445 | public int ladderLength(String beginWord, String endWord, List<String> wordList) {<NEW_LINE>words = new HashSet<>(wordList);<NEW_LINE>if (!words.contains(endWord)) {<NEW_LINE>return 0;<NEW_LINE>}<NEW_LINE>Queue<String> q1 = new ArrayDeque<>();<NEW_LINE>Queue<String> q2 = new ArrayDeque<>();<NEW_LINE>Map<String, Integer... | m1.put(beginWord, 0); |
277,388 | public void sendTransactionData() {<NEW_LINE>ConcurrentHashMap<String, ConcurrentHashMap<String, TransactionData>> transactions = getAndResetTransactions();<NEW_LINE>boolean hasData = false;<NEW_LINE>for (Map<String, TransactionData> entry : transactions.values()) {<NEW_LINE>for (TransactionData data : entry.values()) ... | ).append(CatConstants.SPLIT); |
1,805,461 | private Client buildClient() throws SQLException {<NEW_LINE>// if(props.containsKey("test")){ // used for integration tests<NEW_LINE>// return ESIntegTestCase.client();<NEW_LINE>// }else<NEW_LINE>try {<NEW_LINE>Settings.Builder settingsBuilder = Settings.settingsBuilder();<NEW_LINE>for (Object key : this.props.keySet()... | throw new SQLException("Unable to connect to database", t); |
934,908 | public void giveExecutePermissionToReadActionUsers(MongockTemplate mongoTemplate) {<NEW_LINE>final List<Action> actions = mongoTemplate.find(query(where("policies").exists(true)), Action.class);<NEW_LINE>for (final Action action : actions) {<NEW_LINE>Set<Policy> policies = action.getPolicies();<NEW_LINE>if (policies.si... | getPolicies().add(newExecuteActionPolicy); |
130,429 | public void analyze(Document doc, StreamSource src, Writer xrefOut) throws IOException {<NEW_LINE>JFieldBuilder jfbuilder = new JFieldBuilder();<NEW_LINE>try (ZipInputStream zis = new ZipInputStream(src.getStream())) {<NEW_LINE>ZipEntry entry;<NEW_LINE>while ((entry = zis.getNextEntry()) != null) {<NEW_LINE>String enam... | jfbuilder.write(QueryBuilder.FULL); |
1,048,887 | void cancelJoinRequest() throws GroupChangeFailedException, IOException {<NEW_LINE>Set<UUID> uuids = Collections.singleton(selfAci.uuid());<NEW_LINE>GroupChange signedGroupChange;<NEW_LINE>try {<NEW_LINE>signedGroupChange = commitCancelChangeWithConflictResolution(groupOperations.createRefuseGroupJoinRequest(uuids, fal... | .requireV2GroupProperties().getDecryptedGroup(); |
1,231,524 | protected BeanMetadataElement parseSource(Element element, ParserContext parserContext) {<NEW_LINE>BeanDefinitionBuilder builder = BeanDefinitionBuilder.genericBeanDefinition(JmsDestinationPollingSource.class);<NEW_LINE>String jmsTemplate = element.getAttribute(JmsParserUtils.JMS_TEMPLATE_ATTRIBUTE);<NEW_LINE>String de... | setValueIfAttributeDefined(builder, element, "extract-payload"); |
616,067 | private void reassignEarlyHolders8(Context context) {<NEW_LINE>ReflectUtil.field(Annotate.instance(context), TYPES_FIELD).set(this);<NEW_LINE>ReflectUtil.field(Attr.instance(context), TYPES_FIELD).set(this);<NEW_LINE>ReflectUtil.field(Check.instance(context), TYPES_FIELD).set(this);<NEW_LINE>ReflectUtil.field(DeferredA... | , TYPES_FIELD).set(this); |
1,712,270 | public DeleteInsertGraph visit(final ASTDeleteWhere node, final Object data) throws VisitorException {<NEW_LINE>// Collect construct triples<NEW_LINE>final GroupGraphPattern parentGP = graphPattern;<NEW_LINE>graphPattern = new GroupGraphPattern();<NEW_LINE>// inherit scope & context<NEW_LINE>graphPattern.setStatementPa... | StatementPatternNode sp = itr.next(); |
510,472 | private static boolean isInHeader(CompilationInfo info, ClassTree tree, int offset) {<NEW_LINE>CompilationUnitTree cut = info.getCompilationUnit();<NEW_LINE>SourcePositions sp = info.getTrees().getSourcePositions();<NEW_LINE>long lastKnownOffsetInHeader = sp.getStartPosition(cut, tree);<NEW_LINE>List<? extends Tree> im... | getTreeUtilities().tokensFor(tree); |
304,082 | private static Distribution buildPositionMergeDistribution(Table table, DistributionMode distributionMode) {<NEW_LINE>switch(distributionMode) {<NEW_LINE>case NONE:<NEW_LINE>return Distributions.unspecified();<NEW_LINE>case HASH:<NEW_LINE>if (table.spec().isUnpartitioned()) {<NEW_LINE>Expression[] clustering = new Expr... | ] { SPEC_ID, PARTITION, FILE_PATH }; |
1,633,495 | private // Otherwise, bounce off it and stop flying.<NEW_LINE>void onImpactWithBlock(BlockRayTraceResult rayTraceResult) {<NEW_LINE>// is the block weak enough for the boomerang to smash through it?<NEW_LINE>// the boomerang is modelled as a wooden axe for the purposes of tool effectiveness<NEW_LINE>BlockPos blockPos =... | blockState.getBlockHardness(world, blockPos); |
873,561 | public Mono<Void> filter(@NonNull final ServerWebExchange exchange, @NonNull final WebFilterChain chain) {<NEW_LINE>MediaType mediaType = exchange.getRequest().getHeaders().getContentType();<NEW_LINE>if (MediaType.MULTIPART_FORM_DATA.isCompatibleWith(mediaType)) {<NEW_LINE>ServerRequest serverRequest = ServerRequest.cr... | error(exchange, ShenyuResultEnum.PAYLOAD_TOO_LARGE); |
990,126 | private void optimizeOrderRange() {<NEW_LINE>TreeNode currentTreeNode = treeLeaf;<NEW_LINE>while (!(currentTreeNode instanceof SourceTreeNode)) {<NEW_LINE>if (currentTreeNode instanceof OrderGlobalTreeNode) {<NEW_LINE>OrderGlobalTreeNode orderGlobalTreeNode = OrderGlobalTreeNode.class.cast(currentTreeNode);<NEW_LINE><M... | TreeNode orderInputNode = orderGlobalTreeNode.getInputNode(); |
431,259 | protected void onStart() {<NEW_LINE>super.onStart();<NEW_LINE>organizerViewModel.setLocalDatePreferenceAction();<NEW_LINE>organizerViewModel.getOrganizer().<MASK><NEW_LINE>organizerViewModel.getLogoutAction().observe(this, aVoid -> this.onLogout());<NEW_LINE>organizerViewModel.getLocalDatePreferenceAction().observe(thi... | observe(this, this::showOrganizer); |
1,049,013 | public Map<String, Map<String, PropertyMapping>> mappingsForFunction() {<NEW_LINE>Map<String, Map<String, PropertyMapping>> ret = new HashMap<>();<NEW_LINE>Map<String, PropertyMapping> map = new HashMap<>();<NEW_LINE>val strideMapping = PropertyMapping.builder().tfAttrName("strides").onnxAttrName("strides").build();<NE... | map.put("pH", paddingWidthHeight); |
362,001 | private Expression arrowFunction(final long startToken, final int functionLine, final Expression paramListExpr) {<NEW_LINE>// caller needs to check that there's no LineTerminator between parameter list and arrow<NEW_LINE>assert type != ARROW || checkNoLineTerminator();<NEW_LINE>expect(ARROW);<NEW_LINE>final long functi... | functionNode.setFlag(FunctionNode.IS_ANONYMOUS); |
1,020,601 | public FieldLevelEncryptionConfig unmarshall(StaxUnmarshallerContext context) throws Exception {<NEW_LINE>FieldLevelEncryptionConfig fieldLevelEncryptionConfig = new FieldLevelEncryptionConfig();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>if (context.isStartOfDocument())<NEW_LINE>targetDepth... | int originalDepth = context.getCurrentDepth(); |
242,606 | public static void initBuiltins(FunctionSet functionSet) {<NEW_LINE>for (Type fromType : Type.getSupportedTypes()) {<NEW_LINE>if (fromType.isNull()) {<NEW_LINE>continue;<NEW_LINE>}<NEW_LINE>for (Type toType : Type.getSupportedTypes()) {<NEW_LINE>if (toType.isNull() || disableRegisterCastingFunction(fromType, toType)) {... | .isDecimalV2() ? "DecimalV2Operators" : "CastFunctions"; |
1,140,725 | public synchronized void addServant(Ice.Object servant, Ice.Identity ident, String facet) {<NEW_LINE>// Must not be called after destruction.<NEW_LINE>assert (_instance != null);<NEW_LINE>if (facet == null) {<NEW_LINE>facet = "";<NEW_LINE>}<NEW_LINE>java.util.Map<String, Ice.Object> m = _servantMapMap.get(ident);<NEW_L... | "", _instance.toStringMode()); |
720,879 | public BaseHttpClientInvocation invokeClient(Object[] theArgs) throws InternalErrorException {<NEW_LINE>assert (myQueryName == null || ((theArgs != null ? theArgs.length : 0) == getParameters().size())) : "Wrong number of arguments: " + (theArgs != null ? theArgs.length : "null");<NEW_LINE>Map<String, List<String>> que... | [idx], queryStringArgs, null); |
860,905 | protected void ended(GENASubscription subscription, CancelReason reason, UpnpResponse response) {<NEW_LINE>final <MASK><NEW_LINE>if (service != null) {<NEW_LINE>final ServiceId serviceId = service.getServiceId();<NEW_LINE>final Device device = service.getDevice();<NEW_LINE>if (device != null) {<NEW_LINE>final Device de... | Service service = subscription.getService(); |
1,350,788 | public static void main(String[] args) throws Throwable {<NEW_LINE>OSS ossClient = new OSSClientBuilder().build(endpoint, accessKeyId, accessKeySecret);<NEW_LINE>try {<NEW_LINE>// Put object form file with traffic limit<NEW_LINE>InputStream inputStream = new FileInputStream("<yourlocalFile>");<NEW_LINE>PutObjectRequest... | "Error Message: " + oe.getErrorMessage()); |
1,375,323 | public void onSuccess(@Nullable List<Map<String, TsValue>> result) {<NEW_LINE>missingTelemetryFutures.forEach((key, value) -> {<NEW_LINE>try {<NEW_LINE>key.getLatest().get(EntityKeyType.TIME_SERIES).putAll(value.get());<NEW_LINE>} catch (InterruptedException | ExecutionException e) {<NEW_LINE>log.warn("[{}][{}] Failed ... | ctx.getSessionId(), update); |
854,023 | public void initSubDevices() {<NEW_LINE>ModelFactory factory = ModelFactory.eINSTANCE;<NEW_LINE>AccelerometerDirection x = factory.createAccelerometerDirection();<NEW_LINE>x.setDirection(AccelerometerCoordinate.X);<NEW_LINE>x.setUid(getUid());<NEW_LINE>String subIdX = "x";<NEW_LINE>logger.debug("{} addSubDevice {}", Lo... | temperature.setUid(getUid()); |
1,153,769 | final DeleteAppAssessmentResult executeDeleteAppAssessment(DeleteAppAssessmentRequest deleteAppAssessmentRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteAppAssessmentRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | awsRequestMetrics.endEvent(Field.RequestMarshallTime); |
334,688 | final DetachLoadBalancersResult executeDetachLoadBalancers(DetachLoadBalancersRequest detachLoadBalancersRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(detachLoadBalancersRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequest... | (super.beforeMarshalling(detachLoadBalancersRequest)); |
1,240,919 | private void parseTopologyConfig(final JsonNode allTopologies, final Map<String, DeliveryService> deliveryServiceMap, final CacheRegister cacheRegister) {<NEW_LINE>final Map<String, List<String>> topologyMap = new HashMap<>();<NEW_LINE>final Map<String, List<String>> statMap = new HashMap<>();<NEW_LINE>final String tld... | remap = ds.getRemap(pattern); |
1,361,028 | public void writeGuestbookResponseRecord(GuestbookResponse guestbookResponse) {<NEW_LINE>try {<NEW_LINE>CreateGuestbookResponseCommand cmd = new CreateGuestbookResponseCommand(dvRequestService.getDataverseRequest(), guestbookResponse, guestbookResponse.getDataset());<NEW_LINE>commandEngine.submit(cmd);<NEW_LINE>Dataset... | getDataFile().getId()); |
138,363 | // Internal use only<NEW_LINE>public MethodBinding findMethodForArray(ArrayBinding receiverType, char[] selector, TypeBinding[] argumentTypes, InvocationSite invocationSite) {<NEW_LINE>TypeBinding leafType = receiverType.leafComponentType();<NEW_LINE>if (leafType instanceof ReferenceBinding) {<NEW_LINE>if (!((Reference... | selector, argumentTypes, ProblemReasons.NoSuchMethodOnArray); |
1,096,880 | public ModeInfo read(int miCol, int miRow, int blSz, VPXBooleanDecoder decoder, DecodingContext c) {<NEW_LINE>int segmentId = 0;<NEW_LINE>if (c.isSegmentationEnabled() && c.isUpdateSegmentMap())<NEW_LINE>segmentId = readSegmentId(decoder, c);<NEW_LINE>boolean skip = true;<NEW_LINE>if (!c.isSegmentFeatureActive(segmentI... | miRow, blSz, decoder, c); |
272,125 | private void sendDocsumsRequest(int nodeId, List<FastHit> hits, byte[] payload, Result result) {<NEW_LINE>Client.NodeConnection node = resourcePool.getConnection(nodeId);<NEW_LINE>if (node == null) {<NEW_LINE>String error = "Could not fill hits from unknown node " + nodeId;<NEW_LINE>receive(Client.ResponseOrError.fromE... | (ErrorMessage.createEmptyDocsums(error)); |
374,419 | protected ImmutableListMultimap<String, SysConfigEntryValue> retrieveSysConfigEntryValues() {<NEW_LINE>final String sql = "SELECT Name, Value, AD_Client_ID, AD_Org_ID FROM AD_SysConfig" + " WHERE IsActive='Y'" + " ORDER BY Name, AD_Client_ID, AD_Org_ID";<NEW_LINE>PreparedStatement pstmt = null;<NEW_LINE>ResultSet rs = ... | name = rs.getString("Name"); |
987,882 | //<NEW_LINE>ModelChange(timings = { ModelValidator.TYPE_BEFORE_NEW, ModelValidator.TYPE_BEFORE_CHANGE }, ifColumnsChanged = I_C_RfQResponseLineQty.COLUMNNAME_DatePromised)<NEW_LINE>public void validateDatePromised(final I_C_RfQResponseLineQty rfqResponseLineQty) {<NEW_LINE>final Timestamp datePromised = rfqResponseLine... | dateWorkStart + " - " + dateWorkComplete + ")"); |
934,704 | protected void extractSimpleRule(ExtractValueRequest extractValueRequest, Property property, ObjectMapper mapper, MVELToDataWrapperTranslator translator) {<NEW_LINE>Property jsonProperty;<NEW_LINE>if (extractValueRequest.getRequestedValue() != null) {<NEW_LINE>if (extractValueRequest.getRequestedValue() instanceof Stri... | getProps().add(jsonProperty); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.