idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
1,142,646 | public void apply(float interpolatedTime, Matrix matrix, int childWidth, int childHeight, float anchorX, float anchorY) {<NEW_LINE>anchorX = anchorX == DEFAULT_ANCHOR_VALUE ? this.anchorX : anchorX;<NEW_LINE>anchorY = anchorY == DEFAULT_ANCHOR_VALUE ? this.anchorY : anchorY;<NEW_LINE>switch(type) {<NEW_LINE>case TYPE_S... | interpolatedTime * translateX, interpolatedTime * translateY); |
569,274 | public ItemStack clicked(int id, int dragType, ClickType clickType, Player player) {<NEW_LINE>Slot slot = id < 0 ? null : this.slots.get(id);<NEW_LINE>if (!(slot instanceof IESlot.ItemHandlerGhost))<NEW_LINE>return super.clicked(id, dragType, clickType, player);<NEW_LINE>// Spooky Ghost Slots!!!!<NEW_LINE>ItemStack sta... | ItemStack stackSlot = slot.getItem(); |
1,736,482 | public HttpRequestContext handleStart(C carrier, Q request) {<NEW_LINE>checkNotNull(carrier, "carrier");<NEW_LINE>checkNotNull(request, "request");<NEW_LINE>SpanBuilder spanBuilder = null;<NEW_LINE>String spanName = getSpanName(request, extractor);<NEW_LINE>// de-serialize the context<NEW_LINE>SpanContext spanContext =... | tracer.spanBuilderWithRemoteParent(spanName, spanContext); |
504,599 | public String sqlAD_getUnsequencedDocuments(String vendorName, String catalogName, String schemaName) {<NEW_LINE>// table name<NEW_LINE>String tableName = "AD_Table";<NEW_LINE>// column names<NEW_LINE>ArrayList<String> columnNames = new ArrayList<String>();<NEW_LINE>columnNames.add("TableName");<NEW_LINE>// aliases<NEW... | aliasNames, conditions, sortColumns, false); |
543,923 | public void spawnEntity() {<NEW_LINE>AddEntityPacket addEntityPacket = new AddEntityPacket();<NEW_LINE>addEntityPacket.setIdentifier(definition.identifier());<NEW_LINE>addEntityPacket.setRuntimeEntityId(geyserId);<NEW_LINE>addEntityPacket.setUniqueEntityId(geyserId);<NEW_LINE>addEntityPacket.setPosition(position);<NEW_... | apply(addEntityPacket.getMetadata()); |
1,605,964 | protected static TSSTransportMechConfig extractSSL(Map<String, Object> sslConfigProps, Map<OptionsKey, List<TransportAddress>> addrMap) {<NEW_LINE>TSSSSLTransportConfig sslConfig = new TSSSSLTransportConfig();<NEW_LINE>sslConfig.setSupports(extractAssociationOptions((String[]) sslConfigProps.get(SUPPORTS)));<NEW_LINE>s... | sslConfigProps.get(REQUIRES))); |
342,154 | public String createWebhook(@RequestParam String targetUrl, @RequestParam(required = false) String type, @RequestParam Boolean json, @RequestParam Set<String> events, HttpServletRequest req, Model model) {<NEW_LINE>Profile authUser = utils.getAuthUser(req);<NEW_LINE>if (Utils.isValidURL(targetUrl) && utils.isAdmin(auth... | (events.contains("delete")); |
1,651,541 | private boolean addNewReplicaInfo(ReplicaId replicaId) {<NEW_LINE>boolean additionResult = true;<NEW_LINE>DataNodeConfig dataNodeConfig = getDataNodeConfig();<NEW_LINE>String partitionName = replicaId<MASK><NEW_LINE>DataNodeConfig.ReplicaConfig replicaConfigToAdd = new DataNodeConfig.ReplicaConfig(replicaId.getCapacity... | .getPartitionId().toPathString(); |
947,601 | public static void doArt() {<NEW_LINE>if (artDone)<NEW_LINE>return;<NEW_LINE>artDone = true;<NEW_LINE>Logger.info(com.dotcms.util.AsciiArt.class, " ");<NEW_LINE>Logger.info(com.dotcms.util.AsciiArt.class, " ... | util.AsciiArt.class, " "); |
1,834,705 | private void webSocket(WebSocketConnectOptions connectOptions, PromiseInternal<WebSocket> promise) {<NEW_LINE>ProxyOptions proxyOptions = getProxyOptions(connectOptions.getProxyOptions());<NEW_LINE>int port = getPort(connectOptions);<NEW_LINE>String host = getHost(connectOptions);<NEW_LINE>SocketAddress addr = SocketAd... | (Http1xClientConnection) ar.result(); |
342,324 | protected IndexCandidate createIndexCandidate(final IndexType index, final MultiCondition<JanusGraphElement> conditions, IndexSerializer serializer) {<NEW_LINE>final Set<Condition> subCover = new HashSet<>(1);<NEW_LINE>// Check that this index actually applies in case of a schema constraint<NEW_LINE>if (index.hasSchema... | > labels = equalCon.getValue(); |
730,485 | /*<NEW_LINE>* Creates properties for specific database<NEW_LINE>*/<NEW_LINE>private static void modifyDataSourcePropsForDatabase(List<DataSource> datasources, ServerConfiguration cloneConfig, LibertyServer serv, JdbcDatabaseContainer<?> cont) throws Exception {<NEW_LINE>// Get database type<NEW_LINE>DatabaseContainerTy... | setPassword(cont.getPassword()); |
394,222 | public void load(final String name, final OType[] keyTypes, final boolean nullKeyIsSupported, final OEncryption encryption, final OHashFunction<K> keyHashFunction, final OBinarySerializer<K> keySerializer, final OBinarySerializer<V> valueSerializer) {<NEW_LINE>acquireExclusiveLock();<NEW_LINE>try {<NEW_LINE>this.keyHas... | KeyHashCodeComparator<>(this.keyHashFunction); |
645,475 | static ProcStat parseWithSplits(String cat) throws ParseException {<NEW_LINE>ProcStat stat = new ProcStat();<NEW_LINE>if (!TextUtils.isEmpty(cat)) {<NEW_LINE>int index = cat.indexOf(")");<NEW_LINE>if (index <= 0)<NEW_LINE>throw new IllegalStateException(cat + " has not ')'");<NEW_LINE>String prefix = cat.substring(0, i... | + "\nutime: " + splits[12]); |
1,102,199 | protected static DLHandler loadNFILibrary(PythonContext context, NFIBackend backendType, String name, int flags) {<NEW_LINE>CompilerAsserts.neverPartOfCompilation();<NEW_LINE>String src;<NEW_LINE>if (PString.length(name) > 0) {<NEW_LINE>src = PythonUtils.format("%sload (%s) \"%s\"", backendType.withClause<MASK><NEW_LIN... | , flagsToString(flags), name); |
1,467,217 | private boolean updateIfNecessary() {<NEW_LINE>if (steps > lastSaveSteps + SAVE_OFFSET_STEPS || (steps > 0 && System.currentTimeMillis() > lastSaveTime + SAVE_OFFSET_TIME)) {<NEW_LINE>if (BuildConfig.DEBUG)<NEW_LINE>Logger.log("saving steps: steps=" + steps + " lastSave=" + lastSaveSteps + " lastSaveTime=" + new Date(l... | "pauseCount", steps).commit(); |
21,827 | public TableMetadataUnit toUnit(Record record) {<NEW_LINE>RowGroupsRecord rowGroupsRecord = (RowGroupsRecord) record;<NEW_LINE>return TableMetadataUnit.builder().storagePlugin(rowGroupsRecord.getStoragePlugin()).workspace(rowGroupsRecord.getWorkspace()).tableName(rowGroupsRecord.getTableName()).metadataKey(rowGroupsRec... | getAdditionalMetadata()).build(); |
693,658 | public void createControl(Composite composite) {<NEW_LINE>Composite settingsGroup = new Composite(composite, SWT.NONE);<NEW_LINE>settingsGroup.setLayout(new GridLayout(1, false));<NEW_LINE>settingsGroup.setLayoutData(new GridData(GridData.FILL_BOTH));<NEW_LINE>Composite addrGroup = UIUtils.createControlGroup(settingsGr... | createControlLabel(addrGroup, HANAMessages.label_instance); |
1,592,118 | public // O(V * (V + E))<NEW_LINE>void computeProperties(int[] vertices) {<NEW_LINE>diameter = 0;<NEW_LINE>radius = Integer.MAX_VALUE;<NEW_LINE>center = 0;<NEW_LINE>for (int vertex = 0; vertex < vertices.length; vertex++) {<NEW_LINE>BreadthFirstPaths breadthFirstPaths = new BreadthFirstPaths(graph, vertices[vertex]);<N... | , breadthFirstPaths.distTo(otherVertex)); |
1,754,155 | private void validateTupleValue(TomlNode value, String variableName, TupleType tupleType) {<NEW_LINE>value = getValueFromKeyValueNode(value);<NEW_LINE>if (!checkEffectiveTomlType(value.kind(), tupleType, variableName)) {<NEW_LINE>throwTypeIncompatibleError(value, variableName, tupleType);<NEW_LINE>}<NEW_LINE>visitedNod... | > tupleElementTypes = tupleType.getTupleTypes(); |
1,143,312 | public void call(String[] args) throws CmdException {<NEW_LINE>// validate input<NEW_LINE>if (args.length < 1)<NEW_LINE>throw new CmdSyntaxError();<NEW_LINE>if (!MC.player.getAbilities().creativeMode)<NEW_LINE>throw new CmdError("Creative mode only.");<NEW_LINE>// id/name<NEW_LINE>Item item = getItem(args[0]);<NEW_LINE... | , 2, args.length)); |
665,597 | private void add() {<NEW_LINE>if (fileChooser == null) {<NEW_LINE>fileChooser = new GhidraFileChooser(panel);<NEW_LINE>fileChooser.setMultiSelectionEnabled(allowMultiFileSelection);<NEW_LINE>fileChooser.setFileSelectionMode(fileChooserMode);<NEW_LINE>fileChooser.setTitle(title);<NEW_LINE>fileChooser.setApproveButtonToo... | pathModel.addPath(p, addToTop); |
605,041 | public boolean createDirectory(PathFragment path) throws IOException {<NEW_LINE>File file = getIoFile(path);<NEW_LINE>if (file.mkdir()) {<NEW_LINE>return true;<NEW_LINE>}<NEW_LINE>if (fileIsSymbolicLink(file)) {<NEW_LINE><MASK><NEW_LINE>}<NEW_LINE>if (file.isDirectory()) {<NEW_LINE>// directory already existed<NEW_LINE... | throw new IOException(path + ERR_FILE_EXISTS); |
1,407,806 | protected void computeRealHumanResourceCost(OperationOrder operationOrder, int priority, int bomLevel, CostSheetLine parentCostSheetLine, LocalDate previousCostSheetDate) throws AxelorException {<NEW_LINE>if (!appProductionService.isApp("production") || !appProductionService.getAppProduction().getManageBusinessProducti... | priority, bomLevel, parentCostSheetLine, previousCostSheetDate); |
537,747 | public List<String> expendGroupRoleToGroup(List<String> groupList, List<String> roleList) throws Exception {<NEW_LINE>List<String> groupIds = new ArrayList<>();<NEW_LINE>List<String> expendGroupIds = new ArrayList<>();<NEW_LINE>if (ListTools.isNotEmpty(groupList)) {<NEW_LINE>for (String s : groupList) {<NEW_LINE>Group ... | group().pick(s); |
922,420 | public void onCloseActivityFinal(final Runnable run) {<NEW_LINE>stopTimer();<NEW_LINE>TTSEngine.get().stop();<NEW_LINE>TTSNotification.hideNotification();<NEW_LINE>Safe.run(new Runnable() {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void run() {<NEW_LINE>isClosed = true;<NEW_LINE>if (codeDocument != null) {<NEW_LINE>... | "_PAGE", "SAVE", getCurentPage()); |
501,577 | private String cleanFormat(String format) {<NEW_LINE>// Remove unnecessary d & M if resolution is too low<NEW_LINE>if (currentResolution.getCalendarField() < Resolution.DAY.getCalendarField()) {<NEW_LINE>format = format.replaceAll("d", "");<NEW_LINE>}<NEW_LINE>if (currentResolution.getCalendarField() < Resolution.MONTH... | format.replaceAll("//", "/"); |
922,750 | protected void copyMailConfig(ProcessEngineConfigurationImpl flowable6Configuration, org.activiti.engine.impl.cfg.ProcessEngineConfigurationImpl flowable5Configuration) {<NEW_LINE>flowable5Configuration.setMailServerDefaultFrom(flowable6Configuration.getMailServerDefaultFrom());<NEW_LINE>flowable5Configuration.setMailS... | setMailServerPassword(flowable6Configuration.getMailServerPassword()); |
1,050,012 | public GetStorageStatsAnswer GetStorageStats(GetStorageStatsCommand cmd) {<NEW_LINE>String uuid = cmd.getStorageId();<NEW_LINE>TransactionLegacy txn = <MASK><NEW_LINE>try {<NEW_LINE>txn.start();<NEW_LINE>if (uuid == null) {<NEW_LINE>String secUrl = cmd.getSecUrl();<NEW_LINE>MockSecStorageVO secondary = _mockSecStorageD... | TransactionLegacy.open(TransactionLegacy.SIMULATOR_DB); |
1,787,989 | public static String formatDelay(Number data) {<NEW_LINE>if (data == null) {<NEW_LINE>return StringUtils.EMPTY;<NEW_LINE>}<NEW_LINE><MASK><NEW_LINE>if (t < 0) {<NEW_LINE>return String.valueOf(t);<NEW_LINE>}<NEW_LINE>int hour = 0;<NEW_LINE>int minute = 0;<NEW_LINE>while (t >= 60 * 60 * 1000) {<NEW_LINE>hour++;<NEW_LINE>... | long t = data.longValue(); |
1,163,899 | final AssociateRoutingProfileQueuesResult executeAssociateRoutingProfileQueues(AssociateRoutingProfileQueuesRequest associateRoutingProfileQueuesRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(associateRoutingProfileQueuesRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionC... | (super.beforeMarshalling(associateRoutingProfileQueuesRequest)); |
1,671,653 | public List<KeeperContainerInfoModel> findAllInfos() {<NEW_LINE>List<KeepercontainerTbl> baseInfos = findContainerBaseInfos();<NEW_LINE>HashMap<Long, KeeperContainerInfoModel> containerInfoMap = new HashMap<>();<NEW_LINE>baseInfos.forEach(baseInfo -> {<NEW_LINE>KeeperContainerInfoModel model = new KeeperContainerInfoMo... | setKeeperCount(load.getCount()); |
865,517 | public static DescribeLoadBalancersResponse unmarshall(DescribeLoadBalancersResponse describeLoadBalancersResponse, UnmarshallerContext _ctx) {<NEW_LINE>describeLoadBalancersResponse.setRequestId(_ctx.stringValue("DescribeLoadBalancersResponse.RequestId"));<NEW_LINE>describeLoadBalancersResponse.setPageNumber(_ctx.inte... | = new ArrayList<Tag>(); |
1,371,112 | private static String[] calcWords(final String prefix, Editor editor) {<NEW_LINE>final Matcher matcher = NameUtil.buildMatcher(prefix, 0, true, true);<NEW_LINE>final Set<String> words <MASK><NEW_LINE>CharSequence chars = editor.getDocument().getCharsSequence();<NEW_LINE>IdTableBuilding.scanWords(new IdTableBuilding.Sca... | = new HashSet<String>(); |
574,490 | default <K1, K2, R1, R> ImmutableMap<K2, R> forEach2(Function<? super Tuple2<K, V>, ? extends Iterable<Tuple2<K1, R1>>> iterable1, BiFunction<? super Tuple2<K, V>, ? super Tuple2<K1, R1>, Boolean> filterFunction, BiFunction<? super Tuple2<K, V>, ? super Tuple2<K1, R1>, ? extends Tuple2<K2, R>> yieldingFunction) {<NEW_L... | Tuple.tuple(a1, b1); |
68,484 | // initDatabase<NEW_LINE>private void initDatabase(String selected, int index) {<NEW_LINE>if (index < 0 || index >= DBTYPE.length)<NEW_LINE>log.warning("DatabaseType Index invalid: " + index);<NEW_LINE>else if (m_databaseConfig[index] == null) {<NEW_LINE>log.warning("DatabaseType Config missing: " + DBTYPE[index]);<NEW... | [index].discoverDatabases(selected); |
531,341 | private STNode parseXMLDeclRhs(STNode xmlnsKeyword, STNode namespaceUri, boolean isModuleVar) {<NEW_LINE>STNode asKeyword = STNodeFactory.createEmptyNode();<NEW_LINE>STNode namespacePrefix = STNodeFactory.createEmptyNode();<NEW_LINE>switch(peek().kind) {<NEW_LINE>case AS_KEYWORD:<NEW_LINE>asKeyword = parseAsKeyword();<... | namespaceUri, asKeyword, namespacePrefix, semicolon); |
956,603 | /*<NEW_LINE>We would prefer to make shared fields private, but this doesn't work in the following case:<NEW_LINE><NEW_LINE>class BaseSpec {<NEW_LINE>public sharedInstance<NEW_LINE>private sharedField = 5<NEW_LINE><NEW_LINE>def sharedFieldGetter() { sharedInstance.sharedField }<NEW_LINE>}<NEW_LINE><NEW_LINE>class Derive... | getAst(), Opcodes.ACC_PROTECTED); |
527,323 | protected void doParse(Element element, ParserContext parserContext, BeanDefinitionBuilder builder) {<NEW_LINE>String connectionFactoryRef = element.getAttribute(CONNECTION_FACTORY_ATTRIBUTE);<NEW_LINE>// At least one of 'templateRef' or 'connectionFactoryRef' attribute must be set.<NEW_LINE>if (!StringUtils.hasText(co... | setValueIfAttributeDefined(builder, element, IGNORE_DECLARATION_EXCEPTIONS); |
455,844 | public void execute(IngestDocument ingestDocument, BiConsumer<IngestDocument, Exception> handler) {<NEW_LINE>final boolean matches;<NEW_LINE>try {<NEW_LINE>matches = evaluate(ingestDocument);<NEW_LINE>} catch (Exception e) {<NEW_LINE>handler.accept(null, e);<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (matches) {<NEW_LINE>... | handler.accept(result, null); |
1,641,036 | // this saves an existing set that the user has edited:<NEW_LINE>public void saveSet(ActionEvent ae) {<NEW_LINE>OAISet oaiSet = getSelectedSet();<NEW_LINE>if (oaiSet == null) {<NEW_LINE>// TODO:<NEW_LINE>// tell the user somehow that the set cannot be saved, and advise<NEW_LINE>// them to save the settings they have en... | oaiSet.getSpec()))); |
677,151 | public okhttp3.Call readNamespacedEndpointSliceCall(String name, String namespace, String pretty, final ApiCallback _callback) throws ApiException {<NEW_LINE>Object localVarPostBody = null;<NEW_LINE>// create path and map variables<NEW_LINE>String localVarPath = "/apis/discovery.k8s.io/v1/namespaces/{namespace}/endpoin... | localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); |
998,644 | public void run(RegressionEnvironment env) {<NEW_LINE>// Dimension-provided<NEW_LINE>//<NEW_LINE><MASK><NEW_LINE>env.tryInvalidCompile("select new double[1, 2, 3] from SupportBean", "Incorrect syntax near ',' expecting a right angle bracket ']'");<NEW_LINE>env.tryInvalidCompile("select new double['a'] from SupportBean"... | env.tryInvalidCompile("select new double[] from SupportBean", "Incorrect syntax near 'from' (a reserved keyword) expecting a left curly bracket '{' but found 'from' at line 1 column 20"); |
1,256,288 | public void run(RegressionEnvironment env) {<NEW_LINE>RegressionPath path = new RegressionPath();<NEW_LINE>String stmtOneText = "@name('l1') @public insert into StreamA select nested.* from SupportBeanComplexProps as s0";<NEW_LINE>env.compileDeploy(stmtOneText, path).addListener("l1");<NEW_LINE>env.assertStatement("l1"... | assertEqualsNew("l2", "nestedValue", "nestedValue"); |
505,291 | protected void decodeAZHave(AZHave have) {<NEW_LINE>final int[] pieceNumbers = have.getPieceNumbers();<NEW_LINE>have.destroy();<NEW_LINE>if (closing) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>if (peerHavePieces == null) {<NEW_LINE>peerHavePieces = new BitFlags(nbPieces);<NEW_LINE>}<NEW_LINE>boolean send_interested = false... | havePiece(pieceNumber, pieceLength, this); |
1,199,639 | protected void fixGlobalElementNames() {<NEW_LINE>// clear unique names map<NEW_LINE>namesMap.clear();<NEW_LINE>// create buckets<NEW_LINE>HashMap<GlobalElement, java.util.List<ElementReference>> erefMap = new HashMap<GlobalElement, java.util.List<ElementReference>>();<NEW_LINE>for (Entry<Integer, java.util.List<Object... | erefs = erefMap.get(ge); |
860,160 | public Collection<WildflyWebModuleNode> listWebModules(Lookup lookup) throws IOException {<NEW_LINE>try {<NEW_LINE>WildflyDeploymentFactory.WildFlyClassLoader cl = WildflyDeploymentFactory.getInstance().getWildFlyClassLoader(ip);<NEW_LINE>List<WildflyWebModuleNode> modules = new ArrayList<>();<NEW_LINE>// ModelNode<NEW... | application), SUBSYSTEM), WEB_SUBSYSTEM); |
377,732 | public void read(org.apache.thrift.protocol.TProtocol iprot, invalidateConditionalUpdate_args struct) throws org.apache.thrift.TException {<NEW_LINE>org.<MASK><NEW_LINE>iprot.readStructBegin();<NEW_LINE>while (true) {<NEW_LINE>schemeField = iprot.readFieldBegin();<NEW_LINE>if (schemeField.type == org.apache.thrift.prot... | apache.thrift.protocol.TField schemeField; |
997,517 | protected void doPost(HttpServletRequest request, HttpServletResponse response) throws IOException {<NEW_LINE>TriggerSmartContract.Builder build = TriggerSmartContract.newBuilder();<NEW_LINE>TransactionExtention.Builder trxExtBuilder = TransactionExtention.newBuilder();<NEW_LINE>Return.Builder retBuilder = Return.newBu... | visible = Util.getVisiblePost(contract); |
935,466 | public static String toCSVLine(AuditEvent auditEvent, boolean isTrackingLocationsEnabled, boolean isTrackingChangesEnabled, boolean isTrackingChangesReasonEnabled) {<NEW_LINE>FormIndex formIndex = auditEvent.getFormIndex();<NEW_LINE>AuditEvent.AuditEventType auditEventType = auditEvent.getAuditEventType();<NEW_LINE>lon... | long end = auditEvent.getEnd(); |
440,637 | private void createFolder(final File folder2Create, final String name) throws IOException {<NEW_LINE>boolean isSupported = new FileInfo(folder2Create).isSupportedFile();<NEW_LINE>ProvidedExtensions extensions = getProvidedExtensions();<NEW_LINE>if (!isSupported) {<NEW_LINE>extensions.createFailure(this, folder2Create.g... | getName(), getPath()); |
106,415 | protected void subAppend(E event) {<NEW_LINE>if (!isStarted()) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>// this step avoids LBCLASSIC-139<NEW_LINE>if (event instanceof DeferredProcessingAware) {<NEW_LINE>((DeferredProcessingAware) event).prepareForDeferredProcessing();<NEW_LINE>}<NEW_LINE>// the synchroniz... | this.encoder.encode(event); |
1,222,984 | public Dimension preferredLayoutSize(Container parent) {<NEW_LINE>Insets insets = parent.getInsets();<NEW_LINE>int n = parent.getComponentCount();<NEW_LINE>computeComponentSize(parent);<NEW_LINE>int numRows = 1;<NEW_LINE>int numCols = 1;<NEW_LINE>if (orientation == ROW) {<NEW_LINE>int width = Math.max(maxSize - insets.... | n + numCols - 1) / numCols; |
1,068,026 | public int compareTo(append_batch_args other) {<NEW_LINE>if (!getClass().equals(other.getClass())) {<NEW_LINE>return getClass().getName().compareTo(other.getClass().getName());<NEW_LINE>}<NEW_LINE>int lastComparison = 0;<NEW_LINE>lastComparison = java.lang.Boolean.valueOf(isSetMid()).compareTo(other.isSetMid());<NEW_LI... | compareTo(other.isSetBatch()); |
1,137,775 | final SimulatePrincipalPolicyResult executeSimulatePrincipalPolicy(SimulatePrincipalPolicyRequest simulatePrincipalPolicyRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(simulatePrincipalPolicyRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();... | SimulatePrincipalPolicyResult>(new SimulatePrincipalPolicyResultStaxUnmarshaller()); |
492,445 | private static img createWorkflowImage(String name, int activeNode, String js_command, boolean pressed) {<NEW_LINE><MASK><NEW_LINE>imgName.append("WF");<NEW_LINE>imgName.append(".gif");<NEW_LINE>//<NEW_LINE>img img = new img(MobileEnv.getImageDirectory(imgName.toString()), name);<NEW_LINE>if (!(imgName.toString()).star... | StringBuffer imgName = new StringBuffer(name); |
1,362,665 | private void doPrepareInUI() {<NEW_LINE>//<NEW_LINE>// Get the root pane container and window.<NEW_LINE>final RootPaneContainer rootPaneContainer = findRootPaneContainer(parentComponent);<NEW_LINE>if (rootPaneContainer == null) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>window = findWindow(rootPaneContainer);<NEW_LINE>if (... | glassPane = MetasfreshGlassPane.getOrNull(rootPaneContainer); |
1,663,662 | public void run() {<NEW_LINE>try {<NEW_LINE>Document doc = Http.url(url).cookies(cookies).get();<NEW_LINE>// Find image<NEW_LINE>Elements donwloadLink = doc.select("div.alt1 b a[href^=//d.facdn.net/]");<NEW_LINE>if (donwloadLink.size() == 0) {<NEW_LINE>logger.warn("Could not download " + this.url);<NEW_LINE>return;<NEW... | fileNameSplit[fileNameSplit.length - 1]; |
142,488 | private void initEGL() {<NEW_LINE>mEGL = (EGL10) EGLContext.getEGL();<NEW_LINE>// Get EGLDisplay and initialize display connection<NEW_LINE>mEGLDisplay = mEGL.eglGetDisplay(EGL10.EGL_DEFAULT_DISPLAY);<NEW_LINE>if (mEGLDisplay == EGL10.EGL_NO_DISPLAY) {<NEW_LINE>throw new RuntimeException("eglGetDisplay failed " + GLUti... | ] configs = new EGLConfig[1]; |
327,488 | final CreateIpamPoolResult executeCreateIpamPool(CreateIpamPoolRequest createIpamPoolRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createIpamPoolRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.... | awsRequestMetrics.startEvent(Field.RequestMarshallTime); |
713,115 | private static boolean matchList(Thread thread, Runnable target, List<String> list) {<NEW_LINE>return Stream.concat(Stream.of(JAVA_LANG_PKG), list.stream()).anyMatch(s -> {<NEW_LINE>Class<?> clazz = (target == null ? thread : target).getClass();<NEW_LINE>// Java code could start a thread by passing a `target` Runnable ... | Package pkg = clazz.getPackage(); |
1,818,815 | public UUID rotateCerts(CertsRotateParams requestParams, Customer customer, Universe universe) {<NEW_LINE>log.debug("rotateCerts called with rootCA: {}", (requestParams.rootCA != null) ? requestParams.rootCA.toString() : "NULL");<NEW_LINE>// Verify request params<NEW_LINE>requestParams.verifyParams(universe);<NEW_LINE>... | CertsRotate, requestParams, customer, universe); |
103,037 | private void initialize() {<NEW_LINE>Collection<String> mimeTypes = ctrl.getUpdatedLanguages();<NEW_LINE>List<String[]> langMimes = new ArrayList<String[]>(mimeTypes.size());<NEW_LINE>// NOI18N<NEW_LINE>langMimes.add(new String[] { "", ITEM_AllLanguages() });<NEW_LINE>for (String s : mimeTypes) {<NEW_LINE>Language l = ... | Collections.sort(langMimes, LANG_COMPARATOR); |
173,980 | public void marshall(UpdateAppRequest updateAppRequest, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (updateAppRequest == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(updateAppRequest.getAppId(), APPID_B... | updateAppRequest.getEnableBasicAuth(), ENABLEBASICAUTH_BINDING); |
1,354,306 | private Item nodeHasSelectTable(PlanNode child, Item sel) {<NEW_LINE>if (sel instanceof ItemField) {<NEW_LINE>return nodeHasColumn(child, (ItemField) sel);<NEW_LINE>} else if (sel.canValued()) {<NEW_LINE>return sel;<NEW_LINE>} else if (sel.type().equals(Item.ItemType.SUM_FUNC_ITEM)) {<NEW_LINE>return null;<NEW_LINE>} e... | ).set(index, argSel); |
470,141 | public String[][] resolveType(String typeName, WorkingCopyOwner owner) throws JavaModelException {<NEW_LINE>JavaProject project = (JavaProject) getJavaProject();<NEW_LINE>SearchableEnvironment environment = project.newSearchableNameEnvironment(owner);<NEW_LINE>class TypeResolveRequestor implements ISelectionRequestor {... | String[][] answers = null; |
1,015,706 | public List<ParticipantsEntity> doAddPointByKnowledgeJoinEvent(int offset) {<NEW_LINE>List<ParticipantsEntity> list;<NEW_LINE>list = ParticipantsDao.get().selectAllWidthPager(limit, offset, Order.ASC);<NEW_LINE>for (ParticipantsEntity item : list) {<NEW_LINE>KnowledgesEntity knowledge = KnowledgesDao.get().selectOnKey(... | item.getKnowledgeId() + "] is not found. so skip add point by knowledge event."); |
1,159,697 | final CreateRouteResult executeCreateRoute(CreateRouteRequest createRouteRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createRouteRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.ClientExecuteTi... | addHandlerContext(HandlerContextKey.ADVANCED_CONFIG, advancedConfig); |
1,304,493 | public MatchResult match(MatchResult reuse, byte[] sequence, int start, int length, int node) {<NEW_LINE>if (node == 0) {<NEW_LINE>reuse.reset(<MASK><NEW_LINE>return reuse;<NEW_LINE>}<NEW_LINE>final FST fst = _fst;<NEW_LINE>final int end = start + length;<NEW_LINE>for (int i = start; i < end; i++) {<NEW_LINE>final int ... | MatchResult.NO_MATCH, start, node); |
1,368,500 | private void showError(String message, Exception cause) {<NEW_LINE>if (cause instanceof NodeException) {<NEW_LINE>NodeException e = (NodeException) cause;<NEW_LINE>circuitComponent.addHighLightedWires(e.getValues());<NEW_LINE>circuitComponent.addHighLighted(e.getVisualElement());<NEW_LINE>if (modelCreator != null)<NEW_... | addHighLighted(e.getVisualElement()); |
346,058 | /*<NEW_LINE>static public void addTools(JMenu menu, List<Tool> tools) {<NEW_LINE>Map<String, JMenuItem> toolItems = new HashMap<String, JMenuItem>();<NEW_LINE><NEW_LINE>for (final Tool tool : tools) {<NEW_LINE>// If init() fails, the item won't be added to the menu<NEW_LINE>addToolItem(tool, toolItems);<NEW_LINE>}<NEW_... | getMenuTitle() + "\" is not" + "compatible with this version of Processing"); |
960,754 | // dispose<NEW_LINE>public void sort(Comparator cmpr, boolean ascending) {<NEW_LINE>WListItemRenderer.ColumnComparator lsc = (WListItemRenderer.ColumnComparator) cmpr;<NEW_LINE>if (m_useDatabasePaging) {<NEW_LINE>int col = lsc.getColumnIndex();<NEW_LINE>String colsql = p_layout[col].getColSQL().trim();<NEW_LINE>int las... | tmp.length() - 1); |
482,942 | public void flatMap(BaseVectorSummarizer srt, Collector<Tuple2<Integer, DenseVector>> collector) throws Exception {<NEW_LINE>BaseVectorSummary summary = srt.toSummary();<NEW_LINE>if (summary.count() == 0) {<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>int colNum = summary.vectorSize();<NEW_LINE>// rowNum<NEW_LINE>{<NEW_LINE>do... | * (colNum + 1) * 2; |
1,360,108 | private void uiStartup(Shell shell) {<NEW_LINE>models = Models.create(shell, settings, handler, server.getClient(), window.getStatusBar());<NEW_LINE>widgets = Widgets.create(shell.getDisplay(), theme, server.getClient(), models);<NEW_LINE>Runnable onStart = () -> {<NEW_LINE>if (args.length == 1) {<NEW_LINE>models.captu... | getClient(), models, widgets); |
1,202,583 | public void testFutureGetTimesOut() throws Exception {<NEW_LINE>long currentThreadId = 0;<NEW_LINE>ResultsStatelessRemote bean = lookupSLRBean();<NEW_LINE>assertNotNull("Async Stateless Bean created successfully", bean);<NEW_LINE>// initialize latches<NEW_LINE>ResultsStatelessRemoteFutureBean.svBeanLatch = new CountDow... | svLogger.info("Test threadId = " + currentThreadId); |
1,154,285 | public boolean onTouch(View v, MotionEvent event) {<NEW_LINE>postAction();<NEW_LINE>if (event.getAction() == MotionEvent.ACTION_DOWN && popupView.getLayoutParams() != null) {<NEW_LINE>x = event.getRawX();<NEW_LINE>y = event.getRawY();<NEW_LINE>w = popupView.getLayoutParams().width;<NEW_LINE>h = popupView.getLayoutParam... | AnchorHelper.setY(anchor, y2); |
1,803,323 | public Repo<Manager> call(long id, Manager manager) throws Exception {<NEW_LINE>ZooReaderWriter zoo = manager.getContext().getZooReaderWriter();<NEW_LINE>Utils.getTableNameLock().lock();<NEW_LINE>try {<NEW_LINE>Utils.checkNamespaceDoesNotExist(manager.getContext(), newName, namespaceId, TableOperation.RENAME);<NEW_LINE... | manager, namespaceId, id, true); |
147,893 | public static GetFaceOptionsResponse unmarshall(GetFaceOptionsResponse getFaceOptionsResponse, UnmarshallerContext _ctx) {<NEW_LINE>getFaceOptionsResponse.setRequestId(_ctx.stringValue("GetFaceOptionsResponse.RequestId"));<NEW_LINE>getFaceOptionsResponse.setMessage(_ctx.stringValue("GetFaceOptionsResponse.Message"));<N... | = new ArrayList<OptionListItem>(); |
740,008 | public void marshall(HlsCdnSettings hlsCdnSettings, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (hlsCdnSettings == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(hlsCdnSettings.getHlsAkamaiSettings(), HLS... | hlsCdnSettings.getHlsWebdavSettings(), HLSWEBDAVSETTINGS_BINDING); |
1,480,048 | private TypeUpdateResult invokeListener(TypeUpdateInfo updateInfo, InsnNode insn, InsnArg arg, ArgType candidateType) {<NEW_LINE>BaseInvokeNode invoke = (BaseInvokeNode) insn;<NEW_LINE>if (isAssign(invoke, arg)) {<NEW_LINE>// TODO: implement backward type propagation (from result to instance)<NEW_LINE>return SAME;<NEW_... | ArgType returnType = methodDetails.getReturnType(); |
207,623 | final ListSimulationApplicationsResult executeListSimulationApplications(ListSimulationApplicationsRequest listSimulationApplicationsRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(listSimulationApplicationsRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRe... | awsRequestMetrics.endEvent(Field.RequestMarshallTime); |
1,258,415 | private static InputSource createInputSource(FileObject fo, EditorCookie editor, final StyledDocument document) throws IOException, BadLocationException {<NEW_LINE>final StringWriter w = new <MASK><NEW_LINE>final EditorKit kit = findKit(editor);<NEW_LINE>if (kit == null)<NEW_LINE>return null;<NEW_LINE>final IOException... | StringWriter(document.getLength()); |
1,002,924 | protected boolean isMigrationNeeded(CourseStudent student) {<NEW_LINE>if (isSanitizedHtml(student.getCourseId())) {<NEW_LINE>logError(String.format("Student %s has unsanitized courseId %s, this should not happen", student.getUniqueId(), student.getCourseId()));<NEW_LINE>}<NEW_LINE>if (isSanitizedHtml(student.getEmail()... | isSanitizedHtml(student.getName()); |
857,815 | private WebHookAction onPost(Item project, StaplerRequest request) {<NEW_LINE>String eventHeader = request.getHeader("X-Gitlab-Event");<NEW_LINE>if (eventHeader == null) {<NEW_LINE>LOGGER.log(Level.FINE, "Missing X-Gitlab-Event header");<NEW_LINE>return new NoopAction();<NEW_LINE>}<NEW_LINE>String tokenHeader = request... | Level.FINE, "Unsupported X-Gitlab-Event header: {0}", eventHeader); |
1,088,752 | private void addActionInOnReceive(EReceiverHolder holder, ExecutableElement executableElement, String methodName, JFieldVar actionsField, JFieldVar dataSchemesField) {<NEW_LINE>String actionsInvoke = getInvocationName(actionsField);<NEW_LINE>IJExpression filterCondition = actionsField.invoke(actionsInvoke).arg(holder.g... | _if(filterCondition)._then(); |
284,802 | public void commit() throws TskCoreException {<NEW_LINE>try {<NEW_LINE>this.connection.commitTransaction();<NEW_LINE>} catch (SQLException ex) {<NEW_LINE>throw new TskCoreException("Failed to commit transaction on case database", ex);<NEW_LINE>} finally {<NEW_LINE>close();<NEW_LINE>if (!scoreChangeMap.isEmpty()) {<NEW_... | .groupingBy(ScoreChange::getDataSourceObjectId)); |
600,281 | public ApiResponse<MediaShare> mediaSharesGetByMediaIdWithHttpInfo(String id) throws ApiException {<NEW_LINE>Object localVarPostBody = null;<NEW_LINE>// verify the required parameter 'id' is set<NEW_LINE>if (id == null) {<NEW_LINE>throw new ApiException(400, "Missing the required parameter 'id' when calling mediaShares... | (id.toString())); |
41,405 | // DO NOT MODIFY THIS CODE, GENERATED AUTOMATICALLY<NEW_LINE>public static com.sun.jdi.ObjectReference monitor(com.sun.jdi.event.MonitorContendedEnterEvent a) throws org.netbeans.modules.debugger.jpda.jdi.InternalExceptionWrapper, org.netbeans.modules.debugger.jpda.jdi.VMDisconnectedExceptionWrapper {<NEW_LINE>if (org.... | Mirror) a).virtualMachine(); |
773,734 | public static void main(String[] args) {<NEW_LINE>// Platform-specific initialization routine<NEW_LINE>InitMain("trainer", (int[]) null, null);<NEW_LINE>// Create a new empty graph<NEW_LINE>Scope scope = Scope.NewRootScope();<NEW_LINE>// (2,1) matrix of ones, sixes and tens<NEW_LINE>TensorShape shape = new TensorShape(... | OutputVector(ones, sixes, tens); |
870,609 | private <T extends Statement> Optional<KsqlEntity> executeStatement(final KsqlSecurityContext securityContext, final PreparedStatement<T> prepared, final SessionProperties sessionProperties, final KsqlEntityList entities) {<NEW_LINE>final Class<? extends Statement> statementClass = prepared<MASK><NEW_LINE>commandQueueS... | .getStatement().getClass(); |
1,025,482 | protected AudioInputStream generateAudioStream(List<SelectedUnit> units) {<NEW_LINE>int len = units.size();<NEW_LINE>Datagram[][] datagrams <MASK><NEW_LINE>Datagram[] leftContexts = new Datagram[len];<NEW_LINE>Datagram[] rightContexts = new Datagram[len];<NEW_LINE>for (int i = 0; i < len; i++) {<NEW_LINE>SelectedUnit u... | = new Datagram[len][]; |
160,840 | private Expression transformMethodCallExpression(final MethodCallExpression exp) {<NEW_LINE>ClassNode traitType = getTraitSuperTarget(exp.getObjectExpression());<NEW_LINE>if (traitType != null) {<NEW_LINE>ClassNode helperType = getHelper(traitType);<NEW_LINE>// TraitType.super.foo() -> TraitType$Trait$Helper.foo(this)<... | "class") : varX("this")); |
1,650,975 | protected synchronized void processNewBlockHashes(NewBlockHashesMessage msg) {<NEW_LINE>if (logger.isTraceEnabled())<NEW_LINE>logger.trace("Peer {}: processing NewBlockHashes, size [{}]", channel.getPeerIdShort(), msg.getBlockIdentifiers().size());<NEW_LINE>List<BlockIdentifier> identifiers = msg.getBlockIdentifiers();... | long blockNumber = identifier.getNumber(); |
102,240 | public Position destination(final EditorAdaptor editorAdaptor, Position fromPosition) throws CommandExecutionException {<NEW_LINE>final Selection selection = editorAdaptor.getSelection();<NEW_LINE>if (selection == null)<NEW_LINE>throw new CommandExecutionException("BlockSelectionMotion must have a selection!");<NEW_LIN... | .getRegisterManager().getLastActiveSelectionArea(); |
96,233 | private String format(String input, IParseRootNode parseResult, int indentationLevel, int inputOffset, boolean isSelection, String indentSufix, boolean prefixWithNewLine, boolean postfixWithNewLine) throws Exception {<NEW_LINE>final JSFormatterNodeBuilder builder = new JSFormatterNodeBuilder();<NEW_LINE>final Formatter... | .setWrapLength(getInt(WRAP_COMMENTS_LENGTH)); |
1,656,461 | public int delete(final Uri uri, final String selection, final String[] selectionArgs, final Integer knownSize) {<NEW_LINE>final int uriType = uriMatcher.match(uri);<NEW_LINE>final SQLiteDatabase db = databaseHelper.getWritableDatabase();<NEW_LINE>int rowsDeleted = 0;<NEW_LINE>switch(uriType) {<NEW_LINE>case EVENTS:<NE... | String id = uri.getLastPathSegment(); |
1,297,020 | public int read(byte[] buffer, int offset, int count) throws IOException {<NEW_LINE>try {<NEW_LINE>if (finished) {<NEW_LINE>return -1;<NEW_LINE>}<NEW_LINE>int read = in.read(buffer, offset, count);<NEW_LINE>if (read == -1) {<NEW_LINE>int finalBytes = cipher.doFinal(buffer, 0);<NEW_LINE>this.finished = true;<NEW_LINE>re... | buffer, offset, UPDATE_BUFFER_SIZE, temp); |
1,152,593 | public void onFailure(Throwable t) {<NEW_LINE>logger.warn("Error with Trie Node request: " + t);<NEW_LINE>idle.getNodeStatistics().eth63NodesRequested.add(hashes.size());<NEW_LINE>idle.getNodeStatistics().eth63NodesRetrieveTime.add(<MASK><NEW_LINE>synchronized (FastSyncManager.this) {<NEW_LINE>for (byte[] hash : hashes... | System.currentTimeMillis() - reqTime); |
450,206 | public AgentFilter unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>AgentFilter agentFilter = new AgentFilter();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE>String currentParentElement = context.getCurrentParentElement();<NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE... | )).unmarshall(context)); |
1,449,896 | public Address copyAddress(Address dest, Address orig) {<NEW_LINE>if (dest == null) {<NEW_LINE>dest = create();<NEW_LINE>}<NEW_LINE>if (orig != null) {<NEW_LINE>dest.setFullName(orig.getFullName());<NEW_LINE>dest.setFirstName(orig.getFirstName());<NEW_LINE>dest.setLastName(orig.getLastName());<NEW_LINE>dest.setAddressL... | , orig.getPhoneSecondary())); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.