idx int32 46 1.86M | input stringlengths 321 6.6k | target stringlengths 9 1.24k |
|---|---|---|
965,877 | private void createInputsTable(Composite composite) {<NEW_LINE>Composite panel = UIUtils.createComposite(composite, 1);<NEW_LINE>// UIUtils.createControlLabel(panel, DTUIMessages.data_transfer_wizard_final_group_objects);<NEW_LINE>inputsTable = new TableViewer(panel, SWT.BORDER | SWT.SINGLE | SWT.FULL_SELECTION);<NEW_L... | = new GridData(GridData.FILL_BOTH); |
4,070 | public <T extends Metric> T register(Metadata metadata, T metric) throws IllegalArgumentException {<NEW_LINE>// Create Copy of Metadata object so it can't be changed after its registered<NEW_LINE>Metadata metadataCopy = newMetadata(metadata);<NEW_LINE>for (String tag : metadata.getTags().keySet()) {<NEW_LINE>metadataCo... | addNameToApplicationMap(metadata.getName()); |
511,616 | private void typecheckDataHeader(DataDefinition dataDefinition, Concrete.DataDefinition def, LocalInstancePool localInstancePool) {<NEW_LINE>def.getData().setTypecheckedIfNotCancelled(dataDefinition);<NEW_LINE>if (def.enclosingClass != null) {<NEW_LINE>dataDefinition.setHasEnclosingClass(true);<NEW_LINE>}<NEW_LINE>if (... | checkNoStrictParameters(def.getParameters()); |
969,862 | private Portal create(Business business, Wi wi) throws Exception {<NEW_LINE>List<JpaObject> persistObjects = new ArrayList<>();<NEW_LINE>Portal portal = business.entityManagerContainer().find(wi.getId(), Portal.class);<NEW_LINE>if (null != portal) {<NEW_LINE>throw new ExceptionPortalExistForCreate(wi.getId());<NEW_LINE... | setPortal(portal.getId()); |
21,483 | public Object calculate(Context ctx) {<NEW_LINE>Object o1 = null, o2 = null;<NEW_LINE>if (param == null) {<NEW_LINE>MessageManager mm = EngineMessage.get();<NEW_LINE>throw new RQException("spearman" + mm.getMessage("function.missingParam"));<NEW_LINE>} else if (param.isLeaf()) {<NEW_LINE>o1 = param.getLeafExpression().... | o1).length() : 1; |
1,502,405 | public boolean upgradeVmDb(final long vmId, final ServiceOffering newServiceOffering, ServiceOffering currentServiceOffering) {<NEW_LINE>final VMInstanceVO vmForUpdate = _vmDao.findById(vmId);<NEW_LINE>vmForUpdate.setServiceOfferingId(newServiceOffering.getId());<NEW_LINE>final ServiceOffering newSvcOff = _entityMgr.fi... | class, newServiceOffering.getId()); |
1,033,958 | public void translate(final ITranslationEnvironment environment, final IInstruction instruction, final List<ReilInstruction> instructions) throws InternalTranslationException {<NEW_LINE>TranslationHelpers.checkTranslationArguments(environment, instruction, instructions, "loope");<NEW_LINE>if (instruction.getOperands().... | > operands = instruction.getOperands(); |
97,684 | protected int semwait_signal(Emulator<?> emulator, RunnableTask runningTask, int cond_sem, int mutex_sem, int timeout, int relative, long tv_sec, int tv_nsec) {<NEW_LINE>if (timeout == 1 && relative == 1 && (tv_sec > 0 || tv_nsec > 0)) {<NEW_LINE>if (threadDispatcherEnabled) {<NEW_LINE>runningTask.setWaiter(new SemWait... | getMemory().setErrno(ETIMEDOUT); |
1,364,007 | public void widgetSelected(SelectionEvent ev) {<NEW_LINE>button.setEnabled(false);<NEW_LINE>final Display display = composite.getDisplay();<NEW_LINE>final int[] done = { 0 };<NEW_LINE>new AEThread2("async") {<NEW_LINE><NEW_LINE>@Override<NEW_LINE>public void run() {<NEW_LINE>for (String key : keys) {<NEW_LINE>try {<NEW... | createChatWindow(view, plugin, inst); |
1,175,741 | private Set<String> keysOfPropertyFiles(String names) {<NEW_LINE>String[] <MASK><NEW_LINE>if (namesArr == null) {<NEW_LINE>checker.message(Kind.WARNING, "Couldn't parse the properties files: <" + names + ">");<NEW_LINE>return Collections.emptySet();<NEW_LINE>}<NEW_LINE>Set<String> result = new HashSet<>(namesArr.length... | namesArr = names.split(":"); |
168,500 | public void run(RegressionEnvironment env) {<NEW_LINE>RegressionPath path = new RegressionPath();<NEW_LINE>String epl = "@public @buseventtype create json schema A(a1 double);\n" + "@public @buseventtype create json schema B(b1 string, b2 int) inherits A;\n" + "@public @buseventtype create json schema C(c1 string) inhe... | env.sendEventJson("{\"d2\": 1, \"d1\": 2, \"c1\": \"def\", \"b2\": 3, \"b1\": \"x\", \"a1\": 4}", "D"); |
992,290 | public XmlWorkflowItem start(Context context, WorkspaceItem wsi) throws SQLException, AuthorizeException, IOException, WorkflowException {<NEW_LINE>try {<NEW_LINE>Item myitem = wsi.getItem();<NEW_LINE>Collection collection = wsi.getCollection();<NEW_LINE>Workflow wf = xmlWorkflowFactory.getWorkflow(collection);<NEW_LIN... | context, wf, firstStep, wfi); |
1,345,707 | protected HttpClient createInstance() {<NEW_LINE>// configure pool resources<NEW_LINE>ConnectionProvider connectionProvider = buildConnectionProvider(properties);<NEW_LINE>HttpClient httpClient = // TODO: move customizations to HttpClientCustomizers<NEW_LINE>HttpClient.create(connectionProvider<MASK><NEW_LINE>if (serve... | ).httpResponseDecoder(this::httpResponseDecoder); |
710,349 | protected Map<String, SourceCode> loadSources(Path path) throws IOException {<NEW_LINE>Map<String, SourceCode> map = new HashMap<>();<NEW_LINE>// Will throw IO exception if the file couldn't be opened as an archive<NEW_LINE>try (ZipFile zip = new ZipFile(path.toFile())) {<NEW_LINE>Enumeration<? extends ZipEntry<MASK><N... | > entries = zip.entries(); |
1,151,406 | final ReplicationGroup executeModifyReplicationGroupShardConfiguration(ModifyReplicationGroupShardConfigurationRequest modifyReplicationGroupShardConfigurationRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(modifyReplicationGroupShardConfigurationRequest);<NEW_LINE>AWSRequestMetrics awsRe... | (super.beforeMarshalling(modifyReplicationGroupShardConfigurationRequest)); |
747,607 | public static void main(String[] args) throws Exception {<NEW_LINE>String author = args.length == 0 ? "Random_Stranger" : args[0];<NEW_LINE>// Connect to the sever<NEW_LINE>ManagedChannel channel = ManagedChannelBuilder.forAddress("localhost", PORT).usePlaintext().build();<NEW_LINE>RxChatGrpc.RxChatStub <MASK><NEW_LINE... | stub = RxChatGrpc.newRxStub(channel); |
1,019,503 | public AwsS3BucketServerSideEncryptionRule unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>AwsS3BucketServerSideEncryptionRule awsS3BucketServerSideEncryptionRule = new AwsS3BucketServerSideEncryptionRule();<NEW_LINE><MASK><NEW_LINE>String currentParentElement = context.getCurrentParentElement()... | int originalDepth = context.getCurrentDepth(); |
577,640 | public void map(InfoMap infoMap) {<NEW_LINE>// Defines<NEW_LINE>infoMap.put(new Info(defineFalse()).define(false)).put(new Info(defineTrue()).define(true));<NEW_LINE>// Enums<NEW_LINE>for (String enumName : enums()) {<NEW_LINE>if (!enumName.startsWith("Qt::") && enumName.contains("::")) {<NEW_LINE>String valueType = en... | ("@Cast(\"" + enumName + "\") int")); |
1,160,643 | public void end() throws IOException {<NEW_LINE>try {<NEW_LINE>// errors<NEW_LINE>for (Report.ProcessingError pe : errors) {<NEW_LINE>writeNewLine();<NEW_LINE>xmlWriter.writeStartElement("error");<NEW_LINE>xmlWriter.writeAttribute("filename", determineFileName<MASK><NEW_LINE>xmlWriter.writeAttribute("msg", pe.getMsg())... | (pe.getFile())); |
1,839,099 | public String prepareIt() {<NEW_LINE>log.info(toString());<NEW_LINE>m_processMsg = ModelValidationEngine.get().<MASK><NEW_LINE>if (m_processMsg != null)<NEW_LINE>return DocAction.STATUS_Invalid;<NEW_LINE>MDocType dt = MDocType.get(getCtx(), getC_DocType_ID());<NEW_LINE>// Std Period open?<NEW_LINE>if (!MPeriod.isOpen(g... | fireDocValidate(this, ModelValidator.TIMING_BEFORE_PREPARE); |
1,116,991 | public void escapeText(@Nonnull String text, @Nonnull Key outputType, @Nonnull ColoredTextAcceptor textAcceptor) {<NEW_LINE>List<Pair<String, Key>> chunks = null;<NEW_LINE>int pos = 0;<NEW_LINE>text = normalizeAsciiControlCharacters(text);<NEW_LINE>while (true) {<NEW_LINE>int escSeqBeginInd = text.indexOf(CSI, pos);<NE... | text.substring(escSeqBeginInd, escSeqEndInd); |
1,568,076 | public String sqlAD_getTableEntityType(String vendorName, String catalogName, String schemaName, String tableName) {<NEW_LINE>// table name<NEW_LINE>String searchTableName = "AD_Table";<NEW_LINE>// column names<NEW_LINE>ArrayList<String> columnNames = new ArrayList<String>();<NEW_LINE>columnNames.add("TableName");<NEW_... | ("'").toString()); |
538 | private void fillClassLevelParameters(DefinitionProtos.Definition.ClassData classProto, ClassDefinition classDef) throws DeserializationException {<NEW_LINE>if (!classProto.getIsStdLevels()) {<NEW_LINE>List<LevelVariable> fieldLevels = new ArrayList<>();<NEW_LINE>for (DefinitionProtos.Definition.LevelField levelFieldPr... | myCallTargetProvider.getLevelCallTarget(ref))); |
580,213 | private void sendToNextURIInSequentialMode() {<NEW_LINE>if (c_logger.isTraceEntryExitEnabled()) {<NEW_LINE>c_logger.traceEntry(this, "sendToNextURIInSequentialMode");<NEW_LINE>}<NEW_LINE>// sequential mode - send to next URI.<NEW_LINE>if (_activeBranchCount > 0) {<NEW_LINE>// The last branch has not completed yet. Exit... | "sendToNextURIInSequentialMode", getMyInfo() + "sequencial proxy mode - not sending till previous branch completes."); |
1,801,873 | private MetaInfoResponse handleClientRegister(final MetaInfoRequest request) {<NEW_LINE>final String realSubject = RetrySubjectUtils.getRealSubject(request.getSubject());<NEW_LINE>if (SubjectUtils.isInValid(realSubject)) {<NEW_LINE>return buildResponse(request, -2, OnOfflineState.OFFLINE, new BrokerCluster(new ArrayLis... | setAppCode(request.getAppCode()); |
942,670 | public static QueryDeviceGroupTagListResponse unmarshall(QueryDeviceGroupTagListResponse queryDeviceGroupTagListResponse, UnmarshallerContext _ctx) {<NEW_LINE>queryDeviceGroupTagListResponse.setRequestId(_ctx.stringValue("QueryDeviceGroupTagListResponse.RequestId"));<NEW_LINE>queryDeviceGroupTagListResponse.setSuccess<... | (_ctx.booleanValue("QueryDeviceGroupTagListResponse.Success")); |
1,814,797 | private void tryAssertionCreateSchemaModelAfter(RegressionEnvironment env, EventRepresentationChoice eventRepresentationEnum) {<NEW_LINE>String epl = eventRepresentationEnum.getAnnotationTextWJsonProvided(MyLocalJsonProvidedEventTypeOne.class) + " @public @buseventtype create schema EventTypeOne (hsi int);\n" + eventRe... | EventBean result = iterator.next(); |
967,542 | public RefactoringStatus initialize(JavaRefactoringArguments arguments) {<NEW_LINE>final RefactoringStatus status = new RefactoringStatus();<NEW_LINE>int memberCount = 0;<NEW_LINE>String value = arguments.getAttribute(ATTRIBUTE_MEMBERS);<NEW_LINE>if (value != null && !"".equals(value)) {<NEW_LINE>// $NON-NLS-1$<NEW_LIN... | getProject(), handle, false); |
478,889 | public static void saveToBuilder(DeviceCommandInvocation event, Point.Builder builder) throws SiteWhereException {<NEW_LINE>builder.tag(CMD_INITIATOR, event.getInitiator().name());<NEW_LINE>if (event.getInitiatorId() != null) {<NEW_LINE>builder.tag(CMD_INITIATOR_ID, event.getInitiatorId());<NEW_LINE>}<NEW_LINE>builder.... | InfluxDbDeviceEvent.saveToBuilder(event, builder); |
141,111 | private void addSupportingFilesForHttpClient() {<NEW_LINE>// documentation files<NEW_LINE>modelDocTemplateFiles.put("model_doc.mustache", ".md");<NEW_LINE>apiDocTemplateFiles.put("api_doc.mustache", ".md");<NEW_LINE>supportingFiles.add(new SupportingFile("README.mustache", "", "README.md"));<NEW_LINE>supportingFiles.ad... | ("settings.gradle.mustache", "", "settings.gradle")); |
212,108 | private static void printTagList(final String id, final String tagName, final int comp, final int max, final boolean opt) {<NEW_LINE>if (sb.bookmarksDB == null) {<NEW_LINE>prop.put("display_" + id, 0);<NEW_LINE>return;<NEW_LINE>}<NEW_LINE>int count = 0;<NEW_LINE>final Iterator<BookmarksDB.Tag> it;<NEW_LINE>if ("".equal... | "_" + count + "_selected", " selected=\"selected\""); |
1,023,268 | void populateCache() {<NEW_LINE>Iterator<J9ClassPointer> classes;<NEW_LINE>try {<NEW_LINE>classes = ClassIterator.fromJ9Classloader(j9ClassLoader);<NEW_LINE>} catch (Throwable t) {<NEW_LINE>// if we are corrupt here, then we can't return any classes<NEW_LINE>CorruptData cd = J9DDRDTFJUtils.handleAsCorruptData(<MASK><NE... | DTFJContext.getProcess(), t); |
1,192,264 | private static void toDecimal(StringBuilder sb, long value, int digitGroupSize, String digitSeparator, int digits) {<NEW_LINE>if (digits == 0) {<NEW_LINE>digits = 1;<NEW_LINE>for (long tmp = value; ; ) {<NEW_LINE>tmp = Long.divideUnsigned(tmp, 10);<NEW_LINE>if (tmp == 0)<NEW_LINE>break;<NEW_LINE>digits++;<NEW_LINE>}<NE... | char) (digit + '0')); |
917,056 | private static void productQueryMulUpdateExample() {<NEW_LINE>// 0, 1, 2, 3<NEW_LINE>long[] v = { 3, 2, 2, 1 };<NEW_LINE>GenericSegmentTree st = new GenericSegmentTree(v, SegmentCombinationFn.PRODUCT, RangeUpdateFn.MULTIPLICATION);<NEW_LINE>int l = 0;<NEW_LINE>int r = 3;<NEW_LINE>long q = st.rangeQuery1(l, r);<NEW_LINE... | st.rangeQuery1(l, r); |
1,280,609 | private void doWrite(ByteBuf buff, boolean end, boolean connect, Handler<AsyncResult<Void>> completionHandler) {<NEW_LINE>boolean writeHead;<NEW_LINE>boolean writeEnd;<NEW_LINE>synchronized (this) {<NEW_LINE>if (ended) {<NEW_LINE>completionHandler.handle(Future.failedFuture<MASK><NEW_LINE>return;<NEW_LINE>}<NEW_LINE>ch... | (new IllegalStateException("Request already complete"))); |
1,367,898 | public void didChangeWatchedFiles(DidChangeWatchedFilesParams param) {<NEW_LINE>List<FileEvent> changes = param.getChanges().stream().distinct().collect(Collectors.toList());<NEW_LINE>for (FileEvent fileEvent : changes) {<NEW_LINE>CHANGE_TYPE changeType = toChangeType(fileEvent.getType());<NEW_LINE>if (changeType == CH... | ] units = new ICompilationUnit[1]; |
1,147,824 | public Address parseAddress(JsonObject json) {<NEW_LINE>JsonArray <MASK><NEW_LINE>if (!features.isEmpty()) {<NEW_LINE>Address address = new Address();<NEW_LINE>for (int i = 0; i < features.size(); i++) {<NEW_LINE>JsonObject feature = features.getJsonObject(i);<NEW_LINE>String type = feature.getJsonArray("place_type").g... | features = json.getJsonArray("features"); |
1,826,949 | private void addSetter(SourceBuilder code) {<NEW_LINE>code.addLine("").addLine("/**").addLine(" * Sets the value to be returned by %s.", datatype.getType().javadocNoArgMethodLink(property.getGetterName())).addLine(" *").addLine(" * @return this {@code %s} object", datatype.getBuilder().getSimpleName());<NEW_LINE>if (!u... | ()).addLine("}"); |
1,402,261 | public static void writeGeoLocationsElement(XMLStreamWriter xmlw, DatasetVersionDTO datasetVersionDTO, String language) throws XMLStreamException {<NEW_LINE>// geoLocation -> geoLocationPlace<NEW_LINE>String geoLocationPlace = dto2Primitive(datasetVersionDTO, DatasetFieldConstant.productionPlace);<NEW_LINE>boolean geoL... | fieldDTO.getSingleCompound(), language); |
235,240 | public void visit(BLangWorkerFlushExpr flushExpr) {<NEW_LINE>BIRBasicBlock thenBB = new BIRBasicBlock(this.env.nextBBId(names));<NEW_LINE>addToTrapStack(thenBB);<NEW_LINE>// create channelDetails array<NEW_LINE>BIRNode.ChannelDetails[] channels = new BIRNode.ChannelDetails[flushExpr.workerIdentifierList.size()];<NEW_LI... | .value + "->" + workerIdentifier.value; |
1,492,860 | protected Q newInstance(Class<Q> queryType, PathMetadata pm) {<NEW_LINE>try {<NEW_LINE>if (constructor == null) {<NEW_LINE>if (Constants.isTyped(queryType)) {<NEW_LINE>try {<NEW_LINE>constructor = queryType.getDeclaredConstructor(Class.class, PathMetadata.class, PathInits.class);<NEW_LINE>usePathInits = true;<NEW_LINE>... | Class.class, PathMetadata.class); |
857,969 | public BlockCapsule push(BlockCapsule blk) throws UnLinkedBlockException, BadNumberBlockException {<NEW_LINE><MASK><NEW_LINE>if (head != null && block.getParentHash() != Sha256Hash.ZERO_HASH) {<NEW_LINE>KhaosBlock kblock = miniStore.getByHash(block.getParentHash());<NEW_LINE>if (kblock != null) {<NEW_LINE>if (blk.getNu... | KhaosBlock block = new KhaosBlock(blk); |
877,409 | public void marshall(ConnectorConfiguration connectorConfiguration, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (connectorConfiguration == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(connectorConfigura... | connectorConfiguration.getConnectorLabel(), CONNECTORLABEL_BINDING); |
710,896 | final DeleteTableResult executeDeleteTable(DeleteTableRequest deleteTableRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteTableRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE><MASK><NEW_LINE>Request<DeleteTableRequest> reques... | awsRequestMetrics.startEvent(Field.ClientExecuteTime); |
29,985 | private static void executeQuery(Client client, long sessionId, String query, long statementId) throws TException, StatementExecutionException, IoTDBConnectionException {<NEW_LINE>if (logger.isInfoEnabled()) {<NEW_LINE>logger.info("{ {} }", query);<NEW_LINE>}<NEW_LINE>TSExecuteStatementResp resp = client.executeQuerySt... | statementId).setFetchSize(1000)); |
1,623,023 | private void findHosts(Reader reader) {<NEW_LINE>currentIndex = 0;<NEW_LINE>foundHosts = new LinkedHashMap<>();<NEW_LINE>try (BufferedReader fileReader = new BufferedReader(reader)) {<NEW_LINE>String fileLine;<NEW_LINE>while ((fileLine = fileReader.readLine()) != null) {<NEW_LINE>Matcher <MASK><NEW_LINE>while (matcher.... | matcher = HOSTNAME_REGEX.matcher(fileLine); |
1,334,005 | private void updateInfo() {<NEW_LINE>m_updating = true;<NEW_LINE>nameField.setText(m_cc.getName());<NEW_LINE>appsHostField.setText(m_cc.getAppsHost());<NEW_LINE>appsPortField.setText(String.valueOf(m_cc.getAppsPort()));<NEW_LINE>//<NEW_LINE>bTestApps.setIcon(getStatusIcon(m_cc.isAppsServerOK(false)));<NEW_LINE>// bTest... | setText(m_cc.getFwHost()); |
1,042,756 | public static ListNodeTupleOrdersResponse unmarshall(ListNodeTupleOrdersResponse listNodeTupleOrdersResponse, UnmarshallerContext _ctx) {<NEW_LINE>listNodeTupleOrdersResponse.setRequestId(_ctx.stringValue("ListNodeTupleOrdersResponse.RequestId"));<NEW_LINE>listNodeTupleOrdersResponse.setSuccess(_ctx.booleanValue("ListN... | = new ArrayList<Order>(); |
999,666 | public void put(long ledgerId, long entryId, ByteBuf entry) {<NEW_LINE>int entrySize = entry.readableBytes();<NEW_LINE>int alignedSize = align64(entrySize);<NEW_LINE>lock.readLock().lock();<NEW_LINE>try {<NEW_LINE>if (entrySize > segmentSize) {<NEW_LINE>log.warn("entrySize {} > segmentSize {}, skip update read cache!",... | offset = currentSegmentOffset.getAndAdd(entrySize); |
692,829 | // Inject a new submission<NEW_LINE>public String injestNewSubmission(WorkItem item) {<NEW_LINE>Connection c = null;<NEW_LINE>int rowCount = 0;<NEW_LINE>try {<NEW_LINE>// Create a Connection object<NEW_LINE>c = ConnectionHelper.getConnection();<NEW_LINE>// Use a prepared statement<NEW_LINE>PreparedStatement ps = null;<... | UUID uuid = UUID.randomUUID(); |
1,637,634 | protected synchronized void applyLayoutInternal(InternalNode[] entitiesToLayout, InternalRelationship[] relationshipsToConsider, double boundsX, double boundsY, double boundsWidth, double boundsHeight) {<NEW_LINE>int index = 0;<NEW_LINE>for (int i = 0; i < rows; i++) {<NEW_LINE>for (int j = 0; j < cols; j++) {<NEW_LINE... | sn.setInternalLocation(xmove, ymove); |
309,898 | public void marshall(Container container, ProtocolMarshaller protocolMarshaller) {<NEW_LINE>if (container == null) {<NEW_LINE>throw new SdkClientException("Invalid argument passed to marshall(...)");<NEW_LINE>}<NEW_LINE>try {<NEW_LINE>protocolMarshaller.marshall(container.getContainerArn(), CONTAINERARN_BINDING);<NEW_L... | container.getImageDigest(), IMAGEDIGEST_BINDING); |
77,899 | public void run(RegressionEnvironment env) {<NEW_LINE>EPCompiled type = env.compile("@name('s0') @public @buseventtype create schema MyEvent(p string)");<NEW_LINE>EPCompiled selectMyEvent = env.compile("@name('s0') select * from MyEvent", new RegressionPath().add(type));<NEW_LINE>EPCompiled selectSB = env.compile("@nam... | EPDeployPreconditionException.class, selectSB, selectMyEvent); |
165,955 | public void changeUserPassword(ChangeUserPasswordRequest body, String xSdsAuthToken) throws ApiException {<NEW_LINE>Object localVarPostBody = body;<NEW_LINE>// verify the required parameter 'body' is set<NEW_LINE>if (body == null) {<NEW_LINE>throw new ApiException(400, "Missing the required parameter 'body' when callin... | , apiClient.parameterToString(xSdsAuthToken)); |
1,079,491 | // cuts polygon Q along the line formed by point a -> point b<NEW_LINE>// (note: the last point must be the same as the first point)<NEW_LINE>List<point> cutPolygon(point a, point b, List<point> Q) {<NEW_LINE>List<point> P = new ArrayList<point>();<NEW_LINE>for (int i = 0; i < (int) Q.size(); i++) {<NEW_LINE>double lef... | (P.get(0)); |
707,637 | public final void loadAllData(final String ticker, final File output, final CSVFormat outputFormat, final Date from, final Date to) {<NEW_LINE>try {<NEW_LINE>final URL url = buildURL(ticker, from, to);<NEW_LINE>final InputStream is = url.openStream();<NEW_LINE>final ReadCSV csv = new ReadCSV(is, true, CSVFormat.ENGLISH... | append(outputFormat.getSeparator()); |
1,226,518 | protected Set<MemberGroup> createInternalMemberGroups(Collection<? extends Member> members) {<NEW_LINE>Map<Integer, MemberGroup> memberGroups = new HashMap<Integer, MemberGroup>();<NEW_LINE>for (Member member : members) {<NEW_LINE>String host = ((MemberImpl) member)<MASK><NEW_LINE>for (Entry<Integer, MemberGroupConfig>... | .getAddress().getHost(); |
978,497 | private void writeDecompilationSummary(StringEscapeUtils.Builder builder) {<NEW_LINE>builder.append("<h2>Decompilation</h2>");<NEW_LINE>JadxDecompiler jadx = mainWindow.getWrapper().getDecompiler();<NEW_LINE>List<ClassNode> classes = jadx.getRoot().getClasses(false);<NEW_LINE>int classesCount = classes.size();<NEW_LINE... | ) * 100.0 / (double) methodsCount; |
1,109,119 | private static SQLResponse executeAndConvertResult(PreparedStatement preparedStatement) throws SQLException {<NEW_LINE>if (preparedStatement.execute()) {<NEW_LINE><MASK><NEW_LINE>ResultSet resultSet = preparedStatement.getResultSet();<NEW_LINE>List<Object[]> rows = new ArrayList<>();<NEW_LINE>List<String> columnNames =... | ResultSetMetaData metadata = preparedStatement.getMetaData(); |
1,246,464 | public DatastoreStorage unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>DatastoreStorage datastoreStorage = new DatastoreStorage();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LINE>JsonToken token = context.getCurrentT... | String currentParentElement = context.getCurrentParentElement(); |
399,420 | public static Renderer createRenderer(String reportFormat, Properties properties) {<NEW_LINE>Class<? extends Renderer> rendererClass = getRendererClass(reportFormat);<NEW_LINE>Constructor<? extends Renderer> constructor = getRendererConstructor(rendererClass);<NEW_LINE>Renderer renderer;<NEW_LINE>try {<NEW_LINE>if (con... | renderer.setProperty(prop2, valueFrom); |
1,184,012 | public BlackboardAttribute.Type addArtifactAttributeType(String attrTypeString, TSK_BLACKBOARD_ATTRIBUTE_VALUE_TYPE valueType, String displayName) throws TskCoreException, TskDataException {<NEW_LINE>CaseDbConnection connection = connections.getConnection();<NEW_LINE>acquireSingleUserCaseWriteLock();<NEW_LINE>Statement... | s, "SELECT attribute_type_id FROM blackboard_attribute_types WHERE type_name = '" + attrTypeString + "'"); |
332,490 | public ByteBuffer toNative(CharSequence string, ToNativeContext context) {<NEW_LINE>if (string == null) {<NEW_LINE>return null;<NEW_LINE>}<NEW_LINE>CharsetEncoder <MASK><NEW_LINE>ByteBuffer byteBuffer = ByteBuffer.wrap(new byte[(int) (string.length() * encoder.averageBytesPerChar()) + 4]);<NEW_LINE>CharBuffer charBuffe... | encoder = getEncoder(charset, localEncoder); |
694,907 | final DescribeClustersResult executeDescribeClusters(DescribeClustersRequest describeClustersRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(describeClustersRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "DescribeClusters"); |
70,381 | public NetworkOfferingResponse newNetworkOfferingResponse(NetworkOffering offering) {<NEW_LINE>NetworkOfferingResponse networkOfferingResponse = new NetworkOfferingResponse();<NEW_LINE>networkOfferingResponse.setId(offering.getUuid());<NEW_LINE>networkOfferingResponse.setName(offering.getName());<NEW_LINE>networkOfferi... | setDisplayText(offering.getDisplayText()); |
475,484 | protected static Map<String, List<Event>> findCatchingEventsForProcess(String processDefinitionId, String errorRef) {<NEW_LINE>Map<String, List<Event>> eventMap = new HashMap<String, List<Event>>();<NEW_LINE>Process process = ProcessDefinitionUtil.getProcess(processDefinitionId);<NEW_LINE>BpmnModel bpmnModel = ProcessD... | compareErrorCode = retrieveErrorCode(bpmnModel, errorRef); |
462,617 | private void mergeCategory(String categoryName, DiskIndex onDisk, int[] positions, OutputStream stream) throws IOException {<NEW_LINE>Map<String, Object> wordsToDocs = this.categoryTables.get(categoryName);<NEW_LINE>if (wordsToDocs == null) {<NEW_LINE>wordsToDocs = new HashMap<String, Object>(3);<NEW_LINE>}<NEW_LINE>Ma... | writeCategoryTable(categoryName, wordsToDocs, stream); |
746,304 | protected OrderedTensorType lazyGetType() {<NEW_LINE>if (!allInputTypesPresent(2))<NEW_LINE>return null;<NEW_LINE>IntermediateOperation axisOperation = inputs().get(1);<NEW_LINE>if (!axisOperation.getConstantValue().isPresent()) {<NEW_LINE>throw new IllegalArgumentException("ExpandDims in " + name + ": Axis must be a c... | IllegalArgumentException("ExpandDims in " + name + ": Axis argument must be a scalar."); |
1,791,337 | public static Result match(@NotNull PsiElement psiElement, @NotNull Matcher matcher) {<NEW_LINE>PsiElement arrayValue = psiElement.getParent();<NEW_LINE>if (PsiElementAssertUtil.isNotNullAndIsElementType(arrayValue, PhpElementTypes.ARRAY_VALUE)) {<NEW_LINE>PsiElement arrayHashElement = arrayValue.getParent();<NEW_LINE>... | matchPair.getSecond(), arrayKey); |
98,638 | public Object visit(Object context, FunctionExpression expr, boolean strict) {<NEW_LINE>Scope scope = (Scope) context;<NEW_LINE>FunctionDescriptor descriptor = expr.getDescriptor();<NEW_LINE>Variable result = scope.createTemporaryVariable();<NEW_LINE>String[] parameterNames = descriptor.getFormalParameterNames();<NEW_L... | isStrict(), parameterNames, null); |
15,775 | private IRubyObject zipCommon(ThreadContext context, IRubyObject[] args, Block block, ArgumentVisitor visitor) {<NEW_LINE>final Ruby runtime = context.runtime;<NEW_LINE>if (block.isGiven()) {<NEW_LINE>for (int i = 0; i < realLength; i++) {<NEW_LINE>IRubyObject[] tmp = IRubyObject.array(addBufferLength(runtime<MASK><NEW... | , args.length, 1)); |
362,547 | public Object runPhasedAction(InternalPhasedAction clientPhasedAction, PhasedActionResultListener resultListener, BuildCancellationToken cancellationToken, ProviderOperationParameters providerParameters) {<NEW_LINE>List<String> tasks = providerParameters.getTasks();<NEW_LINE>SerializedPayload serializedAction = payload... | ProgressListenerConfiguration.from(providerParameters, consumerVersion); |
86,501 | private void tryAssertion(RegressionEnvironment env, long timestamp) {<NEW_LINE>String[] fields = "runtimeURI,statementName".split(",");<NEW_LINE>SupportListener listener = env.listener("stmt_metrics");<NEW_LINE>assertEquals(4, listener.getNewDataList().size());<NEW_LINE>EventBean[] received = listener.getNewDataListFl... | (wallOne + 50) > WALL_GOAL_ONE_MSEC); |
1,755,353 | protected boolean beforeInvoke(Object receiver, Method method, Object[] args) throws Throwable {<NEW_LINE>// API 2.3, 4.01, 4.0.3_r1<NEW_LINE>if (args != null) {<NEW_LINE>final <MASK><NEW_LINE>String packageName = null;<NEW_LINE>if (args.length > index0) {<NEW_LINE>if (args[index0] != null && args[index0] instanceof S... | int index0 = 0, index1 = 1; |
1,621,937 | private JCExpression classForNameCall(Type type, JCTree tree) {<NEW_LINE>TreeMaker make = _tp.getTreeMaker();<NEW_LINE><MASK><NEW_LINE>JCTree.JCMethodInvocation typeCall = make.Apply(List.nil(), memberAccess(make, javacElems, ReflectUtil.class.getName() + ".type"), List.of(make.Literal(makeLiteralName(type))));<NEW_LIN... | JavacElements javacElems = _tp.getElementUtil(); |
933,423 | public static void down(ImageGray input, int sampleWidth, ImageGray output) {<NEW_LINE>if (input instanceof GrayU8) {<NEW_LINE>down((GrayU8) input, sampleWidth, (GrayI8) output);<NEW_LINE>} else if (input instanceof GrayS8) {<NEW_LINE>down((GrayS8) input, sampleWidth, (GrayI8) output);<NEW_LINE>} else if (input instanc... | , sampleWidth, (GrayF32) output); |
35,361 | public void divideRoutineLoadJob(int currentConcurrentTaskNum) throws UserException {<NEW_LINE>List<RoutineLoadTaskInfo> result = new ArrayList<>();<NEW_LINE>writeLock();<NEW_LINE>try {<NEW_LINE>if (state == JobState.NEED_SCHEDULE) {<NEW_LINE>// divide kafkaPartitions into tasks<NEW_LINE>for (int i = 0; i < currentConc... | getRoutineLoadTaskScheduler().addTasksInQueue(result); |
1,199,467 | public void onError(java.lang.Exception e) {<NEW_LINE>byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;<NEW_LINE>org.apache.thrift.TSerializable msg;<NEW_LINE>getUserAuthorizations_result result = new getUserAuthorizations_result();<NEW_LINE>if (e instanceof ThriftSecurityException) {<NEW_LINE>result.sec = ... | _LOGGER.error("TTransportException inside handler", e); |
285,645 | public void run(RegressionEnvironment env) {<NEW_LINE>RegressionPath path = setupInfra(env, namedWindow);<NEW_LINE>env.sendEventBean(new SupportBean("E1", 1));<NEW_LINE>env.sendEventBean(new SupportBean("E2", 11));<NEW_LINE>env.sendEventBean(new SupportBean("E1", 5));<NEW_LINE>String[] fields = new <MASK><NEW_LINE>Stri... | String[] { "theString", "total" }; |
221,917 | final DeleteConnectionResult executeDeleteConnection(DeleteConnectionRequest deleteConnectionRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(deleteConnectionRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | false), new DeleteConnectionResultJsonUnmarshaller()); |
839,587 | public static ListPredefinedPrivilegesResponse unmarshall(ListPredefinedPrivilegesResponse listPredefinedPrivilegesResponse, UnmarshallerContext context) {<NEW_LINE>listPredefinedPrivilegesResponse.setRequestId(context.stringValue("ListPredefinedPrivilegesResponse.RequestId"));<NEW_LINE>listPredefinedPrivilegesResponse... | ("ListPredefinedPrivilegesResponse.Privileges[" + i + "].PrivilegeDescription")); |
864,652 | public InputSource resolveEntity(String name, String publicId, String baseURI, String systemId) throws SAXException, IOException {<NEW_LINE>Logger log = Scope.getCurrentScope().getLog(getClass());<NEW_LINE>log.fine("Resolving XML entity name='" + name + "', publicId='" + publicId + "', baseURI='" + baseURI + "', system... | .getCurrentScope().getResourceAccessor(); |
1,322,701 | public static void addMissingReturnTypeProposals(IInvocationContext context, IProblemLocationCore problem, Collection<ChangeCorrectionProposal> proposals) {<NEW_LINE>ICompilationUnit cu = context.getCompilationUnit();<NEW_LINE>CompilationUnit astRoot = context.getASTRoot();<NEW_LINE>ASTNode selectedNode = problem.getCo... | typeBinding = Bindings.normalizeTypeBinding(typeBinding); |
493,674 | private void addTab(String title, Icon icon, final Component c, boolean hideable, boolean visible, int index, boolean reparent) {<NEW_LINE>if (!this.fullTabList.contains(c)) {<NEW_LINE>this.fullTabList.add(c);<NEW_LINE>}<NEW_LINE>if (c instanceof AbstractPanel) {<NEW_LINE>if (reparent) {<NEW_LINE>((AbstractPanel) c).se... | pos = this.indexOfComponent(c); |
177,913 | public void run(FlowTrigger trigger, Map data) {<NEW_LINE>CreateVolumeSnapshotMsg cmsg = new CreateVolumeSnapshotMsg();<NEW_LINE>cmsg.<MASK><NEW_LINE>cmsg.setDescription(msg.getDescription());<NEW_LINE>cmsg.setResourceUuid(msg.getResourceUuid());<NEW_LINE>cmsg.setAccountUuid(msg.getSession().getAccountUuid());<NEW_LINE... | setName(msg.getName()); |
1,411,867 | protected void buildMainPanel() {<NEW_LINE>stackTable = new GhidraTable(stackTableModel);<NEW_LINE>mainPanel.add(new JScrollPane(stackTable));<NEW_LINE>stackFilterPanel = new GhidraTableFilterPanel<>(stackTable, stackTableModel);<NEW_LINE>mainPanel.add(stackFilterPanel, BorderLayout.SOUTH);<NEW_LINE>stackTable.getSelec... | row = stackTableModel.getRowObject(selectedRow); |
66,755 | public void marshall(Datapoint _datapoint, Request<?> request, String _prefix) {<NEW_LINE>String prefix;<NEW_LINE>if (_datapoint.getTimestamp() != null) {<NEW_LINE>prefix = _prefix + "Timestamp";<NEW_LINE>java.util.Date timestamp = _datapoint.getTimestamp();<NEW_LINE>request.addParameter(prefix, StringUtils.fromDate(ti... | Double minimum = _datapoint.getMinimum(); |
734,829 | // Use invokeAll where maxQueueSize is constrained to 1 and runIfQueueFull is false and maxConcurrency is unlimited.<NEW_LINE>// Normally, the queue size of 1 would risk having task submissions aborted when tasks are not pulled from the queue<NEW_LINE>// for execution quickly enough. However, the fact that the user has... | i, future.isDone()); |
1,544,889 | protected void populateBindings(BeanMetaData bmd, Map<JNDIEnvironmentRefType, Map<String, String>> allBindings, Map<String, String> envEntryValues, ResourceRefConfigList resRefList) throws EJBConfigurationException {<NEW_LINE>WCCMMetaDataImpl wccm = getWASWCCMMetaData(bmd);<NEW_LINE>RefBindingsGroup beanBinding = wccm.... | >[] interceptorClasses = imd.ivInterceptorClasses; |
1,191,110 | private void respondWithHttpError(ChannelHandlerContext ctx, int streamId, int code, Status.Code statusCode, String msg) {<NEW_LINE>Metadata metadata = new Metadata();<NEW_LINE>metadata.put(InternalStatus.CODE_KEY, statusCode.toStatus());<NEW_LINE>metadata.put(InternalStatus.MESSAGE_KEY, msg);<NEW_LINE>byte[][] seriali... | false, ctx.newPromise()); |
1,434,395 | final UntagResourceResult executeUntagResource(UntagResourceRequest untagResourceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(untagResourceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEvent(Field.Clien... | addHandlerContext(HandlerContextKey.OPERATION_NAME, "UntagResource"); |
165,945 | private void encodeTrigger(JobTrigger trigger, Bundle data) {<NEW_LINE>if (trigger == Trigger.NOW) {<NEW_LINE>data.putInt(prefix + BundleProtocol.PACKED_PARAM_TRIGGER_TYPE, BundleProtocol.TRIGGER_TYPE_IMMEDIATE);<NEW_LINE>} else if (trigger instanceof JobTrigger.ExecutionWindowTrigger) {<NEW_LINE>JobTrigger.ExecutionWi... | PACKED_PARAM_TRIGGER_WINDOW_END, t.getWindowEnd()); |
35,122 | final CreateDataSourceResult executeCreateDataSource(CreateDataSourceRequest createDataSourceRequest) {<NEW_LINE>ExecutionContext executionContext = createExecutionContext(createDataSourceRequest);<NEW_LINE>AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();<NEW_LINE>awsRequestMetrics.startEv... | HandlerContextKey.SIGNING_REGION, getSigningRegion()); |
1,355,521 | private void outputMethods(String name, ComponentInfo info, Writer out) throws IOException {<NEW_LINE>out.write(String.format("%n%n### Methods {#%s-Methods}%n%n{:.methods}", name));<NEW_LINE>boolean didOutput = false;<NEW_LINE>for (Method method : info.methods.values()) {<NEW_LINE>if (isFeatureHidden(info, method)) {<... | formatParameters(method.parameters))); |
1,172,875 | private void _buildWebSphereXML() throws Exception {<NEW_LINE>StringBuffer sb = new StringBuffer();<NEW_LINE>sb.append("<?xml version=\"1.0\"?>\n");<NEW_LINE>sb.append("\n<com.ibm.ejs.models.base.bindings.ejbbnd:EJBJarBinding xmlns:com.ibm.ejs.models.base.bindings.ejbbnd=\"ejbbnd.xmi\" xmlns:xmi=\"http://www.omg.org/XM... | ++sessionCount).append("_Bnd\" jndiName=\""); |
670,031 | public <C, B> Mono<Flux<Message<C, B>>> receiveLater(Iterable<? extends Topic> topics, SerializationPair<C> channelSerializer, SerializationPair<B> messageSerializer) {<NEW_LINE>Assert.notNull(topics, "Topics must not be null!");<NEW_LINE>Assert.notNull(channelSerializer, "Channel serializer must not be null!");<NEW_LI... | SubscriptionReadyListener.create(topics, stringSerializationPair); |
1,503,147 | static public boolean rangeCheck(final ISeparatorKeys pmd, final byte[] key, final boolean allowUpperBound) {<NEW_LINE>final byte[] leftSeparatorKey = pmd.getLeftSeparatorKey();<NEW_LINE>final byte[] rightSeparatorKey = pmd.getRightSeparatorKey();<NEW_LINE>if (BytesUtil.compareBytes(key, leftSeparatorKey) < 0) {<NEW_LI... | KeyAfterPartitionException(key, allowUpperBound, pmd); |
62,051 | public CapacityUnitsConfiguration unmarshall(JsonUnmarshallerContext context) throws Exception {<NEW_LINE>CapacityUnitsConfiguration capacityUnitsConfiguration = new CapacityUnitsConfiguration();<NEW_LINE>int originalDepth = context.getCurrentDepth();<NEW_LINE><MASK><NEW_LINE>int targetDepth = originalDepth + 1;<NEW_LI... | String currentParentElement = context.getCurrentParentElement(); |
906,095 | @Produces(MediaType.APPLICATION_JSON)<NEW_LINE>public Response indexSearch(@Context HttpServletRequest request, @Context final HttpServletResponse response, @PathParam("query") String query, @PathParam("sortby") String sortBy, @PathParam("limit") int limit, @PathParam("offset") int offset, @PathParam("type") String typ... | paramsMap.put("type", type); |
814,032 | public UserDetails loadUserByUsername(String clientId) throws UsernameNotFoundException {<NEW_LINE>try {<NEW_LINE>String decodedClientId = UriUtils.decode(clientId, "UTF-8");<NEW_LINE>ClientDetailsEntity client = clientDetailsService.loadClientByClientId(decodedClientId);<NEW_LINE>if (client != null) {<NEW_LINE>String ... | accountNonExpired, credentialsNonExpired, accountNonLocked, authorities); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.